repo_name
stringlengths
6
97
path
stringlengths
3
341
text
stringlengths
8
1.02M
Extended-Object-Detection-ROS/extended_object_detection
src/lib/utils/include/geometry_utils.h
<gh_stars>10-100 #ifndef _GEOMETRY_UTILS_ #define _GEOMETRY_UTILS_ #include <opencv2/opencv.hpp> #include <math.h> #include <vector> #include "ExtendedObjectInfo.h" namespace eod{ cv::Rect2d rect2rect2d(cv::Rect src); cv::Rect rect2d2rect(cv::Rect2d src); double intersectionOverUnion(cv::Re...
Extended-Object-Detection-ROS/extended_object_detection
src/lib/include/ObjectIdentifier.h
#ifndef _OBJECT_IDENTIFIER_ #define _OBJECT_IDENTIFIER_ #include <stdio.h> #include <vector> #include <iostream> #include <string> #include <opencv2/opencv.hpp> #include "opencv2/objdetect/objdetect.hpp" #include "opencv2/highgui/highgui.hpp" #include "opencv2/imgproc/imgproc.hpp" #include "ExtendedObje...
Extended-Object-Detection-ROS/extended_object_detection
src/lib/types/include/ComplexObjectGraph.h
<reponame>Extended-Object-Detection-ROS/extended_object_detection #ifndef COMPLEX_OBJECT_GRAPH_H_ #define COMPLEX_OBJECT_GRAPH_H_ #include "SimpleObject.h" #include "Relationship.h" #include "igraph.h" namespace eod{ class Graph{ public: Graph(); int add_vectice(std::str...
Extended-Object-Detection-ROS/extended_object_detection
src/lib/types/include/ComplexObject.h
<gh_stars>10-100 /* Project: Object Detection Lib Author: <NAME> File: Scene detection mechanism using theory of Subdefenite Models. */ #ifndef COMPLEX_OBJECT_H_ #define COMPLEX_OBJECT_H_ //#include "ObjectIdentifier.h" #include "SimpleObject.h" #include "Relationship.h" #include <chrono> namespace eod { cl...
Extended-Object-Detection-ROS/extended_object_detection
src/lib/detectors/include/QrZbarDetector.h
#ifndef _QR_ZBAR_ATTRIBUTE_ #define _QR_ZBAR_ATTRIBUTE_ #include "Attribute.h" #include <zbar.h> namespace eod{ class QrZbarAttribute : public Attribute{ public: QrZbarAttribute(); QrZbarAttribute(double real_len, std::string info); std::vector<ExtendedObjectInfo> Detect2...
Extended-Object-Detection-ROS/extended_object_detection
src/lib/relations/include/SizeRelations.h
#ifndef SIZERELATIONS_H #define SIZERELATIONS_H #include "Relationship.h" namespace eod{ // Same class SizeSameRelation : public RelationShip{ public: SizeSameRelation(); SizeSameRelation(double error); bool checkRelation(const cv::Mat& image, ExtendedObjectInfo* A, Exten...
Extended-Object-Detection-ROS/extended_object_detection
src/lib/detectors/include/FaceDlibDetector.h
<reponame>Extended-Object-Detection-ROS/extended_object_detection #ifndef _FACE_DLIB_ATTRIBUTE_ #define _FACE_DLIB_ATTRIBUTE_ #include "Attribute.h" #include <dlib/image_processing/frontal_face_detector.h> #include <dlib/dnn.h> template <template <int,template<typename>class,int,typename> class block, int N, templat...
jjschweigertspersonalcollaborators/NetworkStack
NetworkStack/Base.h
<gh_stars>0 #ifndef BASE_H #define BASE_H class Base { public: public virtual void ToString(); private: protected: }; #endif // BASE_H
kosua20/BacteriaGeneration
src/helpers/GLUtilities.h
<reponame>kosua20/BacteriaGeneration<gh_stars>1-10 #ifndef ProgramUtilities_h #define ProgramUtilities_h #include <gl3w/gl3w.h> #include <string> #include <vector> #include "MeshUtilities.h" /// This macro is used to check for OpenGL errors with access to the file and line number where the error is detected. #define ...
kosua20/BacteriaGeneration
src/Renderer.h
<filename>src/Renderer.h #ifndef Renderer_h #define Renderer_h #include <gl3w/gl3w.h> #include <GLFW/glfw3.h> #include <glm/glm.hpp> #include <memory> #include "helpers/GenerationUtilities.h" #include "BacteriaScene.h" #include "Framebuffer.h" #include "Blur.h" #include "camera/Camera.h" #include "ScreenQuad.h" clas...
kosua20/BacteriaGeneration
src/Bacterium.h
<reponame>kosua20/BacteriaGeneration #ifndef Bacteria_h #define Bacteria_h #include <gl3w/gl3w.h> #include <GLFW/glfw3.h> #include <glm/glm.hpp> #include "helpers/ResourcesManager.h" class Bacterium { public: Bacterium(const int capId, const glm::vec3 & pos, const glm::vec3 & sca, const glm::vec3 & col, const ...
kosua20/BacteriaGeneration
src/Blur.h
<filename>src/Blur.h #ifndef Blur_h #define Blur_h #include <gl3w/gl3w.h> #include <glm/glm.hpp> #include <memory> #include "Framebuffer.h" #include "ScreenQuad.h" class Blur { public: ~Blur(); /// Init function Blur(int width, int height, int depth); /// Draw function void process(const GLuint textureId); ...
ctu-mrs/mrs_rviz_plugins
include/sphere/visual.h
// clang: MatousFormat #ifndef SPHERE_H #define SPHERE_H #include <mrs_msgs/Sphere.h> #include <OGRE/OgreCamera.h> #include <OGRE/OgreVector3.h> #include <OGRE/OgreSceneNode.h> #include <OGRE/OgreSceneManager.h> #include <OGRE/OgreManualObject.h> #include <rviz/message_filter_display.h> #include <rviz/view_manager.h...
ctu-mrs/mrs_rviz_plugins
include/bumper/display.h
// clang: MatousFormat #ifndef MRS_BUMPER_DISPLAY_H #define MRS_BUMPER_DISPLAY_H #ifndef Q_MOC_RUN #include <boost/circular_buffer.hpp> #include <rviz/message_filter_display.h> #include <mrs_msgs/ObstacleSectors.h> #endif namespace Ogre { class SceneNode; } namespace rviz { class ColorProperty; class EnumPro...
ctu-mrs/mrs_rviz_plugins
include/covariance/property.h
<reponame>ctu-mrs/mrs_rviz_plugins<filename>include/covariance/property.h #ifndef COVARIANCE_PROPERTY_H #define COVARIANCE_PROPERTY_H #include <QColor> #include <OgreColourValue.h> #include <rviz/properties/bool_property.h> #include <covariance/visual.h> namespace Ogre { class SceneManager; class SceneNode; } // ...
ctu-mrs/mrs_rviz_plugins
include/track_array/display.h
<filename>include/track_array/display.h #pragma once #include <string> #include <ros/ros.h> #include <boost/shared_ptr.hpp> #include <mrs_msgs/Track.h> #include <mrs_msgs/TrackArrayStamped.h> #include <geometry_msgs/Pose.h> #include <geometry_msgs/Vector3.h> #include <rviz/message_filter_display.h> #include <rvi...
ctu-mrs/mrs_rviz_plugins
include/pose_with_covariance_array/display.h
#ifndef POSE_WITH_COVARIANCE_DISPLAY_H #define POSE_WITH_COVARIANCE_DISPLAY_H #include <boost/shared_ptr.hpp> #include <mrs_msgs/PoseWithCovarianceArrayStamped.h> #include <rviz/message_filter_display.h> #include <rviz/selection/forwards.h> #include <covariance/property.h> #include <covariance/visual.h> namespace ...
ctu-mrs/mrs_rviz_plugins
include/bumper/visual.h
// clang: MatousFormat #ifndef MRS_BUMPER_VISUAL_H #define MRS_BUMPER_VISUAL_H #include <mrs_msgs/ObstacleSectors.h> namespace Ogre { class Vector3; class Quaternion; } // namespace Ogre namespace rviz { class Arrow; class MeshShape; class Object; } // namespace rviz namespace mrs_rviz_plugins { nam...
thiolliere/sudoku-solver
verification.c
#include <stdlib.h> #include <stdbool.h> #include "verification.h" bool fini(int sudoku[]){ for ( int i=0 ; i<9 ; i++ ){ for ( int j=0 ; j<9 ; j++ ){ if (sudoku[i*9+j]==0){ return false; } } } return true; } void validerligne(int sudoku[],bool *valide){ for ( int i=0 ; i<9 ; i++ ){ bool memoire[10...
thiolliere/sudoku-solver
sudokusolver.c
#include <stdlib.h> #include <stdio.h> #include <stdint.h> #include <stdbool.h> #include "interface_io.h" #include "verification.h" int sudoku[81]; bool sudokupossible[81][9]; void placer(int num,int lig, int col){ for (int m=0; m<9; m++){ sudokupossible[lig*9+col][m]=false; } for (int i=0; i<9; i++){ sudokup...
thiolliere/sudoku-solver
interface_io.h
<reponame>thiolliere/sudoku-solver<filename>interface_io.h<gh_stars>0 #ifndef __interface_io__ #define __interface_io__ extern void afficher (int sudoku[]); extern void ecrire (int sudoku[]); #endif
thiolliere/sudoku-solver
verification.h
#ifndef __verif__ #define __verif__ #include <stdbool.h> extern bool fini(int sudoku[]); extern bool valider(int sudoku[]); #endif
thiolliere/sudoku-solver
interface_io.c
#include <stdlib.h> #include <stdio.h> #include "interface_io.h" void afficher (int sudoku[]){ for ( int i=0 ; i<9 ; i++ ){ for ( int j=0 ; j<9 ; j++ ){ if (j%3 == 2 ){ printf("%d|",sudoku[i*9+j]); }else if (i%3==2) { printf("%d_",sudoku[i*9+j]); }else{ printf("%d ",sudoku[i*9+j]); } } p...
CJBuchel/UDP_TransferNT
UDP_TransferNT/include/Serializer.h
#ifndef SERIALIZER_H #define SERIALIZER_H #include "nt_headers.h" #include "Datapacket.h" namespace UDP_TransferNT { class Serializer { public: /** * Serial cycler. Serialize data type arrays [T] into byte stream [V] */ template <typename T, typename V> static T *serialCycler(T *singleDT, V *data, boo...
CJBuchel/UDP_TransferNT
UDP_TransferNT/include/Datapacket.h
#ifndef DATAPACKET_H #define DATAPACKET_H #include "nt_headers.h" #define DP_CHECK_SCOPE(x, v, code) if (x > (DATAPACKET_TYPESIZE)/sizeof(v)) { DEFAULT_NT_LOGGER("INDEX OUT OF SCOPE, index: " + std::to_string(x) + ", max index: " + std::to_string((DATAPACKET_TYPESIZE)/sizeof(v))); } else { code } namespace UDP_Tran...
CJBuchel/UDP_TransferNT
UDP_TransferNT/include/nt_platform.h
#ifndef NT_PLATFORM_H #define NT_PLATFORM_H #ifdef _WIN32 #define NT_UDP_PLATFORM_WINDOWS #elif defined(__linux__) #define NT_UDP_PLATFORM_LINUX #elif defined (__APPLE__) || defined(__MACH__) #include <TargetConditionals.h> #if TARGET_IPHONE_SIMULATOR == 1 #error "IOS simulator is not supported!" #elif TARGE...
CJBuchel/UDP_TransferNT
UDP_TransferNT/include/nt_headers.h
#ifndef NT_HEADERS_H #define NT_HEADERS_H #include "nt_platform.h" #include <string> #include <iostream> #include <typeinfo> #ifdef DISABLE_NT_LOGGER #define DEFAULT_NT_LOGGER(x) #else // override if you have a proper logger. E.g spdlog #ifndef DEFAULT_NT_LOGGER #define DEFAULT_NT_LOGGER(x) std::cout << x << std:...
CJBuchel/UDP_TransferNT
UDP_TransferNT/include/UDP_TransferNT.h
<filename>UDP_TransferNT/include/UDP_TransferNT.h #ifndef UDP_TRANSFER_NT_H #define UDP_TRANSFER_NT_H #include "Network.h" #endif
CJBuchel/UDP_TransferNT
UDP_TransferNT/include/Network.h
<reponame>CJBuchel/UDP_TransferNT<gh_stars>0 #ifndef NETWORK_H #define NETWORK_H #include "Serializer.h" #include "Socket.h" namespace UDP_TransferNT { class Network : public Serializer { public: /** * Network Type */ enum class Type { SERVER = 0, CLIENT }; /** * Connection type * Meant...
CJBuchel/UDP_TransferNT
UDP_TransferNT/include/Socket.h
#ifndef SOCKET_H #define SOCKET_H #include "nt_headers.h" namespace UDP_TransferNT { /** * Cross platform socket wrapper. Used as main socket for network. */ class Socket { public: /** * Set the port of the socket */ void setPort(int port) { _port = port; } /** * Set the ip of the socke...
MarioMatschgi/Arduino
Projects/2021-03-11_test_serial_communication/src/USART.c
/***************************************************************************/ /** Implementation file for USART on ATMEL-Controller with one or more uarts @author LiTec/PAMG @date 17.10.2012 @version 1.2 @param compiler switches: none @param linker switches: none @b History: - 1.2 LiTec/PAMG 17.10.2012 En...
betrusted-io/prjxray
lib/include/prjxray/xilinx/bitstream_reader.h
<reponame>betrusted-io/prjxray #ifndef PRJXRAY_LIB_XILINX_BITSTREAM_READER_H #define PRJXRAY_LIB_XILINX_BITSTREAM_READER_H #include <algorithm> #include <iostream> #include <memory> #include <vector> #include <absl/types/span.h> #include <prjxray/big_endian_span.h> #include <prjxray/xilinx/architectures.h> #include ...
betrusted-io/prjxray
lib/include/prjxray/memory_mapped_file.h
#ifndef PRJXRAY_LIB_MEMORY_MAPPED_FILE #define PRJXRAY_LIB_MEMORY_MAPPED_FILE #include <memory> #include <string> #include <absl/types/span.h> namespace prjxray { class MemoryMappedFile { public: ~MemoryMappedFile(); static std::unique_ptr<MemoryMappedFile> InitWithFile( const std::string& path); v...
betrusted-io/prjxray
lib/include/prjxray/xilinx/architectures.h
#ifndef PRJXRAY_LIB_XILINX_ARCHITECTURES_H_ #define PRJXRAY_LIB_XILINX_ARCHITECTURES_H_ #include <absl/types/variant.h> #include <memory> #include <vector> #include <prjxray/xilinx/configuration_packet.h> #include <prjxray/xilinx/spartan6/frame_address.h> #include <prjxray/xilinx/spartan6/part.h> #include <prjxray/xi...
betrusted-io/prjxray
lib/include/prjxray/xilinx/spartan6/frame_address.h
<reponame>betrusted-io/prjxray #ifndef PRJXRAY_LIB_XILINX_SPARTAN6_FRAME_ADDRESS_H_ #define PRJXRAY_LIB_XILINX_SPARTAN6_FRAME_ADDRESS_H_ #include <cstdint> #include <ostream> #include <prjxray/xilinx/spartan6/block_type.h> #include <yaml-cpp/yaml.h> #ifdef _GNU_SOURCE #undef minor #endif namespace prjxray { namespa...
betrusted-io/prjxray
lib/include/prjxray/database.h
#ifndef PRJXRAY_LIB_DATABASE_H #define PRJXRAY_LIB_DATABASE_H #include <memory> #include <string> #include <vector> #include <prjxray/segbits_file_reader.h> namespace prjxray { class Database { public: Database(const std::string& path) : db_path_(path) {} std::vector<std::unique_ptr<SegbitsFileReader>> se...
betrusted-io/prjxray
lib/include/prjxray/xilinx/configuration_register.h
<reponame>betrusted-io/prjxray<gh_stars>1-10 #ifndef PRJXRAY_LIB_XILINX_CONFIGURATION_REGISTER_H_ #define PRJXRAY_LIB_XILINX_CONFIGURATION_REGISTER_H_ #include <ostream> namespace prjxray { namespace xilinx { // Spartan6 configuration register addresses // according to UG380, pg. 100 enum class Spartan6Configuration...
betrusted-io/prjxray
lib/include/prjxray/xilinx/xc7series/frame_address.h
#ifndef PRJXRAY_LIB_XILINX_XC7SERIES_FRAME_ADDRESS_H_ #define PRJXRAY_LIB_XILINX_XC7SERIES_FRAME_ADDRESS_H_ #include <cstdint> #include <ostream> #include <prjxray/xilinx/xc7series/block_type.h> #include <yaml-cpp/yaml.h> #ifdef _GNU_SOURCE #undef minor #endif namespace prjxray { namespace xilinx { namespace xc7ser...
betrusted-io/prjxray
lib/include/prjxray/xilinx/xc7series/ecc.h
<reponame>betrusted-io/prjxray #ifndef PRJXRAY_LIB_XILINX_XC7SERIES_ECC_H_ #define PRJXRAY_LIB_XILINX_XC7SERIES_ECC_H_ #include <cstdint> #include <vector> namespace prjxray { namespace xilinx { namespace xc7series { // Extend the current ECC code with one data word (32 bit) at a given // word index in the configura...
betrusted-io/prjxray
lib/include/prjxray/xilinx/spartan6/configuration_row.h
#ifndef PRJXRAY_LIB_XILINX_SPARTAN6_ROW_H_ #define PRJXRAY_LIB_XILINX_SPARTAN6_ROW_H_ #include <algorithm> #include <cassert> #include <map> #include <memory> #include <absl/types/optional.h> #include <prjxray/xilinx/spartan6/block_type.h> #include <prjxray/xilinx/spartan6/configuration_bus.h> #include <prjxray/xilin...
fabianrost84/clasim
src/types.h
// types.h #ifndef TYPES_H #define TYPES_H #include <vector> #include <iostream> typedef float REAL; #include "rand.h" typedef struct t_InitParameter{ int nAnimals; int nCells; int mCells; REAL GF; REAL sPopulation; REAL sAnimal; REAL Tc; REAL fG1; REAL fS; REAL fG2M; URNG...
fabianrost84/clasim
src/rand.h
<gh_stars>1-10 // rand.h #ifndef RAND_H #define RAND_H #include <gsl/gsl_rng.h> #include <gsl/gsl_randist.h> #define URNG generator class generator{ const gsl_rng_type * T; public: gsl_rng * r; generator(); ~generator(); void seed(unsigned long int s); }; #include "types.h" class r_lognorm{...
fabianrost84/clasim
src/cell.h
<gh_stars>1-10 // cell.h #ifndef CELL_H #define CELL_H #include "types.h" #include <vector> #include <array> class cell_base { protected: int Index; int Mother; t_InitParameter& rInitParameter; REAL InitAge; int Label; REAL KillTime; REAL Tc; int GF; REAL fG1; REAL fS; REA...
fabianrost84/clasim
src/sample.h
<filename>src/sample.h // sample.h #ifndef ANIMAL_H #define ANIMAL_H #include "types.h" #include <vector> #include <array> #include <random> #include "cell.h" template < typename cell_type> class sample { URNG& RandGenerator; t_InitParameter& rInitParameter; REAL KillTime; REAL AnimalTc; std::vect...
delan/hammertime
datalink.c
<reponame>delan/hammertime<gh_stars>0 #include "datalink.h" #include <string.h> #include "util.h" #include "assignment.h" #include "network.h" void cc200_datalink_from_network(cc200_packet_t packet) { int link = cc200_routing_table[packet.source][packet.destination]; CC200_PRINT( "data " CC200_SEQ CC200_TO CC200...
delan/hammertime
datalink.h
<gh_stars>0 #ifndef CC200_DATALINK_H #define CC200_DATALINK_H #include "type.h" #include "physical.h" void cc200_datalink_from_network(cc200_packet_t packet); void cc200_datalink_data_next(int link); void cc200_datalink_ack(cc200_byte sequence_number, int link); void cc200_datalink_from_physical(cc200_frame_t fram...
delan/hammertime
assignment.h
#ifndef CC200_ASSIGNMENT_H #define CC200_ASSIGNMENT_H #include <cnet.h> #include "type.h" #include "list.h" #define CC200_NODES 5 extern int cc200_routing_table[CC200_NODES][CC200_NODES]; extern cc200_byte cc200_next_seq_to_send[CC200_NODES]; extern cc200_byte cc200_next_data_seq_expected[CC200_NODES]; extern cc20...
delan/hammertime
util.h
#ifndef CC200_UTIL_H #define CC200_UTIL_H #include <stdlib.h> #include <inttypes.h> #include <unistd.h> #define CC200_UNUSED(NAME) do { \ ((void) sizeof(NAME)); \ } while (0) #define CC200_PRINT_ARGS(FORMAT, ...) ...
delan/hammertime
network.c
#include "network.h" #include <string.h> #include "util.h" #include "datalink.h" #include "application.h" void cc200_network_from_application( CnetAddr source, CnetAddr destination, cc200_byte *payload, cc200_byte len ) { cc200_packet_t packet; packet.source = source; packet.destination = destination; packet...
delan/hammertime
assignment.c
<gh_stars>0 #include "assignment.h" #include <stdint.h> #include <stdlib.h> #include <string.h> #include "util.h" #include "physical.h" #include "datalink.h" #include "application.h" int cc200_routing_table[CC200_NODES][CC200_NODES] = { { 0, 1, 2, 3, 4 }, { 1, 0, 2, 1, 1 }, { 1, 2, 0, 1, 1 }, { 1, 1, 1, 0, 2 }, ...
delan/hammertime
network.h
#ifndef CC200_NETWORK_H #define CC200_NETWORK_H #include <cnet.h> #include "type.h" void cc200_network_from_application( CnetAddr source, CnetAddr destination, cc200_byte *payload, cc200_byte len ); void cc200_network_from_datalink(cc200_packet_t packet); #endif
delan/hammertime
application.h
#ifndef CC200_APPLICATION_H #define CC200_APPLICATION_H #include <cnet.h> #include "type.h" EVENT_HANDLER(cc200_application_ready); void cc200_application_from_network(cc200_byte *payload, cc200_byte len); #endif
delan/hammertime
physical.h
<gh_stars>0 #ifndef CC200_PHYSICAL_H #define CC200_PHYSICAL_H #include <cnet.h> #include "type.h" EVENT_HANDLER(cc200_physical_ready); void cc200_physical_from_datalink(cc200_frame_t frame, int link); #endif
delan/hammertime
physical.c
<reponame>delan/hammertime<filename>physical.c #include "physical.h" #include <stdlib.h> #include "util.h" #include "assignment.h" #include "datalink.h" EVENT_HANDLER(cc200_physical_ready) { int link; cc200_frame_t frame; size_t len = sizeof(frame); CC200_CHECK(CNET_read_physical(&link, &frame, &len)); CC200_PR...
delan/hammertime
application.c
#include "application.h" #include <stdlib.h> #include "type.h" #include "util.h" #include "network.h" EVENT_HANDLER(cc200_application_ready) { CnetAddr dest; cc200_byte payload[CC200_MAX_APPLICATION]; size_t len = CC200_MAX_APPLICATION; CC200_CHECK(CNET_read_application(&dest, payload, &len)); CC200_PRINT( "%...
delan/hammertime
list.h
#ifndef CC200_LIST_H #define CC200_LIST_H #include <stddef.h> #include "type.h" typedef struct cc200_list_node { cc200_frame_t data; struct cc200_list_node *prev; struct cc200_list_node *next; } *cc200_list_node; typedef struct cc200_list { size_t count; cc200_list_node head; cc200_list_node tail; } *cc200_li...
delan/hammertime
list.c
#include "list.h" #include <stdlib.h> cc200_list_node cc200_list_node_new(cc200_frame_t data) { cc200_list_node node = malloc(sizeof(struct cc200_list_node)); node->data = data; node->prev = NULL; node->next = NULL; return node; } void cc200_list_node_free(cc200_list_node node) { free(node); } cc200_list cc20...
delan/hammertime
type.h
<reponame>delan/hammertime<filename>type.h #ifndef CC200_TYPE_H #define CC200_TYPE_H #include <cnet.h> #include <stdint.h> #define CC200_MAX_APPLICATION 255 typedef enum cc200_frame_type { CC200_DATA, CC200_ACK } cc200_frame_type_t; typedef uint8_t cc200_byte; typedef struct cc200_packet { CnetAddr source; Cne...
sbgisen/rviz_satellite
src/aerialmap_display.h
<filename>src/aerialmap_display.h /* Copyright 2014 <NAME> Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to...
jdwapman/gunrock
unittests/test_binarysearch.h
/* * @brief Unit test for BinarySearch * @file test_binarysearch.cuh */ #include <examples/core/test_binarysearch.cuh> using namespace gunrock; TEST(utils, BinarySearch) { cudaError_t retval = BinarySearchTest(); EXPECT_EQ(retval, cudaSuccess); }
jdwapman/gunrock
gunrock/util/basic_utils.h
// ---------------------------------------------------------------- // Gunrock -- Fast and Efficient GPU Graph Library // ---------------------------------------------------------------- // This source code is distributed under the terms of LICENSE.TXT // in the root directory of this source distribution. // ----------...
jdwapman/gunrock
unittests/test_lib_sm.h
<reponame>jdwapman/gunrock<gh_stars>1-10 /* * @brief Subgraph matching test for shared library advanced interface * @file test_lib_sm.h */ TEST(sharedlibrary, sm) { int num_data_nodes = 5, num_data_edges = 10; int data_row_offsets[6] = {0, 2, 6, 7, 9, 10}; int data_col_indices[10] = {1, 3, 0, 2, 3, 4, 1, 0, 1...
jdwapman/gunrock
gunrock/util/gitsha1make.c
#ifndef GIT_SHA1 #define GIT_SHA1 "GIT-SHA-NOT-FOUND" #endif const char g_GIT_SHA1[] = GIT_SHA1;
jdwapman/gunrock
unittests/test_lib_pr.h
/* * @brief PageRank test for shared library advanced interface * @file test_lib_pr.h */ TEST(sharedlibrary, pagerank) { int num_nodes = 7, num_edges = 26; int row_offsets[8] = {0, 3, 6, 11, 15, 19, 23, 26}; int col_indices[26] = {1, 2, 3, 0, 2, 4, 0, 1, 3, 4, 5, 0, 2, 5, 6, 1, 2, 5...
jdwapman/gunrock
gunrock/gunrock.h
// ---------------------------------------------------------------------------- // Gunrock -- Fast and Efficient GPU Graph Library // ---------------------------------------------------------------------------- // This source code is distributed under the terms of LICENSE.TXT // in the root directory of this source dis...
jdwapman/gunrock
unittests/test_repeatfor.h
/* * @brief Unit test for RepeatFor * @file test_repeatfor.cuh */ #include <examples/core/test_for.cuh> using namespace gunrock; TEST(operators, RepeatFor) { cudaError_t retval = RepeatForTest(); EXPECT_EQ(retval, cudaSuccess); }
jdwapman/gunrock
gunrock/util/json_spirit_writer_options.h
<gh_stars>100-1000 #ifndef JSON_SPIRIT_WRITER_OPTIONS #define JSON_SPIRIT_WRITER_OPTIONS // Copyright <NAME> 2007 - 2014 // Distributed under the MIT License, see accompanying file LICENSE.txt // json spirit version 4.08 #if defined(_MSC_VER) && (_MSC_VER >= 1020) #pragma once #endif namespace ...
jdwapman/gunrock
unittests/test_pointer_location.h
<gh_stars>100-1000 /* * @brief Test to determine the location (device or host) of memory * @file test_pointer_location.h */ #include <gunrock/util/test_utils.h> TEST(utils, PointerLocation) { using namespace gunrock::util; // // pointers to host memory int x = 10; auto host_ptr = &x; ...
jdwapman/gunrock
gunrock/util/sysinfo_rapidjson.h
<gh_stars>100-1000 // ---------------------------------------------------------------- // Gunrock -- Fast and Efficient GPU Graph Library // ---------------------------------------------------------------- // This source code is distributed under the terms of LICENSE.TXT // in the root directory of this source distribu...
jdwapman/gunrock
unittests/test_segreduce.h
<filename>unittests/test_segreduce.h /* * @brief Unit test for RepeatFor * @file test_segreduce.h */ #include <examples/core/test_segreduce.cuh> using namespace gunrock; TEST(operators, SegReduce) { cudaError_t retval = SegReduceTest(); EXPECT_EQ(retval, cudaSuccess); }
jdwapman/gunrock
gunrock/util/random_bits.h
<filename>gunrock/util/random_bits.h // ---------------------------------------------------------------- // Gunrock -- Fast and Efficient GPU Graph Library // ---------------------------------------------------------------- // This source code is distributed under the terms of LICENSE.TXT // in the root directory of th...
jdwapman/gunrock
gunrock/util/gitsha1.h
extern const char g_GIT_SHA1[];
jdwapman/gunrock
examples/shared_libs/shared_lib_sm.c
<filename>examples/shared_libs/shared_lib_sm.c /* * @brief Subgraph matching test for shared library advanced interface * @file shared_lib_sm.c */ #include <stdio.h> #include <gunrock/gunrock.h> int main(int argc, char *argv[]) { int num_data_nodes = 5, num_data_edges = 10; int data_row_offsets[6] = {0, 2, 6, ...
guodongxiaren/AE
ae.h
<filename>ae.h #ifndef __AE_H__ #define __AE_H__ #include <vector> #include <string> using namespace std; namespace ae { #define AE_OK 0 #define AE_ERR -1 #define AE_NONE 0 #define AE_READABLE 1 #define AE_WRITABLE 2 #define AE_FILE_EVENTS 1 #define AE_TIME_EVENTS 2 #define AE_ALL_EVENTS (AE_FILE_EVENTS|AE_TIME_E...
southfox/JFAlgo
Example/Pods/Target Support Files/JFAlgo/JFAlgo-umbrella.h
<reponame>southfox/JFAlgo #import <UIKit/UIKit.h> FOUNDATION_EXPORT double JFAlgoVersionNumber; FOUNDATION_EXPORT const unsigned char JFAlgoVersionString[];
southfox/JFAlgo
Example/Pods/Target Support Files/Pods-JFAlgo_Tests/Pods-JFAlgo_Tests-umbrella.h
<reponame>southfox/JFAlgo<filename>Example/Pods/Target Support Files/Pods-JFAlgo_Tests/Pods-JFAlgo_Tests-umbrella.h #import <UIKit/UIKit.h> FOUNDATION_EXPORT double Pods_JFAlgo_TestsVersionNumber; FOUNDATION_EXPORT const unsigned char Pods_JFAlgo_TestsVersionString[];
southfox/JFAlgo
Example/Pods/Target Support Files/Pods-JFAlgo_Example/Pods-JFAlgo_Example-umbrella.h
<reponame>southfox/JFAlgo #import <UIKit/UIKit.h> FOUNDATION_EXPORT double Pods_JFAlgo_ExampleVersionNumber; FOUNDATION_EXPORT const unsigned char Pods_JFAlgo_ExampleVersionString[];
bernatandrea/FM-tree
src/lib/rank_select.h
<reponame>bernatandrea/FM-tree<filename>src/lib/rank_select.h // // Created by <NAME> on 28/12/2016. // #ifndef BIOINF_TREE_H #define BIOINF_TREE_H #include <cstdint> /** * Interface that supports rank and select operations */ class rank_select { public: /** * @param idx index * @return character at give...
bernatandrea/FM-tree
src/lib/lookup_list.h
// // Created by <NAME> on 28/12/2016. // #ifndef BIOINF_VERYGOODTREE_H #define BIOINF_VERYGOODTREE_H #include "wavelet.h" #include "data.h" #include "rank_select.h" #include <algorithm> #include <vector> /** * Implementation of rank select that uses a sorted * vector of data and performs binary search on it */ ...
bernatandrea/FM-tree
src/lib/rb_tree.h
// // Created by <NAME> on 28/12/2016. // #ifndef BIOINF_RBTREE_H #define BIOINF_RBTREE_H #include <vector> #include "rb_node.h" #include "data.h" #include "rank_select.h" /** * Implementation of rank select using the red-black tree. * * Red-black tree implementation is based on the algorithms in the * "Introdu...
bernatandrea/FM-tree
src/lib/bitmask.h
// // Created by <NAME> on 28/12/2016. // #ifndef BIOINF_BITMASK_H #define BIOINF_BITMASK_H #include <cstdint> #include <functional> class bitmask; /** * Interface that provides some methods needed by wavelet, such as rank0/1, select01... */ class bitmask { private: static std::function<bitmask *(uint32_t)> C...
bernatandrea/FM-tree
src/lib/rb_node.h
<filename>src/lib/rb_node.h // // Created by <NAME> on 28/12/2016. // #ifndef BIOINF_RBNODE_H #define BIOINF_RBNODE_H #include "data.h" /** * Node for the red black tree. */ class rb_node { private: rb_node *right; rb_node *left; rb_node *parent; bool red; data *d; public: /** * Constructor. *...
bernatandrea/FM-tree
src/lib/bitmask_bitset.h
// // Created by <NAME> on 28/12/2016. // #ifndef BIOINF_BITMASK_BITSET_H #define BIOINF_BITMASK_BITSET_H #include "bitmask.h" #include "bitset.h" /** * Implementation of bitmask which uses bitsets * Because of that, operations require ~ constant time */ class bitmask_bitset : public bitmask { private: bitset...
bernatandrea/FM-tree
src/lib/bitset.h
// // Created by <NAME> on 28/12/2016. // #ifndef BIOINF_BITSET_H #define BIOINF_BITSET_H #include <vector> #include <ostream> /** * Implementation of bitset that supports rank/select (implemented by popcount) */ class bitset { private: // popcount // used because it's faster than __builtin_popcount() sta...
bernatandrea/FM-tree
src/fm-tree.h
#ifndef FMTREE_FM_TREE_H #define FMTREE_FM_TREE_H #include <set> #include "lib/bitmask.h" #include "lib/bitmask_bitset.h" #include "lib/bitmask_vector.h" #include "lib/data.h" #include "lib/rank_select.h" #include "lib/lookup_list.h" #include "lib/rb_tree.h" class Node { private: int sp; int e...
bernatandrea/FM-tree
src/lib/data.h
<reponame>bernatandrea/FM-tree<filename>src/lib/data.h // // Created by <NAME> on 30/12/2016. // #ifndef BIOINF_DATA_H #define BIOINF_DATA_H #include <utility> #include <unordered_map> #include <numeric> #include <algorithm> #include "wavelet.h" /** * Represents data used to answer rank/select queries. * Has meta...
bernatandrea/FM-tree
src/lib/bitmask_vector.h
// // Created by <NAME> on 28/12/2016. // #ifndef BIOINF_BITMASK_VECTOR_H #define BIOINF_BITMASK_VECTOR_H #include <vector> #include <algorithm> #include "bitmask.h" /** * Implementation of bitmask which uses vector of bools * Because of that, operations require ~ linear time */ class bitmask_vector : public bitm...
bernatandrea/FM-tree
src/lib/wavelet.h
<filename>src/lib/wavelet.h // // Created by <NAME> on 28/12/2016. // #ifndef BIOINF_ABSTRACT_NODE_H #define BIOINF_ABSTRACT_NODE_H #include <cstdint> #include <type_traits> #include <cstddef> #include <cstdint> #include <string> #include <unordered_map> #include "bitmask.h" /** * Represents a single wavelet tree. ...
zxhiOS/XHCommonKit
XHCommonKit/Classes/XHSystemInfo.h
<gh_stars>0 // // XHSystemInfo.h // Pods-XHCommonKit_Example // // Created by 郑信鸿 on 2019/1/4. // #import <Foundation/Foundation.h> #import <UIKit/UIKit.h> NS_ASSUME_NONNULL_BEGIN @interface XHSystemInfo : NSObject + (NSString *)iphoneTypeString; //5大小 + (BOOL)iPhone5; //小屏 + (BOOL)iPhone678; //iphonePuls + (...
zxhiOS/XHCommonKit
Example/Pods/Target Support Files/Pods-XHCommonKit_Example/Pods-XHCommonKit_Example-umbrella.h
<filename>Example/Pods/Target Support Files/Pods-XHCommonKit_Example/Pods-XHCommonKit_Example-umbrella.h<gh_stars>0 #ifdef __OBJC__ #import <UIKit/UIKit.h> #else #ifndef FOUNDATION_EXPORT #if defined(__cplusplus) #define FOUNDATION_EXPORT extern "C" #else #define FOUNDATION_EXPORT extern #endif #endif #endif FOUNDATI...
zxhiOS/XHCommonKit
XHCommonKit/Classes/XHCommonConst.h
// // XHCommonConst.h // Pods // // Created by 郑信鸿 on 2019/1/4. // #ifndef XHCommonConst_h #define XHCommonConst_h #define kScreenWidth ([UIScreen mainScreen].bounds.size.width) #define kScreenHeight ([UIScreen mainScreen].bounds.size.height) #define kNavgationBarHeight [XHSystemInfo navgationHeight] #define kS...
stsaz/alphahttpd
src/server.c
/** alphahttpd: server 2022, <NAME> */ #include <alphahttpd.h> #include <util/ipaddr.h> #include <FFOS/queue.h> #include <FFOS/socket.h> #include <FFOS/timer.h> #include <FFOS/perf.h> #include <FFOS/thread.h> struct server { struct ahd_kev kev; struct ahd_boss *boss; ffthread thd; ffuint64 thd_id; ffsock lsock; ...
stsaz/alphahttpd
src/http/transfer.h
/** alphahttpd: data transfer filter 2022, <NAME> */ static int trans_open(struct client *c) { if (c->resp.content_length == (ffuint64)-1) { c->resp_connection_keepalive = 0; return CHAIN_SKIP; } c->conlen = c->resp.content_length; return CHAIN_FWD; } static void trans_close(struct client *c) { } static int ...
stsaz/alphahttpd
src/alphahttpd.h
/** alphahttpd: shared types and functions 2022, <NAME> */ #pragma once #include <FFOS/error.h> #include <FFOS/kcall.h> #include <FFOS/socket.h> #include <FFOS/string.h> #include <FFOS/thread.h> #include <FFOS/time.h> #include <FFOS/timerqueue.h> #include <ffbase/vector.h> #define AHD_VER "0.4" typedef unsigned int ...
stsaz/alphahttpd
src/http/error.h
/** alphahttpd: error document 2022, <NAME> */ static int err_open(struct client *c) { if (!c->resp_err) return CHAIN_SKIP; return CHAIN_FWD; } static void err_close(struct client *c) { } static int err_process(struct client *c) { ffstr_setz(&c->resp.content_type, "text/plain"); c->resp.content_length = c->res...
stsaz/alphahttpd
src/http/request.h
/** alphahttpd: receive and parse HTTP request 2022, <NAME> */ #include <FFOS/path.h> #include <FFOS/perf.h> static int req_parse(struct client *c); static int req_open(struct client *c) { return CHAIN_FWD; } static void req_close(struct client *c) { if (c->ka) { // preserve pipelined data ffstr_erase_left((f...
stsaz/alphahttpd
src/util/range.h
/** alphahttpd: memory region pointer 2022, <NAME> */ // ffstr requires 16 bytes; range16 requires only 4 bytes typedef struct range16 { ffushort off, len; } range16; static inline void range16_set(range16 *r, uint off, uint len) { r->off = off; r->len = len; } static inline ffstr range16_tostr(range16 *r, const ...
stsaz/alphahttpd
src/log.h
/** alphahttpd: logging 2022, <NAME> */ #include <FFOS/std.h> // TIME LEVEL: #TID: [ID:] MSG [: SYSERR] void ahd_log(struct server *s, uint level, const char *id, const char *fmt, ...) { char buf[1024]; ffsize cap = sizeof(buf) - 2; // time ffstr dts; sv_date(s, &dts); ffsize r = _ffs_copy(buf, cap, dts.ptr, d...
stsaz/alphahttpd
src/http/access-log.h
/** alphahttpd: write access log 2022, <NAME> */ #include <FFOS/std.h> /* CLIENT_IP REQ_TOTAL "METHOD PATH VER" RESP_TOTAL "VER CODE MSG" REALTIME */ static int accesslog_open(struct client *c) { ffstr dts; fftime end_time = sv_date(c->srv, &dts); uint tms = end_time.sec*1000 + end_time.nsec/1000000 - c->start_tim...
stsaz/alphahttpd
src/http/response.h
/** alphahttpd: prepare and send HTTP response 2022, <NAME> */ static int resp_open(struct client *c) { if (NULL == ffvec_alloc(&c->resp.buf, ahd_conf->write_buf_size, 1)) { cl_syswarnlog(c, "no memory"); return CHAIN_ERR; } return CHAIN_FWD; } static void resp_close(struct client *c) { ffvec_free(&c->resp.bu...