repo_name stringlengths 5 122 | path stringlengths 3 232 | text stringlengths 6 1.05M |
|---|---|---|
jl2922/hci | src/heg/k_points_util.h | <reponame>jl2922/hci
#ifndef K_POINTS_UTIL_H_
#define K_POINTS_UTIL_H_
#include <array>
#include <vector>
class KPointsUtil {
public:
static int get_n_k_points(const double);
static std::vector<std::array<int8_t, 3>> generate_k_points(const double);
static std::vector<std::array<int8_t, 3>> get_k_diffs(
... |
jl2922/hci | src/parallel.h | #ifndef PARALLEL_H_
#define PARALLEL_H_
#include <algorithm>
#include <functional>
#include <vector>
class Parallel {
public:
Parallel(int argc, char** argv) {
(void)argc;
(void)argv;
};
virtual ~Parallel() = default;
virtual bool is_master() const = 0;
virtual int get_proc_id() const = 0;
vi... |
jl2922/hci | src/solver/davidson_util.h | #ifndef DAVIDSON_UTIL_H_
#define DAVIDSON_UTIL_H_
#include <functional>
#include <utility>
#include <vector>
class DavidsonUtil {
public:
// Returns lowest eigen value and eigen vector.
static std::pair<double, std::vector<double>> diagonalize(
const std::vector<double>& initial_vector,
const std::ve... |
jl2922/hci | src/heg/heg_system.h | #ifndef HEG_SYSTEM_H_
#define HEG_SYSTEM_H_
#include "../abstract_system.h"
class HEGSystem : public AbstractSystem {
public:
HEGSystem(Session* const session) : AbstractSystem(session) {}
virtual ~HEGSystem() = default;
// Generate k points, hci array, and HF for the specified rcut.
virtual void setup(con... |
jl2922/hci | src/heg/heg_controller.h | <gh_stars>1-10
#ifndef HEG_CONTROLLER_H_
#define HEG_CONTROLLER_H_
#include "../session.h"
#include "../solver/solver.h"
#include "heg_system.h"
class HEGController {
public:
HEGController(
Session* const session, Solver* const solver, HEGSystem* const heg_system)
: session(session), solver(solver), he... |
jl2922/hci | src/injector.h | #ifndef INJECTOR_H_
#define INJECTOR_H_
#include "abstract_system.h"
#include "config.h"
#include "heg/heg_controller.h"
#include "heg/heg_system.h"
#include "parallel.h"
#include "session.h"
#include "solver/connections.h"
#include "solver/solver.h"
#include "timer.h"
// Dependency injection.
class Injector {
publi... |
jl2922/hci | src/abstract_system.h | <reponame>jl2922/hci
#ifndef ABSTRACT_SYSTEM_H_
#define ABSTRACT_SYSTEM_H_
#include <functional>
#include <memory>
#include <string>
#include <vector>
#include "data.pb.h"
#include "session.h"
class AbstractSystem {
public:
AbstractSystem(Session* const session) : session(session) {}
std::vector<std::string> de... |
jl2922/hci | src/solver/solver.h | <filename>src/solver/solver.h
#ifndef SOLVER_H_
#define SOLVER_H_
#include "../abstract_system.h"
#include "../session.h"
#include "connections.h"
class Solver {
public:
Solver(
Session* const session,
Connections* const connections,
AbstractSystem* const abstract_system)
: session(session)... |
jl2922/hci | src/array_math.h | <reponame>jl2922/hci<filename>src/array_math.h<gh_stars>1-10
#ifndef ARRAY_MATH_H_
#define ARRAY_MATH_H_
#include <array>
template <class T, size_t N>
std::array<T, N> operator+(
const std::array<T, N> &lhs, const std::array<T, N> &rhs) {
std::array<T, N> res;
for (size_t i = 0; i < N; i++) res[i] = lhs[i] + ... |
dlguswo333/baidu-allreduce | collectives.h | #ifndef BAIDU_ALLREDUCE_COLLECTIVES_H_
#define BAIDU_ALLREDUCE_COLLECTIVES_H_ value
#include <cstddef>
#include <mpi.h>
#define NO_DEVICE -1
/*
* This file contains the implementation of the baidu-allreduce communication
* collectives, and provides the following functions:
*
* void InitCollectives(int device... |
dlguswo333/baidu-allreduce | timer.h | #pragma once
#ifndef TIMER_SMALL_SECOND
#define TIMER_SMALL_SECOND 5e-324
#endif
#ifndef TIMER_LARGE_SECOND
#define TIMER_LARGE_SECOND 5e324
#endif
#include <ctime>
namespace timer
{
class Timer
{
public:
/*! \brief A type for seconds */
typedef double Second;
/*! \brief A type for representin... |
hmunozb/Ising-Monte-Carlo-Example | include/ising_mc.h | /*
* File: ising_mc.h
* Author: hmunozbauza
*
* Created on December 20, 2015, 8:06 AM
*/
#ifndef ISING_MC_H
#define ISING_MC_H
#include "ising.h"
#include "MCMC.h"
#include "monte_carlo.h"
#include "topologies.h"
void ising_basic_mc(int ising_l, unsigned long sweeps, double beta);
void ising_pt(int ising_l, ... |
hmunozb/Ising-Monte-Carlo-Example | include/_ising/ising_model.h | /*
* File: ising_model.h
* Author: hmunozbauza
*
* Created on December 18, 2015, 11:49 PM
*/
#ifndef ISING_MODEL_H
#define ISING_MODEL_H
#include "ising_instance.h"
using namespace std;
template< typename NumericType>
class ising_model {
public:
/*constructs an ising model object from the given instance. Spi... |
hmunozb/Ising-Monte-Carlo-Example | include/StatMechFunctionals.h | /*
* File: StatMechFunctionals.h
* Author: hmunozbauza
*
* Created on April 22, 2016, 1:10 PM
*/
#ifndef STATMECHFUNCTIONALS_H
#define STATMECHFUNCTIONALS_H
#include <map>
#include "MCMC.h"
using namespace std;
template< typename NumericType >
class BoltzmannTPF : public TransitionProbabilityFn< NumericType... |
hmunozb/Ising-Monte-Carlo-Example | include/Log.h | /*
* File: Log.h
* Author: hmunozbauza
*
* Created on June 7, 2015, 11:21 PM
*/
#ifndef LOG_H
#define LOG_H
#define ELPP_DEBUG_ASSERT_FAILURE
#define ELPP_NO_DEFAULT_LOG_FILE
#define ELPP_THREAD_SAFE
#if defined(__GNUC__)
#define ELPP_STACKTRACE_ON_CRASH
#endif
#include "easylogging++.h"
#endif /* LOG_H... |
hmunozb/Ising-Monte-Carlo-Example | include/MCMC.h | /*
* File: MCMC.h
* Author: hmunozbauza
*
* Created on June 25, 2015, 3:27 PM
*/
#ifndef MCMC_H
#define MCMC_H
#include <random>
#include <map>
using namespace std;
/*
* Hast_Metr_Advance()
* Generic advancer for the Hastings-Metropolis algorithm
*
* Explicit Template Parameters:
* * MvType - The data... |
hmunozb/Ising-Monte-Carlo-Example | include/topologies.h | <reponame>hmunozb/Ising-Monte-Carlo-Example<filename>include/topologies.h<gh_stars>0
/*
* File: topologies.h
* Author: hmunozbauza
*
* Created on December 20, 2015, 7:56 AM
*/
#ifndef TOPOLOGIES_H
#define TOPOLOGIES_H
#include <boost/graph/adjacency_list.hpp>
#include "_ising/ising_instance.h"
#include "randu... |
hmunozb/Ising-Monte-Carlo-Example | include/_ising/ising_instance.h | <filename>include/_ising/ising_instance.h
/*
* File: ising_instance.h
* Author: hmunozbauza
*
* Created on December 18, 2015, 7:07 PM
*/
#ifndef ISING_INSTANCE_H
#define ISING_INSTANCE_H
#include <vector>
#include <random>
#include <boost/graph/adjacency_list.hpp>
using namespace std;
using namespace boost;
... |
hmunozb/Ising-Monte-Carlo-Example | include/EMDataQueue.h | /*
* File: EMDataQueue.h
* Author: hmunozbauza
*
* Created on April 23, 2016, 1:23 PM
*/
#ifndef EMDATAQUEUE_H
#define EMDATAQUEUE_H
#include "readerwriterqueue.h"
using namespace std;
using namespace moodycamel;
enum EMDataCode{
OK,
PHASE_DONE,
SIM_DONE
};
struct EMData {
long replica_id;
EMDataCode ... |
hmunozb/Ising-Monte-Carlo-Example | include/Arg.h | <filename>include/Arg.h
/*
* File: Arg.h
* Author: hmunozbauza
*
* Created on June 14, 2015, 3:06 PM
*/
#ifndef ARG_H
#define ARG_H
/*
* Arg.h
* Some structures to build on optionparser to parse
* the options passed to the program.
*/
#ifndef LIBCOMPILE
#include "optionparser.h"
#include <cstdlib>
#inc... |
hmunozb/Ising-Monte-Carlo-Example | include/RandGenerators.h | <filename>include/RandGenerators.h
/*
* File: RandGenerators.h
* Author: hmunozbauza
*
* Created on April 22, 2016, 1:11 PM
*/
#ifndef RANDGENERATORS_H
#define RANDGENERATORS_H
#include "randutils.hpp"
using RNG_ENGINE = mt19937_64;
using RAND_UL = uniform_int_distribution<unsigned long>;
using RAND_REAL = un... |
hmunozb/Ising-Monte-Carlo-Example | include/monte_carlo.h | <filename>include/monte_carlo.h
/*
* File: monte_carlo.h
* Author: hmunozbauza
*
* Created on June 21, 2015, 3:18 AM
*/
#ifndef MONTE_CARLO_H
#define MONTE_CARLO_H
#include "concurrentqueue.h"
#include "blockingconcurrentqueue.h"
#include "EMDataQueue.h"
#include <chrono>
#include <random>
#include <deque>
... |
orctom/speex | libspeex/speex_codec.c | <gh_stars>1-10
//#define DEBUG
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
#include "speex.h"
//#include "speex/speex_codec.h"
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#define max(a,b) ( ((a)>(b)) ? (a):(b) )
#define min(a,b) ( ((a)>(b)) ? (b):(a) )
typedef struct SpeexStateType {
SpeexBi... |
orctom/speex | include/speex/speex_codec.h | <filename>include/speex/speex_codec.h
#include "speex.h"
#ifndef SPEEX_SPEEX_CODEC_H
#define SPEEX_SPEEX_CODEC_H
#ifdef __cplusplus
extern "C" {
#endif
struct SpeexStateType;
typedef struct SpeexStateType SpeexState;
SpeexState *create_encoder(int mode, int quality, int sampling_rate);
SpeexState *create_decoder(... |
nopnop2002/esp-idf-ttp229 | main/ttp229.c | <gh_stars>0
/*********************************** LICENCE **********************************\
| Copyright (c) 2014, <NAME> |
| All rights reserved. |
| ... |
nopnop2002/esp-idf-ttp229 | main/ttp229.h | /*********************************** LICENCE **********************************\
| Copyright (c) 2014, <NAME> |
| All rights reserved. |
| ... |
nopnop2002/esp-idf-ttp229 | main/main.c | /* TTP229 Example
This example code is in the Public Domain (or CC0 licensed, at your option.)
Unless required by applicable law or agreed to in writing, this
software is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
CONDITIONS OF ANY KIND, either express or implied.
*/
#include <stdio.h>
#include <s... |
uCRDev/realsense_samples_ros | realsense_ros_person/src/apiwrapper/publisher/AbsPersonTrackingPublisher.h | <reponame>uCRDev/realsense_samples_ros<gh_stars>100-1000
// License: Apache 2.0. See LICENSE file in root directory.
// Copyright(c) 2017 Intel Corporation. All Rights Reserved
#pragma once
#include "ros/ros.h"
#include "person_tracking_video_module_factory.h"
#include <sensor_msgs/Image.h>
#include "realsense_ros_per... |
uCRDev/realsense_samples_ros | realsense_ros_object/src/utils.h | // License: Apache 2.0. See LICENSE file in root directory.
// Copyright(c) 2017 Intel Corporation. All Rights Reserved.
#pragma once
#include <librealsense/rs.hpp>
#include <librealsense/object_recognition/or_data_interface.h>
#include <librealsense/object_recognition/or_configuration_interface.h>
#include <librealse... |
uCRDev/realsense_samples_ros | realsense_ros_person/src/sample/TrackingRenderer/PersonDataStorage.h | // License: Apache 2.0. See LICENSE file in root directory.
// Copyright(c) 2017 Intel Corporation. All Rights Reserved
#pragma once
#include <opencv2/core/core.hpp>
#include <map>
class PersonData
{
public:
int Id;
int rid = 0;
cv::Rect rectangle;
bool valid;
};
class PersonDataStorage
{
pub... |
uCRDev/realsense_samples_ros | realsense_ros_person/src/apiwrapper/helpers/Ros2RealsenseSdkConverter.h | // License: Apache 2.0. See LICENSE file in root directory.
// Copyright(c) 2017 Intel Corporation. All Rights Reserved
#pragma once
#include <sensor_msgs/Image.h>
#include <sensor_msgs/CameraInfo.h>
#include <rs/core/correlated_sample_set.h>
#include <rs/core/video_module_interface.h>
namespace realsense_ros_perso... |
uCRDev/realsense_samples_ros | realsense_ros_camera/test/camera_core.h | // License: Apache 2.0. See LICENSE file in root directory.
// Copyright(c) 2017 Intel Corporation. All Rights Reserved
#pragma once
#ifndef CAMERA_CORE_H // NOLINT(build/header_guard)
#define CAMERA_CORE_H
#include <cstdlib>
#include <cctype>
#include <sstream>
#include <iostream>
#include <vector>
#include <map>
#... |
uCRDev/realsense_samples_ros | realsense_ros_person/src/apiwrapper/publisher/PersonTrackingDefaultPublisher.h | // License: Apache 2.0. See LICENSE file in root directory.
// Copyright(c) 2017 Intel Corporation. All Rights Reserved
#pragma once
#include <memory>
#include "AbsPersonTrackingPublisher.h"
#include "PersonTrackingPublisherHelper.h"
namespace realsense_ros_person
{
class PersonTrackingDefaultPublisher : public Abs... |
uCRDev/realsense_samples_ros | realsense_ros_slam/include/realsense_ros_slam/slam_nodelet.h | <reponame>uCRDev/realsense_samples_ros
// License: Apache 2.0. See LICENSE file in root directory.
// Copyright(c) 2017 Intel Corporation. All Rights Reserved
#pragma once
#include <iostream>
#include <functional>
#include <iomanip>
#include <map>
#include <atomic>
#include <thread>
#include <pluginlib/class_list_macr... |
uCRDev/realsense_samples_ros | realsense_ros_person/src/apiwrapper/helpers/PersonTracking2RosHelper.h | <gh_stars>100-1000
// License: Apache 2.0. See LICENSE file in root directory.
// Copyright(c) 2017 Intel Corporation. All Rights Reserved
#pragma once
#include <RealSense/PersonTracking/PersonTrackingConfiguration.h>
#include "realsense_ros_person/RecognitionResponse.h"
#include "realsense_ros_person/RecognitionReg... |
uCRDev/realsense_samples_ros | realsense_ros_person/src/sample/TrackingRenderer/TrackingRenderer.h | // License: Apache 2.0. See LICENSE file in root directory.
// Copyright(c) 2017 Intel Corporation. All Rights Reserved
#pragma once
#include "Viewer.h"
#include "PersonDataStorage.h"
#include <opencv2/core/core.hpp>
#include <vector>
#include <functional>
#include <memory>
class TrackingRenderer
{
public:
enum Sel... |
uCRDev/realsense_samples_ros | realsense_ros_person/src/apiwrapper/helpers/PersonTrackingHelper.h | <gh_stars>100-1000
// License: Apache 2.0. See LICENSE file in root directory.
// Copyright(c) 2017 Intel Corporation. All Rights Reserved
#pragma once
#include <string>
#include <ros/ros.h>
#include "RealSense/PersonTracking/PersonTrackingConfiguration.h"
namespace realsense_ros_person
{
struct PersonTrackingConfig... |
uCRDev/realsense_samples_ros | realsense_ros_person/src/sample/TrackingRenderer/Colors.h | <gh_stars>100-1000
// License: Apache 2.0. See LICENSE file in root directory.
// Copyright(c) 2017 Intel Corporation. All Rights Reserved#pragma once
#include <opencv2/core/core.hpp>
cv::Scalar BLACK(0, 0, 0);
cv::Scalar WHITE(255, 255, 255);
cv::Scalar RED(0, 0, 255);
cv::Scalar BLUE(255, 0, 0);
cv::Scalar GREEN(0... |
uCRDev/realsense_samples_ros | realsense_ros_person/src/sample/TrackingRenderer/Viewer.h | // License: Apache 2.0. See LICENSE file in root directory.
// Copyright(c) 2017 Intel Corporation. All Rights Reserved
#pragma once
#include <opencv2/core/core.hpp>
#include <functional>
class Viewer
{
public:
Viewer(bool showDepth);
void ShowImage(cv::Mat image);
void ShowDepth(cv::Mat depth);
void SetMou... |
uCRDev/realsense_samples_ros | realsense_ros_person/src/sample/PersonTrackingSample.h | <filename>realsense_ros_person/src/sample/PersonTrackingSample.h
// License: Apache 2.0. See LICENSE file in root directory.
// Copyright(c) 2017 Intel Corporation. All Rights Reserved
#pragma once
#include "ros/ros.h"
#include "realsense_ros_person/FrameTest.h"
#include "TrackingRenderer/TrackingRenderer.h"
#include ... |
uCRDev/realsense_samples_ros | realsense_ros_object/src/viewer/GUI_utils.h | <filename>realsense_ros_object/src/viewer/GUI_utils.h
// License: Apache 2.0. See LICENSE file in root directory.
// Copyright(c) 2017 Intel Corporation. All Rights Reserved.
#pragma once
#include <opencv2/highgui.hpp>
#include <opencv2/imgproc.hpp>
#include <opencv2/core.hpp>
#include <cv_bridge/cv_bridge.h>
#includ... |
uCRDev/realsense_samples_ros | realsense_ros_camera/include/realsense_ros_camera/constants.h | <gh_stars>100-1000
// License: Apache 2.0. See LICENSE file in root directory.
// Copyright(c) 2017 Intel Corporation. All Rights Reserved
#include <iostream>
#include <string>
#include <utility>
#include <map>
#pragma once
#ifndef REALSENSE_CAMERA_CONSTANTS_H
#define REALSENSE_CAMERA_CONSTANTS_H
namespace realsense... |
uCRDev/realsense_samples_ros | realsense_ros_slam/include/ParamTypes.h | // License: Apache 2.0. See LICENSE file in root directory.
// Copyright(c) 2017 Intel Corporation. All Rights Reserved
#pragma once
#include "stdio.h"
typedef struct stCameraWorldParam
{
float ffar;
float fnear;
float fFOV;
float fCameraHeight2Width;
void Default()
{
ffar = 2.5f;
f... |
uCRDev/realsense_samples_ros | realsense_ros_slam/include/2DMapCommon.h | <reponame>uCRDev/realsense_samples_ros
// License: Apache 2.0. See LICENSE file in root directory.
// Copyright(c) 2017 Intel Corporation. All Rights Reserved
#pragma once
#include <opencv2/opencv.hpp>
#define INNAV_RENDER_DATA_INSIDE
enum emNavStatus
{
navInvalid,
navContinue,
navStay,
navNavig... |
uCRDev/realsense_samples_ros | realsense_ros_object/src/realsense_localization_nodelet.h | <filename>realsense_ros_object/src/realsense_localization_nodelet.h
// License: Apache 2.0. See LICENSE file in root directory.
// Copyright(c) 2017 Intel Corporation. All Rights Reserved.
#pragma once
# ifndef RS_LOCALIZATION_NODELET
# define RS_LOCALIZATION_NODELET
///////////////////////////////////////////////
//... |
uCRDev/realsense_samples_ros | realsense_ros_person/src/apiwrapper/publisher/PersonTrackingPublisherHelper.h | // License: Apache 2.0. See LICENSE file in root directory.
// Copyright(c) 2017 Intel Corporation. All Rights Reserved
#pragma once
#include <PersonTracking2RosHelper.h>
#include "RealSense/PersonTracking/PersonTrackingConfiguration.h"
#include "RealSense/PersonTracking/PersonTrackingData.h"
#include "realsense_ros... |
uCRDev/realsense_samples_ros | realsense_ros_person/src/apiwrapper/server/PersonTrackingServer.h | // License: Apache 2.0. See LICENSE file in root directory.
// Copyright(c) 2017 Intel Corporation. All Rights Reserved
#pragma once
#include <ros/ros.h>
#include <realsense_ros_person/StartTracking.h>
#include <realsense_ros_person/StopTracking.h>
#include <realsense_ros_person/Recognition.h>
#include <realsense_ros_... |
uCRDev/realsense_samples_ros | realsense_ros_object/src/viewer/realsense_orview_nodelet.h | <gh_stars>100-1000
// License: Apache 2.0. See LICENSE file in root directory.
// Copyright(c) 2017 Intel Corporation. All Rights Reserved.
#pragma once
# ifndef RS_ORVIEW_NODELET
# define RS_ORVIEW_NODELET
///////////////////////////////////////////////
/// Dependencies
//////////////////////////////////////////////... |
uCRDev/realsense_samples_ros | realsense_ros_object/src/sample-localize-track/realsense_ormgr_nodelet.h | <gh_stars>100-1000
// License: Apache 2.0. See LICENSE file in root directory.
// Copyright(c) 2017 Intel Corporation. All Rights Reserved.
#pragma once
# ifndef RS_ORMGR_NODELET
# define RS_ORMGR_NODELET
///////////////////////////////////////////////
/// Dependencies
///////////////////////////////////////////////
... |
uCRDev/realsense_samples_ros | realsense_ros_person/src/sample/TrackingRenderer/OpencvUtils.h | <filename>realsense_ros_person/src/sample/TrackingRenderer/OpencvUtils.h
// License: Apache 2.0. See LICENSE file in root directory.
// Copyright(c) 2017 Intel Corporation. All Rights Reserved
#pragma once
#include <opencv2/highgui/highgui.hpp>
#include <opencv2/imgproc/imgproc.hpp>
struct Rectangle
{
Rectangle(cv... |
uCRDev/realsense_samples_ros | realsense_ros_person/src/apiwrapper/realsense_ros_person_nodelet.h | // License: Apache 2.0. See LICENSE file in root directory.
// Copyright(c) 2017 Intel Corporation. All Rights Reserved
#include <vector>
#include <cstring>
#include <sys/types.h>
#include <sys/stat.h>
#include <string>
#include <fstream>
#include <iostream>
#include <unistd.h>
#include <signal.h>
#include <stdio.h>
#... |
fandigunawan/Terminal | src/cascadia/TerminalApp/TerminalTab.h | // Copyright (c) Microsoft Corporation.
// Licensed under the MIT license.
#pragma once
#include "Pane.h"
#include "ColorPickupFlyout.h"
#include "TabBase.h"
#include "TerminalTab.g.h"
static constexpr double HeaderRenameBoxWidthDefault{ 165 };
static constexpr double HeaderRenameBoxWidthTitleLength{ std::n... |
gouyz/GYZTuAi | TuAi/TuAi/TuAi-Bridging-Header.h | // 桥接文件
// Use this file to import your target's public headers that you would like to expose to Swift.
//
/// 选择框
#import "IQActionSheetPickerView.h"
/// 多标签选择
#import "HXTagsView.h"
#import "HXTagAttribute.h"
#import "HXTagCollectionViewFlowLayout.h"
/// 搜索框
//#import "PYSearchViewController.h"
/// 极光推送相关头文件
// ... |
chimisgo/quickjs-android | quickjs/repl.c | /* File generated automatically by the QuickJS compiler. */
#include <inttypes.h>
const uint32_t qjsc_repl_size = 16086;
const uint8_t qjsc_repl[16086] = {
0x02, 0xa1, 0x03, 0x0e, 0x72, 0x65, 0x70, 0x6c,
0x2e, 0x6a, 0x73, 0x06, 0x73, 0x74, 0x64, 0x04,
0x6f, 0x73, 0x10, 0x69, 0x73, 0x46, 0x69, 0x6e,
0x69, 0x74, 0... |
chimisgo/quickjs-android | library/src/main/c/java-method.c | #include <string.h>
#include "java-method.h"
#include "java-helper.h"
// TODO append the java exception to the js exception
#define CHECK_JAVA_EXCEPTION_NO(ENV) \
do { \
if ((*(ENV))->ExceptionCheck(ENV)) { ... |
chimisgo/quickjs-android | quickjs/quickjs-patch.h | #ifndef QUICKJS_ANDROID_QUICKJS_PATCH_H
#define QUICKJS_ANDROID_QUICKJS_PATCH_H
#include "quickjs/quickjs.h"
int JS_IsArrayBuffer(JSContext *ctx, JSValueConst val);
#endif //QUICKJS_ANDROID_QUICKJS_PATCH_H
|
chimisgo/quickjs-android | quickjs/quickjs-patch.c | #include "quickjs/quickjs.c"
#include "quickjs-patch.h"
int JS_IsArrayBuffer(JSContext *ctx, JSValueConst val) {
if (JS_VALUE_GET_TAG(val) != JS_TAG_OBJECT) {
return FALSE;
}
JSObject *p = JS_VALUE_GET_OBJ(val);
return p->class_id == JS_CLASS_ARRAY_BUFFER || p->class_id == JS_CLASS_SHARED_ARR... |
chimisgo/quickjs-android | library/src/main/c/java-helper.c | #include <stdio.h>
#include "java-helper.h"
#define MAX_MSG_SIZE 1024
jint throw_exception(JNIEnv *env, const char *exception_name, const char *message, ...) {
char formatted_message[MAX_MSG_SIZE];
va_list va_args;
va_start(va_args, message);
vsnprintf(formatted_message, MAX_MSG_SIZE, message, va_arg... |
chimisgo/quickjs-android | quickjs/qjscalc.c | <filename>quickjs/qjscalc.c
/* File generated automatically by the QuickJS compiler. */
#include <inttypes.h>
const uint32_t qjsc_qjscalc_size = 31831;
const uint8_t qjsc_qjscalc[31831] = {
0x02, 0xba, 0x02, 0x0e, 0x49, 0x6e, 0x74, 0x65,
0x67, 0x65, 0x72, 0x0a, 0x46, 0x6c, 0x6f, 0x61,
0x74, 0x10, 0x46, 0x72, 0x61... |
danielxsr/matrix_calculator | script.c | #include <stdio.h>
int main () {
int l = 0, c = 0, escolha = 0;
int A[2][2], B[3][3];
int detA = 0, detB = 0, detBpos = 0, detBneg = 0;
printf("\nDeterminante de uma matriz");
printf("\nvoce quer calcular o determinante de uma matriz 2x2 ou 3x3 ?");
printf("\n[2] - 2x2 [3] 3x3\n");
scanf("... |
curiousleo/liquidhaskell | benchmarks/hmatrix-0.15.0.1/lib/Numeric/LinearAlgebra/LAPACK/lapack-aux.c | #include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>
#include <time.h>
#include "lapack-aux.h"
#define MACRO(B) do {B} while (0)
#define ERROR(CODE) MACRO(return CODE;)
#define REQUIRES(COND, CODE) MACRO(if(!(COND)) {ERROR(CODE);})
#define MIN(A,B) ((A)<(B)?(A):(B))
#define MAX(A,B) ((A)>(B)?(... |
curiousleo/liquidhaskell | benchmarks/bytestring-0.9.2.1/cbits/fpstring.c | /*
* Copyright (c) 2003 <NAME>
* Copyright (c) 2005-6 <NAME>
*
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
* ... |
curiousleo/liquidhaskell | benchmarks/base-4.5.1.0/include/EventConfig.h | <reponame>curiousleo/liquidhaskell<filename>benchmarks/base-4.5.1.0/include/EventConfig.h
/* include/EventConfig.h. Generated from EventConfig.h.in by configure. */
/* include/EventConfig.h.in. Generated from configure.ac by autoheader. */
/* Define if you have epoll support. */
#define HAVE_EPOLL 1
/* Define to ... |
curiousleo/liquidhaskell | benchmarks/base-4.5.1.0/include/ieee-flpt.h | <gh_stars>100-1000
/* this file is #included into both C (.c and .hc) and Haskell files */
/* IEEE format floating-point */
#define IEEE_FLOATING_POINT 1
/* Radix of exponent representation */
#ifndef FLT_RADIX
# define FLT_RADIX 2
#endif
/* Number of base-FLT_RADIX digits in the significand of a float */
... |
curiousleo/liquidhaskell | benchmarks/hmatrix-0.15.0.1/lib/Numeric/GSL/gsl-aux.c | #include <gsl/gsl_complex.h>
#define RVEC(A) int A##n, double*A##p
#define RMAT(A) int A##r, int A##c, double* A##p
#define KRVEC(A) int A##n, const double*A##p
#define KRMAT(A) int A##r, int A##c, const double* A##p
#define CVEC(A) int A##n, gsl_complex*A##p
#define CMAT(A) int A##r, int A##c, gsl_complex* A##p
#def... |
curiousleo/liquidhaskell | benchmarks/bytestring-0.9.2.1/include/fpstring.h |
void fps_reverse(unsigned char *dest, unsigned char *from, unsigned long len);
void fps_intersperse(unsigned char *dest, unsigned char *from, unsigned long len, unsigned char c);
unsigned char fps_maximum(unsigned char *p, unsigned long len);
unsigned char fps_minimum(unsigned char *p, unsigned long len);
unsigned... |
curiousleo/liquidhaskell | benchmarks/text-0.11.2.3/cbits/cbits.c | <reponame>curiousleo/liquidhaskell
/*
* Copyright (c) 2011 <NAME> <<EMAIL>>.
*
* Portions copyright (c) 2008-2010 <NAME> <<EMAIL>>.
*
* See http://bjoern.hoehrmann.de/utf-8/decoder/dfa/ for details.
*/
#include <string.h>
#include <stdint.h>
#include <stdio.h>
void _hs_text_memcpy(void *dest, size_t doff, const... |
curiousleo/liquidhaskell | benchmarks/hmatrix-0.15.0.1/lib/Numeric/GSL/gsl-ode.c | <filename>benchmarks/hmatrix-0.15.0.1/lib/Numeric/GSL/gsl-ode.c<gh_stars>100-1000
#ifdef GSLODE1
////////////////////////////// ODE V1 //////////////////////////////////////////
#include <gsl/gsl_odeiv.h>
typedef struct {int n; int (*f)(double,int, const double*, int, double *); int (*j)(double,int, const double*, ... |
curiousleo/liquidhaskell | benchmarks/vector-0.10.0.1/include/vector.h | #define PHASE_STREAM [1]
#define PHASE_INNER [0]
#define INLINE_STREAM INLINE PHASE_STREAM
#define INLINE_INNER INLINE PHASE_INNER
#ifndef NOT_VECTOR_MODULE
import qualified Data.Vector.Internal.Check as Ck
#endif
#define ERROR (Ck.error __FILE__ __LINE__)
#define INTERNAL_ERROR (Ck.internalError __FILE__... |
curiousleo/liquidhaskell | benchmarks/containers-0.5.0.0/include/Typeable.h | {- --------------------------------------------------------------------------
// Macros to help make Typeable instances.
//
// INSTANCE_TYPEABLEn(tc,tcname,"tc") defines
//
// instance Typeable/n/ tc
// instance Typeable a => Typeable/n-1/ (tc a)
// instance (Typeable a, Typeable b) => Typeable/n-2/ (tc ... |
curiousleo/liquidhaskell | benchmarks/base-4.5.1.0/cbits/PrelIOUtils.c | /*
* (c) The University of Glasgow 2002
*
* static versions of the inline functions in HsCore.h
*/
#define INLINE
#ifdef __GLASGOW_HASKELL__
# include "Rts.h"
#endif
#include "HsBase.h"
#ifdef __GLASGOW_HASKELL__
void errorBelch2(const char*s, char *t)
{
errorBelch(s,t);
}
void debugBelch2(const char*s, ... |
curiousleo/liquidhaskell | benchmarks/hmatrix-0.15.0.1/examples/devel/ej2/functions.c | /* general element order */
typedef struct { double r, i; } doublecomplex;
#define DVEC(A) int A##n, double*A##p
#define CVEC(A) int A##n, doublecomplex*A##p
#define DMAT(A) int A##r, int A##c, double*A##p
#define CMAT(A) int A##r, int A##c, doublecomplex*A##p
#define AT(M,r,c) (M##p[(r)*sr+(c)*sc])
int c_diag(i... |
curiousleo/liquidhaskell | benchmarks/base-4.5.1.0/include/WCsubst.h | <filename>benchmarks/base-4.5.1.0/include/WCsubst.h
#ifndef WCSUBST_INCL
#define WCSUBST_INCL
#include <stdlib.h>
int u_iswupper(int wc);
int u_iswdigit(int wc);
int u_iswalpha(int wc);
int u_iswcntrl(int wc);
int u_iswspace(int wc);
int u_iswprint(int wc);
int u_iswlower(int wc);
int u_iswalnum(int wc);
int u_tow... |
curiousleo/liquidhaskell | benchmarks/hmatrix-0.15.0.1/examples/devel/ej1/functions.c | /* assuming row order */
typedef struct { double r, i; } doublecomplex;
#define DVEC(A) int A##n, double*A##p
#define CVEC(A) int A##n, doublecomplex*A##p
#define DMAT(A) int A##r, int A##c, double*A##p
#define CMAT(A) int A##r, int A##c, doublecomplex*A##p
#define AT(M,row,col) (M##p[(row)*M##c + (col)])
/*-------... |
curiousleo/liquidhaskell | benchmarks/base-4.5.1.0/cbits/selectUtils.c | <reponame>curiousleo/liquidhaskell<gh_stars>100-1000
#include "HsBase.h"
void hsFD_ZERO(fd_set *fds) { FD_ZERO(fds); }
|
rgh000/maxhs-enqueue | maxhs/core/MaxSolver.h | <gh_stars>1-10
/***********[MaxSolver.h]
Copyright (c) 2012-2013 <NAME>, <NAME>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the rights to use,... |
rgh000/maxhs-enqueue | maxhs/utils/io.h | <reponame>rgh000/maxhs-enqueue
/***********[io.h]
Copyright (c) 2012-2013 <NAME>, <NAME>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the right... |
rgh000/maxhs-enqueue | maxhs/ifaces/Cplex.h | /***********[Cplex.h]
Copyright (c) 2012-2013 <NAME>, <NAME>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merg... |
rgh000/maxhs-enqueue | maxhs/utils/Params.h | <filename>maxhs/utils/Params.h
/***********[Params.h]
Copyright (c) 2012-2013 <NAME>, <NAME>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the r... |
saisankargochhayat/algo_quest | Misc/insertion_sort.c | <gh_stars>1-10
#include <iostream>
using namespace std;
int main()
{
int a[],i,j,k,n;
cin>>n;
cout<<"enter the elements";
for(i=0;i<n;i++)
{
cin>>a[i];
}
for(int j=2;j<a.length();j++)
{
k=a[j];
i=j-1;
while((i>0)&&(a[i]>k))
{
... |
JoyIfBam5/curl-asio | include/curl-asio/socket_info.h | /**
curl-asio: wrapper for integrating libcurl with boost.asio applications
Copyright (c) 2013 <NAME> <<EMAIL>>
See COPYING for license information.
*/
#pragma once
#include <boost/asio.hpp>
#include <boost/enable_shared_from_this.hpp>
#include <boost/scoped_ptr.hpp>
#include <memory>
namespace curl
... |
JoyIfBam5/curl-asio | include/curl-asio/form.h | /**
curl-asio: wrapper for integrating libcurl with boost.asio applications
Copyright (c) 2013 <NAME> <<EMAIL>>
See COPYING for license information.
C++ wrapper for constructing libcurl forms
*/
#pragma once
#include "config.h"
#include <boost/enable_shared_from_this.hpp>
#include <boost/noncopyable.... |
RaneWallin/bf_interpreter | bf.c | /*
* bf.c - <NAME>
*
* A brainf**k interpreter that processes code written in brainf**k
*
* Copyright 2019 <<EMAIL>>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version... |
burner/playwright | browser_patches/firefox-beta/juggler/screencast/HeadlessWindowCapturer.h | <reponame>burner/playwright
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#pragma once
#include <memory>
#include <set>
#include "api/video/video_frame.h"
#inc... |
ClearDotX/FreeRTOS-Kernel | portable/ThirdParty/GCC/Wiced_CY/portmacro.h | <filename>portable/ThirdParty/GCC/Wiced_CY/portmacro.h
/*
* FreeRTOS Kernel V10.2.0
* Copyright (C) 2017 Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Softwa... |
STMicroelectronics/ts3510 | ts3510.h | <gh_stars>1-10
/**
******************************************************************************
* @file ts3510.h
* @author MCD Application Team
* @brief This file contains all the functions prototypes for the
* ts3510.c Touch Screen driver.
********************************************************... |
STMicroelectronics/ts3510 | ts3510_reg.h | /**
******************************************************************************
* @file ts3510_reg.h
* @author MCD Application Team
* @brief Header of ts3510_reg.c
*
******************************************************************************
* @attention
*
* <h2><center>© Copyrigh... |
lingxun-cpp/spider001 | code/html_parse/std.h | <gh_stars>0
#pragma once
#include <iostream>
#include <regex>
#include "base_i.h"
#include "html_parse_i.h"
using namespace std;
using namespace Example;
|
lingxun-cpp/spider001 | code/spider_main/inf_run.h | <gh_stars>0
#pragma once
namespace Example{
class Inf_run : public ISpiderMain
{
public:
Inf_run(const char* path_input);
void Run(const char* domain, const char* key) override;
string path;
};
}
|
lingxun-cpp/spider001 | code/file_down/Ifile_down.h | <gh_stars>0
#pragma once
class Ifile_down : public IFileDown
{
public:
Ifile_down(const char* path_input);
bool SetDomain(const char* domain);
bool DownFile(const char* SyncHttpGet, int len);
bool SaveDownFile(const char* file, const char* context, int len);
strin... |
lingxun-cpp/spider001 | code/spider_main/std.h | #pragma once
#pragma GCC system_header
#include <string>
#include <stdexcept>
#include <iostream>
#include <iomanip>
using namespace std;
#include "load_library.h"
#include "base_i.h"
#include "util_i.h"
#include "util_action_i.h"
#include "spider_main_i.h"
#include "url_manager_i.h"
#include "http_get... |
lingxun-cpp/spider001 | code/http_get/http_get.h | <filename>code/http_get/http_get.h
#pragma once
#include "http_get_i.h"
namespace Example
{
class http_get:public IHttpGet
{
public:
http_get(INetAction& inetAtion) :m_pacong(inetAtion){};
const char* SyncHttpGet(int& len, const char* domain, const char* path);
private:
INetAction & ... |
ptrrkssn/pnscan | pnscan.c | <filename>pnscan.c<gh_stars>100-1000
/*
** pnscan.c - Parallell Network Scanner
**
** Copyright (c) 2002-2020, <NAME> <<EMAIL>>
** All rights reserved.
**
** Redistribution and use in source and binary forms, with or without
** modification, are permitted provided that the following conditions are met:
**
** 1. Redis... |
ptrrkssn/pnscan | t_listen.c | <reponame>ptrrkssn/pnscan
/*
** t_listen.c - Test daemon for pnscan
**
** Copyright (c) 2002-2020, <NAME> <<EMAIL>>
** All rights reserved.
**
** Redistribution and use in source and binary forms, with or without
** modification, are permitted provided that the following conditions are met:
**
** 1. Redistributions o... |
ptrrkssn/pnscan | bm.c | /*
** bm.c - Boyer-Moore string search
**
** Copyright (c) 2002-2020, <NAME> <<EMAIL>>
** All rights reserved.
**
** Redistribution and use in source and binary forms, with or without
** modification, are permitted provided that the following conditions are met:
**
** 1. Redistributions of source code must retain the... |
Dina-Nashaat/Server-Client | Server-Client/Client/RequestsProvider.h | <filename>Server-Client/Client/RequestsProvider.h
#pragma once
#include <array>
#include <iostream>
using namespace std;
vector<string> getRequests() {
vector<string> requests;
requests.push_back("GET report.pdf hostname");
//requests.push_back("GET brush2.gif hostname");
return requests;
}
|
Dina-Nashaat/Server-Client | Server-Client/Client/helper.h | #pragma once
#include <vector>
#include <iostream>
#include <string>
#include <sstream>
#include <array>
#include <fstream>
#define _CRT_SECURE_NO_WARNINGS
using namespace std;
array<string, 3> parseRequest(string request)
{
array<string, 3> requestParams;
stringstream ss(request);
string token;
int i = 0;
whi... |
nanshuii/TurnTable | TurnTable/TurnTable/Main/LENColorSelectViewController.h | <filename>TurnTable/TurnTable/Main/LENColorSelectViewController.h<gh_stars>0
//
// LENColorSelectViewController.h
// TurnTable
//
// Created by 林南水 on 2019/7/12.
// Copyright © 2019 ledon. All rights reserved.
//
#import <UIKit/UIKit.h>
NS_ASSUME_NONNULL_BEGIN
@interface LENColorSelectViewController : UIViewCont... |
nanshuii/TurnTable | TurnTable/TurnTable/Model/LENHandle.h | <reponame>nanshuii/TurnTable
//
// LENHandle.h
// TurnTable
//
// Created by 林南水 on 2019/7/10.
// Copyright © 2019 ledon. All rights reserved.
//
#import <Foundation/Foundation.h>
NS_ASSUME_NONNULL_BEGIN
typedef void(^AlertTextFieldBlock)(NSString *text);
@interface LENHandle : NSObject
/**
获取罗盘列表
@return re... |
nanshuii/TurnTable | TurnTable/TurnTable/Model/LENTurnTableModel.h | //
// LENTurnTableModel.h
// TurnTable
//
// Created by 林南水 on 2019/7/10.
// Copyright © 2019 ledon. All rights reserved.
//
#import <Foundation/Foundation.h>
NS_ASSUME_NONNULL_BEGIN
@interface LENTurnTableModel : NSObject
@property (nonatomic, copy) NSString *t_id;
@property (nonatomic, copy) NSString *name;
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.