sha256
stringlengths
64
64
language
stringclasses
28 values
size
int32
1
491k
lines
int32
1
23.2k
content
stringlengths
1
200k
a5aa5d7beae70dccc71e0580a2966c4236458be0e8b3ec763b9073b7ad1024ae
C
30,256
1,014
/* tifffile.c A Python C extension module for decoding PackBits and LZW encoded TIFF data. Refer to the tifffile.py module for documentation and tests. :Author: `Christoph Gohlke <http://www.lfd.uci.edu/~gohlke/>`_ :Organization: Laboratory for Fluorescence Dynamics, University of California, Irvine :Version: ...
5610d49f6eca6b144379266a6240385ef6f60ac44bfb66b29ed6bb240308308b
C
30,960
1,005
// Copyright [1999-2017] EMBL-European Bioinformatics Institute // // 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 a...
e728042cc65ef5e2f55cbc9726daa164c1d6fd8d6592d26a529c9a0d8d8e913d
C
31,919
1,375
// PGF got this from Dave Swofford. Thanks Dave! Not GPL'd, but it // is copyrighted by Dave. I believe Dave got the routines from // eispack, and hand translated to fortran to c. Dave says it is ok // to use this code as long as he is acknowleged. /* linalg.c | | This file contains code for various linear algebra...
5237486580d212801cf2eb3ad9074e2a2bf20e235f91b428e9f2b04f703a50be
C
33,632
1,121
/* Created by Language version: 7.7.0 */ /* VECTORIZED */ #define NRN_VECTORIZED 1 #include <stdio.h> #include <stdlib.h> #include <math.h> #include "scoplib_ansi.h" #undef PI #define nil 0 #include "md1redef.h" #include "section.h" #include "nrniv_mf.h" #include "md2redef.h" #if METHOD3 extern int _method3; #endif ...
87f2309ccc1dd7835b2e2b9a7e45bfd39c6dba30e0e65162a5adce3fa8339019
C
34,528
1,111
/* * Copyright (C) 2010 S. Klanke * F.C. Donders Centre for Cognitive Neuroimaging, Radboud University Nijmegen, * Kapittelweg 29, 6525 EN Nijmegen, The Netherlands * * */ #include <rdaserver.h> #include <fcntl.h> #include <errno.h> const UINT8_T _rda_guid[16]={ 0x8E,0x45,0x58,0x43,0x96,0xC9,0x86,0x4C,0xAF,0x4...
b84b43c96aed0dd59e01621fe31414cf477502210ac3bd5fb24fb433915d2e9f
C
36,972
1,047
#include "pftypes.h" #include "p4_tree.h" #include "pmatrices.h" #include "defines.h" // #include "util.h" #include "p4_node.h" #include <stdio.h> #include <stdlib.h> #include <math.h> void p4_simulate(p4_tree *t, p4_tree *refTree, const gsl_rng *g) { double theRanDoubleUpToOne; int i, j, k, l; int p...
d225c550ef380c2195ac074c89d2720b8b92dc4aaf24480870de648ed4f6906f
C
36,990
1,087
/* The MIT License Copyright (c) 2003-2006, 2008, 2009, by Heng Li <lh3lh3@gmail.com> 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 limitat...
dcafab77c7c237131009e16f12f3849390ae2a02d2f06debe0f3d8d6ca95c007
C
38,717
1,258
// Copyright [1999-2017] EMBL-European Bioinformatics Institute // // 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 a...
973c5028f731b0698da770eaab57733d6d0c55a7dc0c405008b40fae8a96b090
C
39,973
1,362
#include <zlib.h> #include <stdlib.h> #include <getopt.h> #include <string.h> #include <hdf5.h> #include <stdint.h> #include "impute.h" #include "vcf.h" #include "sample.h" #include "sampletab.h" #include "snptab.h" #include "util.h" #include "memutil.h" #include "chrom.h" /* * These values control size of chunks...
e47d9c9b8cd199bec69dc1c832b2f22ef1cf62ba083c01f1f56dc62e724611e5
C
40,113
1,845
/* * hsfft.c * * Created on: Apr 14, 2013 * Author: Rafat Hussain */ #include "hsfft.h" fft_object fft_init(int N, int sgn) { // Change N/2 to N-1 for longvector case int twi_len; const int out = dividebyN(N); fft_object obj; if (out == 1) { obj = (fft_object)malloc(sizeof(struct fft_set) + s...
0f8a60032e69fb537f07c1ed3a7a8701b035e4bb61fdeec29f14881972231504
C
47,150
1,571
#include <stdio.h> #include <stdlib.h> #include <math.h> #include <Python.h> #include "pmatrices.h" #include "defines.h" #include "pftypes.h" #include "part.h" #include "eig.h" #include "util.h" #include <gsl/gsl_linalg.h> #define DTOLERANCE 1e-37 // uncritically stolen from PAUP part *newPart(int nTax, int nChar, c...
55f83cc9f2394ab5769c8f00ce92cde7c85284f5d84fc85ecc9c5db88cf97baa
C
49,012
1,200
# include <stdio.h> # include <stdlib.h> # include <malloc.h> # include <time.h> # include <math.h> # include "ProgConst.h" # include "FunAsser_Cal_ion_current.h" void main() { clock_t start = clock(), finish; FILE *fp, *fp1, *fp2, *fp3, *fp4, *fp5, *fp6, *fp7; FILE *fp11, *fp12, *fp13, *fp14, *fp15, *fp...
473e4e5c066bffbcc5f7cf38f39c827ab893df1a421c4c3b5f24ccbd726280c5
C
57,303
728
#include <stdio.h> #include <math.h> #include <time.h> #include "./include/k2c_include.h" #include "example.h" float maxabs(k2c_tensor *tensor1, k2c_tensor *tensor2); struct timeval GetTimeStamp(); int main() { float test1_input_1_input_array[256] = { -1.09487110e-01,1.93387878e+00,-2.97306259e-01,3.12030...
09a1debcbccedf6fe49eba4c7dfe65475b37bbe97bca67f6fdcd2ca3a15efde4
C
58,674
1,505
#include "pftypes.h" #include "p4_node.h" #include "p4_model.h" #include "pmatrices.h" #include "eig.h" #include "defines.h" #include <math.h> //For fabs p4_node *p4_newNode(int nodeNum, p4_tree *aTree, int seqNum, int isLeaf, int inTree) { p4_node *aNode; int i, j; aNode = malloc(sizeof(p4_node)); ...
5d22984dd35737f1acf8b8d7903662f90592b228ff2297716312eca0d926aa51
C
62,397
1,698
#include "pftypes.h" #include "p4_tree.h" #include "p4_node.h" #include "gamma.h" // Yang funcs, DiscreteGamma et al. #include "defines.h" #include "util.h" #include "eig.h" /* #include <stdio.h> */ /* #include <stdlib.h> */ #include <math.h> // log #include "pmatrices.h" //static int anInt = 0; // for a recur...
ade56c6f645fee6c9a5e10690994d4b0a702901e36322a35cd2cfbf1d6ab7d05
C
62,742
1,770
#include "pftypes.h" #include "p4_tree.h" #include "pmatrices.h" #include "util.h" #include "brent.h" #include "defines.h" #include <stdio.h> #include <stdlib.h> #include <math.h> #include <nlopt.h> static int nPrams = 0; static p4_tree *thisTree = NULL; static int doBranchLengths = 0; static int likelihoodEval...
6381e29b2d8e0cdb1e52f1c2790d894ab446f31d2d39776538c5a5b7a448917d
C
66,284
2,669
/* Copyright (c) 2014, Rafat Hussain */ #include "wavelib.h" wave_object wave_init(char* wname) { const int retval = (wname != NULL) ? filtlength(wname) : 0; wave_object obj = (wave_object)malloc(sizeof(struct wave_set) + sizeof(double) * 4 * retval); obj->filtlength = retval; obj->lpd_len = obj->hpd_len =...
bfc28328e279c83bb3d20a1721f737d86d1b234fd56f7b00938e0ea96b87cd91
C
75,055
942
#include <stdio.h> #include <math.h> #include <time.h> #include "./include/k2c_include.h" #include "emmodel_na.h" float maxabs(k2c_tensor *tensor1, k2c_tensor *tensor2); struct timeval GetTimeStamp(); float test1_input1_input_array[403] = { +1.80481793e-01f,+1.70485765e-01f,-1.29160324e+00f,+1.32057038e+00f,-6...
18c7284d2c11382f9e391e10ac3130508b223ccc8c86cc3e8fc882d14d36159d
C
75,081
942
#include <stdio.h> #include <math.h> #include <time.h> #include "./include/k2c_include.h" #include "xraymodel_na.h" float maxabs(k2c_tensor *tensor1, k2c_tensor *tensor2); struct timeval GetTimeStamp(); float test1_input1_input_array[403] = { -1.15900665e+00f,+8.47538302e-01f,-1.36592173e+00f,+1.51949925e+00f,...
8baa11fe0bf8a3e484434ee2428e73950c67896d305e4113f6111f1b3c639bc4
C
75,094
942
#include <stdio.h> #include <math.h> #include <time.h> #include "./include/k2c_include.h" #include "xraymodel_dna.h" float maxabs(k2c_tensor *tensor1, k2c_tensor *tensor2); struct timeval GetTimeStamp(); float test1_input1_input_array[403] = { -1.61090333e+00f,+7.97014076e-01f,+2.01910521e-01f,-5.41540645e-01f...
a2e77bca128e16dd143d8cd4015339e32d873fbce8dc3006040beb0024ff6915
C
75,107
942
#include <stdio.h> #include <math.h> #include <time.h> #include "./include/k2c_include.h" #include "emmodel_rnadna.h" float maxabs(k2c_tensor *tensor1, k2c_tensor *tensor2); struct timeval GetTimeStamp(); float test1_input1_input_array[403] = { +1.85466883e+00f,-9.91255672e-01f,-1.41800596e+00f,+8.68112860e-01...
9a9baee0d2c8e3d266347831cb7cd7524d1b2455c6b24fa5d816c4932ff8eddf
C
75,133
942
#include <stdio.h> #include <math.h> #include <time.h> #include "./include/k2c_include.h" #include "xraymodel_rnadna.h" float maxabs(k2c_tensor *tensor1, k2c_tensor *tensor2); struct timeval GetTimeStamp(); float test1_input1_input_array[403] = { -1.65583121e+00f,+9.94338377e-01f,-1.46778880e-01f,-2.63127661e-...
8f57a86a7dbecc2effacf4de40c3e0bbb90d9b9a49c6eadedc55d878301397b1
C
81,080
3,038
#include <Python.h> #include <numpy/arrayobject.h> #include "pftypes.h" #include "data.h" #include "part.h" #include "defines.h" #include "dlsgamma.h" #include "gamma.h" #include "util.h" #include "pmatrices.h" #include <gsl/gsl_rng.h> #include <gsl/gsl_randist.h> #include <gsl/gsl_sf_gamma.h> #include <gsl/gsl_stati...
604c0162b19f7707e17fb47bf8f7d052625d9c0695c14b3d2d32f67204261df9
C
91,512
1,077
#include <math.h> #include <string.h> #include "./include/k2c_include.h" #include "./include/k2c_tensor_include.h" void example(k2c_tensor* input_1_input, k2c_tensor* dense_3_output) { float dense_1_output_array[160] = {0}; k2c_tensor dense_1_output = {&dense_1_output_array[0],2,160,{ 8,20, 1, 1, 1}}; ...
4aea064c4547d760a7290d4a496bc03afd078a2a97790d311cc0a387100f2f9e
C
148,094
6,872
/* ***************************************************************************** * * Copyright (c) 2009 - 2024 Teunis van Beelen * All rights reserved. * * Email: teuniz@protonmail.com * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following condit...
23934b2ce07d8b87924b7402dcbc83daf7a539a2cf27ee6afa0599d356435992
C
200,000
2,335
#include <math.h> #include <string.h> #include "./include/k2c_include.h" #include "./include/k2c_tensor_include.h" void xraymodel_dna(k2c_tensor* input1_input, k2c_tensor* l7_output) { float l5_output_array[403] = {0}; k2c_tensor l5_output = {&l5_output_array[0],1,403,{403, 1, 1, 1, 1}}; float l5_kern...
3eba9fbb6e6c91398ccb3790a8daa6d9be73ac2379e846806da72c4ad528e028
C
200,000
4,224
/****************************************************************************** ** This file is an amalgamation of many separate C source files from SQLite ** version 3.7.14.1. By combining all the individual C code files into this ** single large file, the entire code can be compiled as a single translation ** unit....
401ef401abddac306f93b3f6dd50aeb3cca26d54ab86ded0d17836b2a72b09f5
C
200,000
2,335
#include <math.h> #include <string.h> #include "./include/k2c_include.h" #include "./include/k2c_tensor_include.h" void emmodel_na(k2c_tensor* input1_input, k2c_tensor* l7_output) { float l5_output_array[403] = {0}; k2c_tensor l5_output = {&l5_output_array[0],1,403,{403, 1, 1, 1, 1}}; float l5_kernel_...
528a312b12ea6c83e01c309ca853301a0ef5a671e433fb9e4726ca6431620f14
C
200,000
3,765
/* * Copyright (c) 2014, Rafat Hussain * Copyright (C) 2016 Holger Nahrstaedt * Daubechies wavelets coefficents Computed by Kazuo Hatano, Aichi Institute of Technology. http://phase.hpcc.jp/phase/wavelet/ */ #include "wavefilt.h" static const double db1[2] = { 7.07106781186547524400844362104849039284835937688474036...
b58583d12160a43dd5be19d7eb1cd85d1e7d2d5554ec3003eed8bad3bd0ef1d0
C
200,000
2,614
void cpREVRMatrix(double **r) { r[ 0][ 0] = 0.0; r[ 0][ 1] = 105.0; r[ 0][ 2] = 227.0; r[ 0][ 3] = 175.0; r[ 0][ 4] = 669.0; r[ 0][ 5] = 157.0; r[ 0][ 6] = 499.0; r[ 0][ 7] = 665.0; r[ 0][ 8] = 66.0; r[ 0][ 9] = 145.0; r[ 0][10] = 197.0; r[ 0][11] = ...
c9dbd20caf3844a79127ae34e2ac75d81c2b24e6c0cc65b93ef3067ffc7c4bf8
C
200,000
2,335
#include <math.h> #include <string.h> #include "./include/k2c_include.h" #include "./include/k2c_tensor_include.h" void xraymodel_na(k2c_tensor* input1_input, k2c_tensor* l7_output) { float l5_output_array[403] = {0}; k2c_tensor l5_output = {&l5_output_array[0],1,403,{403, 1, 1, 1, 1}}; float l5_kerne...
da5929682599e0eca17811e9559db880656056432ad2eaeeb9ab75aa07328caf
C
200,000
2,335
#include <math.h> #include <string.h> #include "./include/k2c_include.h" #include "./include/k2c_tensor_include.h" void emmodel_rnadna(k2c_tensor* input1_input, k2c_tensor* l7_output) { float l5_output_array[403] = {0}; k2c_tensor l5_output = {&l5_output_array[0],1,403,{403, 1, 1, 1, 1}}; float l5_ker...
f415e1cbb9786513578842a5e8831aa8bb97b107742b6087913545000ffee352
C
200,000
2,335
#include <math.h> #include <string.h> #include "./include/k2c_include.h" #include "./include/k2c_tensor_include.h" void xraymodel_rnadna(k2c_tensor* input1_input, k2c_tensor* l7_output) { float l5_output_array[403] = {0}; k2c_tensor l5_output = {&l5_output_array[0],1,403,{403, 1, 1, 1, 1}}; float l5_k...
2f1d005e3cbf4cc806b005f96746e26de8cfcbb70dac0da10e90275dd5726cfc
C++
20
1
#include "ov_all.h"
7c8a0944bcdf4b0b4154d4abce6ea2e03cc0bd6893bde95629857f97a3bf80bc
C++
66
6
#include "BamStats.h" #include <cmath> using namespace SeqLib;
6a51d4aa25149a1b6c0bc4a1fb1c02298a0735692d4785272dfd2322aeda21be
C++
135
3
#include "CStimulusSender.h" OV_API TCPTagging::IStimulusSender* TCPTagging::CreateStimulusSender() { return new CStimulusSender(); }
331398b1e4af07aa6740d4a119b56b12efd6829e3aa59111f03f716c789579d9
C++
163
10
#include <vector> #include <openvibe/ov_all.h> #include "ovp_defines.h" OVP_Declare_Begin(); // For the moment this plugin is empty OVP_Declare_End()
c3e05e4437af6a6e2a7f0027208258fc19a6b1c63dcf75645b709290ec306254
C++
182
9
#include "SequenceAlignment.h" int main(int argc, char* argv[]) { SequenceAlignment* data = new FileSequenceAlignment(argv[1],1,0); ofstream os(argv[2]); data->ToStream(os); }
6316441ae51f54f869ea8e44a2f02ed25407da327ecc0922b1bf2573964ff0dd
C++
279
9
#include <script_api.hpp> #include <hex/api/imhex_api/bookmarks.hpp> #define VERSION V1 SCRIPT_API(void createBookmark, u64 address, u64 size, u32 color, const char *name, const char *description) { hex::ImHexApi::Bookmarks::add(address, size, name, description, color); }
8263575af5f31fdc4aa75decdd361866b9aada2e09db27fedcd26a676ab9ba9f
C++
283
14
#include <hex/data_processor/link.hpp> namespace hex::dp { int Link::s_idCounter = 1; Link::Link(int from, int to) : m_id(s_idCounter++), m_from(from), m_to(to) { } void Link::setIdCounter(int id) { if (id > s_idCounter) s_idCounter = id; } }
116310e233d855f8464b57302626715ced450b4703333000e4e8b4ab3083e0b4
C++
292
9
//----------------------------------------------- // Copyright 2009 Wellcome Trust Sanger Institute // Written by Jared Simpson (js18@sanger.ac.uk) // Released under the GPL //----------------------------------------------- // // bucketSort - perform a bucket sort over a range of values //
3c7213756183a4d4daf6f0fec6b36387c2eb9dcf6964aed616026a5d5826376f
C++
298
8
// stdafx.cpp : source file that includes just the standard includes // ConsoleApplication1.pch will be the pre-compiled header // stdafx.obj will contain the pre-compiled type information #include "stdafx.h" // TODO: reference any additional headers you need in STDAFX.H // and not in this file
178409444b0624f22babe046f0d006674a7626a562a77ca6c91348d5b2f3d1b8
C++
322
15
#include "gtest/gtest.h" // ReSharper disable CppUnusedIncludeDirective #include "ConvertTests.hpp" // ReSharper restore CppUnusedIncludeDirective int main(int argc, char** argv) { try { testing::InitGoogleTest(&argc, argv); return RUN_ALL_TESTS(); } catch (std::exception&) { return 1; } ...
bea27dc9bd9417050790c34174542209000044a05cc4bf4f6c22a125c6659f23
C++
345
12
#include "ovpCBoxAlgorithmNothing.h" namespace OpenViBE { namespace Plugins { namespace Examples { bool CBoxAlgorithmNothing::initialize() { return true; } bool CBoxAlgorithmNothing::uninitialize() { return true; } bool CBoxAlgorithmNothing::process() { return true; } } // namespace Examples } // namespace Plugins ...
c532852cbdc4ae658b73aeea1bca463288588af1ec59fe124ffbfff21ca2c718
C++
384
17
#include "internal.hpp" #include <hex/api/project_manager.hpp> namespace hex::plugin::builtin::project::impl { ProjectState &state() { static ProjectState state; return state; } const std::fs::path &projectSettingsPath() { static const auto path = std::fs::path(ProjectManager::Pr...
7f4b53a1ffeac92e50ce02a7b0c9583410ce091b8ec17724e8bc99212386d8b7
C++
386
12
/* # ============================================================================= # Copyright (c) 2016 - 2021 Blue Brain Project/EPFL # # See top-level LICENSE file for details. # =============================================================================. */ namespace coreneuron { int nrnmpi_numprocs = 1; /* size ...
db197760b3f46b29da12a71ec61a486cbf7bbd51dc300379f31b0b88581bceb2
C++
397
18
#include <hex/ui/toast.hpp> #include <hex/helpers/auto_reset.hpp> namespace hex::impl { [[nodiscard]] std::list<std::unique_ptr<ToastBase>> &ToastBase::getQueuedToasts() { static AutoReset<std::list<std::unique_ptr<ToastBase>>> queuedToasts; return queuedToasts; } std::mutex& ToastBase::...
1f4bd4e7507dd049b05132ce5941c5c223d781311abc54c463011474b6d92eb1
C++
398
21
#include <hex/ui/popup.hpp> #include <hex/helpers/auto_reset.hpp> namespace hex::impl { [[nodiscard]] std::vector<std::unique_ptr<PopupBase>> &PopupBase::getOpenPopups() { static AutoReset<std::vector<std::unique_ptr<PopupBase>>> openPopups; return openPopups; } std::mutex& PopupBase::g...
2211273957c514003fced5cf590878646282aabf983aede598ebea6210097695
C++
399
18
#include <hex/ui/banner.hpp> #include <hex/helpers/auto_reset.hpp> namespace hex::impl { [[nodiscard]] std::list<std::unique_ptr<BannerBase>> &BannerBase::getOpenBanners() { static AutoReset<std::list<std::unique_ptr<BannerBase>>> openBanners; return openBanners; } std::mutex& BannerBase...
f939102d586568ed99a59fb308b13d26d0b27e172bcd80ef341f8705ca5c6f62
C++
416
17
#include "ovp_defines.h" #include "box-algorithms/BoxAcquisitionClientLegacy.h" #include "box-algorithms/BoxAcquisitionClient.h" namespace OpenViBE { namespace Plugins { namespace Acquisition { OVP_Declare_Begin() OVP_Declare_New(CBoxAlgorithmAcquisitionClientLegacyDesc) OVP_Declare_New(CBoxAcquisitionClientDesc) ...
a86187450669f38650de6eca731d61cdcef228a11f211e98f2bf5f3c88d33ad0
C++
421
20
#include <hex/plugin.hpp> #include <hex/helpers/logger.hpp> #include <romfs/romfs.hpp> namespace hex::plugin::decompress { void registerPatternLanguageFunctions(); } using namespace hex; using namespace hex::plugin::decompress; IMHEX_PLUGIN_SETUP("Decompressing", "WerWolv", "Support for decompressing data") ...
867c4bb19b5c0ee4bdb741cc276aabb85ae49a05724fe2fc6bbc8f5addf35d42
C++
430
18
#include <hex/api/tutorial_manager.hpp> #include <ui/markdown.hpp> namespace hex::plugin::builtin { void registerIntroductionTutorial(); void registerTutorials() { TutorialManager::setRenderer([](const std::string &message) { return [markdown = std::make_shared<ui::Markdown>(message)] { ...
117ac9711e7427db0348574f97517ab8b597dfdf152ececcaeb6bc7cca6c3114
C++
435
18
#include <mensia/advanced-visualization.hpp> namespace OAV = OpenViBE::AdvancedVisualization; int main() { OAV::CRendererContext context; context.Clear(); context.SetDataType(OAV::CRendererContext::EDataType::Matrix); OAV::IRenderer* rend = OAV::IRenderer::Create(OAV::ERendererType::Bitmap, false); ...
d6f8a01dcbef92287466f2a355c5c21a1cd371f31877f11b8f3491621190408d
C++
435
15
#include <content/data_processor_nodes.hpp> namespace hex::plugin::builtin { void registerDataProcessorNodes() { registerBasicDataProcessorNodes(); registerVisualDataProcessorNodes(); registerLogicDataProcessorNodes(); registerControlDataProcessorNodes(); registerDecodeData...
7fe7e7c5b5eb2bb36eb18fefe4f154df72c73de02f1a8ff541d2176f18fe916a
C++
442
16
#include <hex/plugin.hpp> #include <hex/helpers/logger.hpp> #include <romfs/romfs.hpp> #include <ui/hex_editor.hpp> #include <ui/pattern_drawer.hpp> #include <ui/widgets.hpp> IMHEX_LIBRARY_SETUP("UI") { hex::log::debug("Using romfs: '{}'", romfs::name()); hex::LocalizationManager::addLanguages(romfs::get("l...
425bbce03d5658ce186ae0153256a52c2c1ca0ff9bc797da81dec27e14055881
C++
443
21
#include "bamreader.h" bool Bamreader::bamToSeqRecordVector(SeqRecordVector &srv) { if (!m_reader.Open(m_bam) || !reader.SetRegion(m_region)) return false; BamTools::BamAlignment a; while (m_reader.GetNextAlignment()) } bool Bamreader::findBamIndex() { m_bai = m_bam.substr(0, m_bam.size()-3.append(...
22c7b1952efc7998170bd706aa79821e669d8efafd89d5ee96209572d105dd51
C++
459
16
#include "defines.hpp" #include "box-algorithms/CBoxAlgorithmModifiableSettings.hpp" namespace OpenViBE { namespace Plugins { namespace Examples { OVP_Declare_Begin() context.getTypeManager().registerEnumerationEntry(OV_TypeId_BoxAlgorithmFlag, Box_FlagIsUnstable.toString(), Box_FlagIsUnstable.id()); OVP_Dec...
4fca9bcf55552152cdafbf3fa73e87b04161e29c375e688dd7c28e72f810d434
C++
463
12
#include "utils.h" /****************************************************************************** * Utility Functions * ******************************************************************************/ /* Print vector of double type */ void print_dvec(const int...
c1171de6a0686e0acc5a273e846c5be4bc2b21d5fec8bd5210879750233f31c9
C++
466
19
#include <gtest/gtest.h> // ReSharper disable CppUnusedIncludeDirective #include "CMatrixTest.hpp" #include "CTimeTest.hpp" #include "CIdentifierTest.hpp" #include "CStimulationSetTest.hpp" #include "CNameValuePairListTest.hpp" #include "CErrorManagerTest.hpp" #include "CParameterTest.hpp" int main(int argc, char* ar...
b157aa96791847d98807b7bc006f3310c19b2138122a513458bc75e301ae83db
C++
479
17
//----------------------------------------------- // Copyright 2010 Wellcome Trust Sanger Institute // Written by Jared Simpson (js18@sanger.ac.uk) // Released under the GPL //----------------------------------------------- // // BWTReader - Abstract class for reading a BWT file // #include "BWTReader.h" #include "BWT...
f86830e7b042e27817a54c3f828031d1c77c8fc6b341f6f6672ab7c2d3bdf305
C++
490
14
#include "ebml/CWriter.h" namespace EBML { CWriter::CWriter(IWriterCallback& callback) { m_impl = createWriter(callback); } CWriter::~CWriter() { m_impl->release(); } bool CWriter::openChild(const CIdentifier& identifier) { return m_impl->openChild(identifier); } bool CWriter::setChildData(const void* buffer, const ...
7f15b2d4b254c727374cc8e65aba47ef58e101d5a542edc05b22dda11d8c7537
C++
495
16
#include "gtest/gtest.h" #include "Eikonal.h" TEST(Sanity3D, Filename) { Eikonal data(false); data.filename_ = "notarealfile"; EXPECT_EXIT(data.solveEikonal(), ::testing::ExitedWithCode(1), ""); data.filename_ = TEST_DATA_DIR + std::string("sphere334"); EXPECT_NO_THROW(data.solveEikonal()); delete da...
ab0257a832a0a086943ea5409ee86d1e6f93a5b8a8b0b199b75f7016d8a9e838
C++
500
14
#include "ebml/CReader.h" namespace EBML { CReader::CReader(IReaderCallback& callback) { m_impl = createReader(callback); } CReader::~CReader() { m_impl->release(); } bool CReader::processData(const void* buffer, const size_t size) { return m_impl->processData(buffer, size); } CIdentifier CReader::getCurrentNodeID()...
a4cdbfd541572593a74c8b587c921e7f6847cc0cb6555cfdadbc4b7617bca7e1
C++
501
22
#include "ovtkCSignalTrialSet.hpp" namespace OpenViBE { namespace Toolkit { bool CSignalTrialSet::addSignalTrial(ISignalTrial& rSignalTrial) { m_signalTrials.push_back(&rSignalTrial); return true; } bool CSignalTrialSet::clear() { m_signalTrials.clear(); return true; } ISignalTrialSet* createSignalT...
5158d99c5f9ed3ec79cffdd91cb2a33a28c778e7cb494c61fb57e1dcbe486cd5
C++
511
19
#include "ovpCFeatureVectorEncoder.h" namespace OpenViBE { namespace Plugins { namespace StreamCodecs { bool CFeatureVectorEncoder::processHeader() { OV_ERROR_UNLESS_KRF(ip_pMatrix->getDimensionCount() == 1, "Invalid feature vector: found " << ip_pMatrix->getDimensionCount() << " dimensions, 1 expected", ...
acd30ec5bafa46a17e617024438a8ec61297fceab6d33ce1e6c29cd48693c8d1
C++
511
17
#include <hex/test/tests.hpp> #include <hex/helpers/encoding_file.hpp> #include <vector> TEST_SEQUENCE("EncodingLineStartAddressCache") { std::vector<u64> lineStartAddresses = { 0, 2, 1 }; hex::impl::appendEncodingLineStartAddress(lineStartAddresses, 0, 3); TEST_ASSERT(lineStartAddresses == std::vector<...
a78c1b44720a6dfb37cf4bde3c30b5970dcc9dca73c6b8c1be888a28d7108354
C++
517
15
/* # ============================================================================= # Copyright (c) 2016 - 2021 Blue Brain Project/EPFL # # See top-level LICENSE file for details. # ============================================================================= */ #include <cstring> unsigned strcat_at_pos(char* dest, un...
e178260c2faa13b7e4ba69ea72148274467e1619bc926490964972711fa95ed4
C++
538
11
#include <hex/plugin.hpp> // Browse through the headers in lib/libimhex/include/hex/api/ to see what you can do with the API. // Most important ones are the things under imhex_api and content_registry // This is the main entry point of your plugin. The code in the body of this construct will be executed // when ImHex...
9b63e13a64ca76ed707ead151e253700f20c8a89915b8ce917ffd4aa15a0038c
C++
539
28
#include <mutex> namespace hex { void functionEntry(void *); void functionExit(void *); } extern "C" { static std::mutex s_mutex; [[gnu::no_instrument_function]] void __cyg_profile_func_enter(void *functionAddress, void *) { std::scoped_lock lock(s_mutex); hex::functionEntry(f...
f284130d774065ec92a0472861d3b8cc5bf2f2e985f671341b82dd887e9e54b5
C++
542
23
#if defined(OS_WEB) #include <stdexcept> #include <hex/helpers/logger.hpp> #include "messaging.hpp" namespace hex::messaging { void sendToOtherInstance(const std::string &eventName, const std::vector<u8> &args) { std::ignore = eventName; std::ignore = args; log::error("Unimplemented fun...
d93f688a1daf7342c73e78faa97e0d335d0632804411e40fdcbb225f5837c898
C++
545
20
#include "ovkCBuffer.h" namespace OpenViBE { namespace Kernel { CBuffer::CBuffer(const CBuffer& buffer) { this->CMemoryBuffer::setSize(buffer.getSize(), true); memcpy(this->CMemoryBuffer::getDirectPointer(), buffer.getDirectPointer(), buffer.getSize()); } CBuffer& CBuffer::operator=(const CBuffer& buffer) { ...
c9ce184de458a15dcd540e6833f5a0cbcd401a5e66effb89209ee24abccbeb11
C++
546
17
#include "ovkCPlayerContext.h" #include "ovkCSimulatedBox.h" namespace OpenViBE { namespace Kernel { void CBoxAlgorithmLogManager::log(const ELogLevel logLevel) { CIdentifier boxId; m_simulatedBox.getBoxIdentifier(boxId); m_logManager << logLevel << "At time " << CTime(m_playerCtx.getCurrentTime()) << " ...
5cf336372c06f32abc1d0b7bc6a8f34f6b1b89b8dd3fe897eb53372245545678
C++
547
27
//----------------------------------------------- // Copyright 2010 Wellcome Trust Sanger Institute // Written by Jared Simpson (js18@sanger.ac.uk) // Released under the GPL //----------------------------------------------- // // SQG - Common functions for parsing // assembly and sequence graph files // #include "SQG....
ace069329b37bf528a276dac8e1f9fcd78d87e397482009353347bfc4910cfd1
C++
552
23
#include <hex/helpers/scaling.hpp> #include <hex/api/imhex_api/system.hpp> namespace hex { float operator""_scaled(long double value) { return value * ImHexApi::System::getGlobalScale(); } float operator""_scaled(unsigned long long value) { return value * ImHexApi::System::getGlobalScale...
f5a7011d3441fdec272370801641c229086ee27745488b8edd790d485d4eb15f
C++
552
25
#include "ovbt_sg_defines.h" #include <fstream> bool CCppDefineGenerator::openFile(const char* filename) { m_file.open(filename, std::ios::out | std::ios::trunc); if (!m_file.is_open()) { return false; } m_file << "#pragma once" << std::endl << std::endl; return true; } bool CCppDefineGenerator::app...
8ec490f94de86865d8339d25c9753ba1113b18285d76cd3bdf66c5f758305190
C++
554
19
#include "ovkCBoxAlgorithmContext.h" #include "ovkCPlayerContext.h" #include "ovkCSimulatedBox.h" namespace OpenViBE { namespace Kernel { CBoxAlgorithmCtx::CBoxAlgorithmCtx(const IKernelContext& ctx, CSimulatedBox* simulatedBox, const IBox* box) : TKernelObject<IBoxAlgorithmContext>(ctx), m_pStaticBoxContext(box)...
87e055a2c632f2f968740cd45a65a732d796c5d9573d9e0b37f065c8537b9647
C++
568
17
/* # ============================================================================= # Copyright (c) 2016 - 2021 Blue Brain Project/EPFL # # See top-level LICENSE file for details. # =============================================================================. */ #include <coreneuron/engine.h> #include "coreneuron/util...
ece13c93f6be1b56e1cbd378996c39574f2faf76f07180cde8dc81023fc71ca9
C++
569
22
#include <hex/data_processor/attribute.hpp> namespace hex::dp { int Attribute::s_idCounter = 1; Attribute::Attribute(IOType ioType, Type type, UnlocalizedString unlocalizedName) : m_id(s_idCounter++), m_ioType(ioType), m_type(type), m_unlocalizedName(std::move(unlocalizedName)) { } Attribute::~Att...
456339502208065eb5cf7a61d35a5ca3694e9962e600c740d3847a52f500863e
C++
584
21
//#include "defines.hpp" //#include "algorithms/CAlgorithmAddition.hpp" //#include "box-algorithms/CBoxAlgorithmAdditionTest.hpp" //#include "box-algorithms/CCrashingBox.hpp" #include "box-algorithms/CTestCodecToolkit.hpp" namespace OpenViBE { namespace Plugins { namespace Tests { OVP_Declare_Begin() // OVP_Decl...
68d9f647df864378428794ec3a98fb9c0526fcb59222d22c658e8091aaf6cac4
C++
584
18
#include <hex/api/content_registry/settings.hpp> #include <hex/api/task_manager.hpp> #include <hex/api/workspace_manager.hpp> #include <hex/helpers/fs.hpp> namespace hex::plugin::builtin { void loadWorkspaces() { WorkspaceManager::reload(); auto currentWorkspace = ContentRegistry::Settings::read...
6013d71cc30d46c2c7120f7bf2e2760dc17e6cc8613f0161dd9750e0ad786098
C++
590
31
/** * SPDX-FileCopyrightText: Inria <tristan.cabel@inria.fr> * SPDX-License-Identifier: AGPL-3.0-only */ #include "OVLogControllerItem.h" OVLogControllerItem::OVLogControllerItem(const QString &message, const QString &level) : m_message(message), m_level(level) { m_time = QDateTime::currentDateTime().toString("...
f820591e89754be4a3259ed6742f29101b8c8504078db1c1956503e94985add9
C++
595
29
#include "imagewidget.h" #include <QPalette> ImageWidget::ImageWidget(QWidget *parent) : QWidget(parent) { this->setMaximumSize(640,640); this->setMinimumSize(640,640); this->setAutoFillBackground(true); this->setPalette(Qt::white); } void ImageWidget::paintEvent(QPaintEvent *event) { QPainter pai...
5d990ef6cfb7b3292e36d01deffd659d19bcd4ae184848165ded60f5c41fd0dd
C++
597
30
#include "SimTrainerWalker.h" void SimTrainerWalker::train() { SeqLib::BamRecord r; size_t count = 0; while (GetNextRecord(r)) { ++count; // check occasionally that we still have read groups if (count % 10000 == 0) assert(r.GetZTag("RG").length()); if (count % 1000000 == 0) ...
5141b60629d160c96615f384cf3eb5eba266abc830025423d7251a63bee147e6
C++
601
27
#include "datadef.h" #include "utils.h" #include <QDebug> #include <QString> QString strDrawbackType(int type){ QString str = ""; switch(type){ case DRAWBACK_NONE: str = "none";break; case DRAWBACK_BROKEN: str = "open";break; case DRAWBACK_SHORT: str = "short"; break; ca...
c30fe0b2ec000cf7264a94a1cd40c23265b3a8a70285eaac630c12f314b66750
C++
611
18
#include <hex/api/events/events_gui.hpp> #include <imgui.h> #include <imgui_internal.h> #include <hex/api/tutorial_manager.hpp> #if !defined(IMGUI_TEST_ENGINE) void ImGuiTestEngineHook_ItemAdd(ImGuiContext*, ImGuiID id, const ImRect& bb, const ImGuiLastItemData*) { hex::TutorialManager::postElementRende...
121b40f95eb00975b8e02cdba46d88bef2dfbc21bb0d9d7fbe4ccc96bae89dae
C++
623
23
#include <hex/api/plugin_manager.hpp> #include <hex/helpers/utils.hpp> #include <hex/helpers/default_paths.hpp> using namespace hex; class PluginLoader { public: PluginLoader() { if (const auto pluginPath = getEnvironmentVariable("IMHEX_TEST_PLUGIN_PATH"); pluginPath.has_value()) { PluginMana...
a402754a266857556118dc35900b2e212d1d4fc0c916f12b927026716eb76ae4
C++
629
22
#include <vector> #include <openvibe/ov_all.h> #include "ovp_defines.h" #include "box-algorithms/ovpCMouseControl.h" // inserm namespace OpenViBE { namespace Plugins { namespace Tools { OVP_Declare_Begin() // @BEGIN inserm OVP_Declare_New(CMouseControlDesc) context.getTypeManag...
f860b2af6e8f922fc59fee1dac8fac13ea507ebe3ff5d395cc866573d53855f5
C++
630
22
#include "visualization-toolkit/ovviz_all.h" #include "ovvizCVisualizationContext.hpp" namespace OpenViBE { namespace { VisualizationToolkit::CVisualizationContextDesc visualizationContextDesc; } // namespace bool VisualizationToolkit::initialize(const Kernel::IKernelContext& ctx) { Kernel::ITypeManager& typeMa...
f12d2028598f7fc48338b8e33d95829d8ba5a0cbf6a0d9a194f401f3de3120b8
C++
642
15
#include "ovasCConfigurationGenericTimeSignal.h" namespace OpenViBE { namespace AcquisitionServer { CConfigurationGenericTimeSignal::CConfigurationGenericTimeSignal(IDriverContext& ctx, const char* gtkBuilderFilename) : CConfigurationBuilder(gtkBuilderFilename), m_driverCtx(ctx) {} bool CConfigurationGenericTime...
6c2ab6e732c07579e0ae89148208f3d6dbf0f6854a60d8ef36a92047cf1e630a
C++
650
20
#include "MonotoneRegressor.h" #include "PAVARegressor.h" #include "ISplineTRRRegressor.h" #include <stdexcept> std::unique_ptr<MonotoneRegressor> make_monotone_regressor(RegressorType type) { std::unique_ptr<MonotoneRegressor> ptr; switch (type) { case RegressorType::PAVA: ptr = std::unique_ptr<Monotone...
52206d6924c8eee5b92730bba0536a91c111b92306d945aee72c0b2f4b4a5771
C++
657
23
/* * Prints user-specified greeting to the log with given frequency */ #include "ovpCHelloWorld.h" #include <openvibe/CTime.hpp> namespace OpenViBE { namespace Plugins { namespace Examples { uint64_t CHelloWorld::getClockFrequency() { return CTime(double(FSettingValueAutoCast(*this->getBoxAlgorithmContext(), 0))...
448533c40ff89ae686da02a7757325638baf735dadccbb58dc647cb5607cd475
C++
658
28
/** * SPDX-FileCopyrightText: Inria <thomas.prampart@inria.fr> * SPDX-License-Identifier: AGPL-3.0-only */ #include <QGuiApplication> #include <QQmlApplicationEngine> #include <QQmlContext> #include <QQuickStyle> #include "updateHandler.h" int main(int argc, char *argv[]) { QGuiApplication app(argc, argv); ...
3519ac4b8c891f3757c2e14cc48fd0b971ebf0ab06c1483a5219ff192f72401e
C++
660
20
#include "gtest/gtest.h" #include "Eikonal.h" TEST(Basic3D, NonMaxUnstructured) { Eikonal data(false); data.filename_ = TEST_DATA_DIR + std::string("sphere334"); EXPECT_NO_THROW(data.solveEikonal()); for (size_t i = 0; i < data.getFinalResult().size(); i ++) { EXPECT_TRUE(data.getFinalResult()[i] < 100.); ...
a366549a59cd708465e3a984979d3f4ce947c22e4c983c8e6f4de553b54207bb
C++
666
26
#include <openvibe/ov_all.h> #include "ovp_defines.h" #include "box-algorithms/ovpCBoxAlgorithmMatlabScripting.h" #include <vector> namespace OpenViBE { namespace Plugins { namespace Matlab { OVP_Declare_Begin() #if defined TARGET_HAS_ThirdPartyMatlab OVP_Declare_New(CBoxAlgorithmMatlabScriptingDesc) cont...
5a8b5a32d59a193152f8a525f2e8997b87837322f75d805bc3f1affa1fef1947
C++
667
22
#include <cstdint> #include <random> #include <iostream> #include <sstream> #include <iomanip> int main(int /*argc*/, char** /*argv*/) { std::random_device rd; std::default_random_engine rng(rd()); std::uniform_int_distribution<uint32_t> uni(0, std::numeric_limits<uint32_t>::max() - 1); for (int i = 0...
0a0f33e93faf7a235a938946057cb4a941f0ddfb4f97d319e7c2c3d37785eade
C++
674
28
#if defined(OS_LINUX) #include <hex/helpers/logger.hpp> #include <vector> #include <string> #include <unistd.h> namespace hex { void executeCmd(const std::vector<std::string> &argsVector) { std::vector<char*> cArgsVector; cArgsVector.reserve(argsVector.size()); for (const auto &str : arg...
85f6c76ae74267d5bfcc328cbe915826d266209ddc142633ba70537eae8f7cc7
C++
681
15
#include "ebml/CReaderHelper.h" namespace EBML { CReaderHelper::CReaderHelper() { m_impl = createReaderHelper(); } CReaderHelper::~CReaderHelper() { m_impl->release(); } uint64_t CReaderHelper::getUInt(const void* buffer, const size_t size) { return m_impl->getUInt(buffer, size); } int64_t CReaderHelper::getInt(cons...
1a9d2746931112f1df5b781eb4ff9cf41e32669e6060e45132e09003349ddbc5
C++
696
33
#include <script_api.hpp> #include <hex/helpers/logger.hpp> #define VERSION V1 SCRIPT_API(void logPrint, const char *message) { hex::log::print("{}", message); } SCRIPT_API(void logPrintln, const char *message) { hex::log::println("{}", message); } SCRIPT_API(void logDebug, const char *message) { hex::...
fc4f7a11683924906a80cc8cefe82e7f191f897a235910b72d74b4dac435d834
C++
701
31
#include <hex/plugin.hpp> #include <hex/api/content_registry/views.hpp> #include <hex/helpers/logger.hpp> #include <romfs/romfs.hpp> #include "content/views/view_diff.hpp" namespace hex::plugin::diffing { void registerDiffingAlgorithms(); } using namespace hex; using namespace hex::plugin::diffing; IMHEX_P...
bbadc1384b9d98db3bb8ffea338aa5a96515e5b90ae05074fa5e570817c7a631
C++
702
23
#include "gtest/gtest.h" #include "Eikonal.h" TEST(Sanity2D, Filename) { Eikonal* data = new Eikonal(true); data->filename_ = "notarealfile"; EXPECT_EXIT(data->solveEikonal(), ::testing::ExitedWithCode(1), ""); delete data; data = new Eikonal(true); data->filename_ = TEST_DATA_DIR + std::string("sphe...