sha256 stringlengths 64 64 | language stringclasses 27
values | size int32 1 491k | lines int32 1 21.8k | content stringlengths 1 200k |
|---|---|---|---|---|
5e11267626cda4138b6e9cbe94497addf9fc20420f79189be0b04c8e96cc8f03 | C++ | 4,441 | 148 | #include "circular_Fourier_filament_model.h"
#include "coordinate_conventions.h"
#include <omp.h>
using namespace gravis;
CircularFourierFilamentModel::CircularFourierFilamentModel(
double length,
const std::vector<d4Matrix>& proj,
double padding )
: length(length),
padding(padding),
proj(proj),
totalLeng... |
e3650f31fec898c246821a6688df495d0e0b0ed9eaa3d68d65ab5cbd81586980 | C++ | 4,452 | 144 | /*
* Copyright (c) Facebook, Inc. and its affiliates.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree.
*/
#include <gtest/gtest.h>
#include "fully-connected-sparse-operator-tester.h"
#define SPARSE_OP_TEST... |
e88b4d7d0b123ffb19668f7f4a7ea5cccfedfdf911a8175e5770bcc1bb6169ce | C++ | 4,463 | 179 | #include <src/jaz/single_particle/stack_helper.h>
#include <src/jaz/gravis/t2Vector.h>
#include <src/metadata_table.h>
using namespace gravis;
int main(int argc, char *argv[])
{
IOParser parser;
parser.setCommandLine(argc, argv);
int gen_section = parser.addSection("General options");
std::string sourceFn = ... |
bbcb14efcbc37bc0a4fcda39fe96d983aa82907ade40f150c81e55e17fc24255 | C++ | 4,464 | 205 | #include "pdb_helper.h"
using namespace gravis;
std::map<std::string,std::vector<d3Vector>> PdbHelper::groupAtomsByName(
const Assembly& assembly)
{
std::map<std::string,std::vector<d3Vector>> out;
const int mc = assembly.molecules.size();
for (int m = 0; m < mc; m++)
{
const Molecule& molecule = assembly.... |
9cad4b316f2971adc57501d72f2db67a527aab353de0029e22572e398d57654c | C++ | 4,465 | 130 | #include "../dep/laynii_lib.h"
int show_help(void) {
printf(
"LN_EXTREMETR: To find extreme the TR time point.\n"
"\n"
" This program tries to find the maximal/minimal value of a time \n"
" series and writes out the timepoint of that TR vor every voxel.\n"
"\n"
"Usage:\n"
" LN... |
39c54c31f3c4eff34a82d2934f241065849bbc8fbf6f3f914ed4b27a012831e4 | C++ | 4,492 | 115 | // Copyright 2004-present Facebook. All Rights Reserved.
#define TORCH_ASSERT_ONLY_METHOD_OPERATORS
#include <ATen/core/Tensor.h>
#include <ATen/Dispatch.h>
#include <c10/util/irange.h>
#ifndef AT_PER_OPERATOR_HEADERS
#include <ATen/Functions.h>
#include <ATen/NativeFunctions.h>
#else
#include <ATen/ops/_rowwise_prun... |
6f5ec434ce3ac383f38c51c32c4e6ced5d3c926c4ff31b7e76178b993451c2c5 | C++ | 4,497 | 87 | #include <algorithm>
#include <numeric>
#include <cstdint>
#include <mex.h>
template<typename Number>
void sumDataByBin(const mxArray* mat_X, const double* bin, const size_t nData, const int nBins, double* sumX, double* totalX)
{
const bool doTally = mxIsEmpty(mat_X);
const size_t ... |
bc5e6aef5a767576efcdc3c982ce1b2e5379463df698887d8d93cfe2781ae726 | C++ | 4,497 | 93 | /**
Converts a (presumably symmetric) matrix to a list of upper-triangular elements. Note that actual symmetry
of elements in the input matrix is not enforced, but the code does require that the first two dimensions
be the same size.
*/
#include "mex.h"
#include <vector>
#include <cmath>
#include <cst... |
d1d5606c9a29b83c59f71494127b9ef6261cbae493d2f8b33da35da5f57bf607 | C++ | 4,541 | 183 | #include "fcc.h"
#include <src/jaz/tomography/particle_set.h>
#include <src/jaz/tomography/projection/fwd_projection.h>
#include <src/jaz/tomography/prediction.h>
#include <src/jaz/tomography/reconstruction.h>
#include <src/jaz/tomography/tomo_ctf_helper.h>
#include <src/jaz/tomography/tomogram.h>
#include <src/jaz/im... |
c26c3cf87b1301a9c11e16afefc97cb72fa93e4520cf36b9877e744c2ad82e58 | C++ | 4,550 | 142 | /***************************************************************************
*
* Author: "Sjors H.W. Scheres" "Jasenko Zivanov"
* MRC Laboratory of Molecular Biology
*
* 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
* t... |
ba65008609211af35599c2d284b60c27ac07464378011db328d3a2ec46b7d59d | C++ | 4,554 | 146 | #define TORCH_ASSERT_ONLY_METHOD_OPERATORS
#include <ATen/core/Tensor.h>
#include <ATen/TensorOperators.h>
#ifndef AT_PER_OPERATOR_HEADERS
#include <ATen/Functions.h>
#include <ATen/NativeFunctions.h>
#else
#include <ATen/ops/affine_grid_generator_backward_native.h>
#include <ATen/ops/affine_grid_generator_native.h>
#... |
431c8680357416dc58202a75852e0dbd1030698b4d038ec3e76f2fdb67f9d86d | C++ | 4,573 | 187 | /*
* axi_gpio.cpp
*
* Created on: Mar 8, 2017
* Author: arios
*/
#include "axi_gpio.hpp"
Axigpio::Axigpio(int gl_gpio_base)
{
this->gl_gpio_base = gl_gpio_base;
this->nchannel = open_gpio_channel();
}
Axigpio::~Axigpio()
{
close_gpio_channel();
}
int Axigpio::open_gpio_channel(/*int gpio_base*/)
{
ch... |
0340ae4070490de5cb9179d46b42fb97ee6dda9ca422c325b46fe7f4188cd892 | C++ | 4,587 | 106 | //NS: CUDACachingAllocator must be included before to get CUDART_VERSION definedi
#include <ATen/cuda/Exceptions.h>
namespace at::cuda {
namespace blas {
C10_EXPORT const char* _cublasGetErrorEnum(cublasStatus_t error) {
if (error == CUBLAS_STATUS_SUCCESS) {
return "CUBLAS_STATUS_SUCCESS";
}
if (error == C... |
edf71b3eeb8d9e3b08c2b2eca831ba8d29864d58735f7676572830430aa8191a | C++ | 4,588 | 210 | /***************************************************************************
*
* Author: "Jasenko Zivanov"
* MRC Laboratory of Molecular Biology
*
* 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 Foun... |
530881177347fd5b0f69adfa829ef5778a61e809e70eeaa6e10cd692b2ddfad1 | C++ | 4,605 | 150 | #include "udp_client.h"
#include "udp_receiver.h"
#include "spike_detector.h"
#include "plot_server.h"
#include "spike_collector.h"
#include <iostream>
#include <unistd.h>
#include <sys/wait.h>
#include <sys/socket.h>
#include <sys/un.h>
#include <vector>
#include <memory>
#include <chrono>
#include <thread>
#in... |
18ae21b6ef13a7c1f69e72b5207acb4c22042725f67e28c7de2a077339d0bcc5 | C++ | 4,606 | 183 | /*
* Copyright (c) Facebook, Inc. and its affiliates.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree.
*/
#include <cpuinfo.h>
#include <gtest/gtest.h>
#include <qnnpack/hgemm.h>
#include <qnnpack/isa-check... |
e5250ad876b5b6d57146ab43ee8ebf5a6b5155b1eb5583913a386ef39ae8c820 | C++ | 4,676 | 163 | #define TORCH_ASSERT_ONLY_METHOD_OPERATORS
#include <ATen/Context.h>
#include <ATen/core/Tensor.h>
#include <ATen/detail/CUDAHooksInterface.h>
#include <ATen/native/TensorProperties.h>
#ifndef AT_PER_OPERATOR_HEADERS
#include <ATen/Functions.h>
#include <ATen/NativeFunctions.h>
#else
#include <ATen/ops/_nested_tensor_... |
35f7748d3a2393eddfee0f600cd72565c4f0f97ec0e1a8d0c7504e7dd36cfdd5 | C++ | 4,681 | 155 | // 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 2
// of the License, or (at your option) any later version.
// This program is distributed in the hope that it will be use... |
4cbe3929a24a94a1eb250caf72802fdfcc24edc0d05fced9167a09423f049835 | C++ | 4,688 | 143 | #include <ATen/native/SparseTensorUtils.h>
#include <ATen/ATen.h>
#include <ATen/SparseTensorImpl.h>
#include <ATen/native/sparse/SparseStubs.h>
#include <ATen/Parallel.h>
#include <c10/util/irange.h>
#ifndef AT_PER_OPERATOR_HEADERS
#include <ATen/Functions.h>
#else
#include <ATen/ops/_sparse_coo_tensor_with_dims_and... |
718cab6d396218c9612d70859702e0426ee468dcce098c422ec5b80694bbf541 | C++ | 4,698 | 125 | #include "../dep/laynii_lib.h"
#include <sstream>
int show_help(void) {
printf(
"LN2_SENSITIVITY: Compute a voxel-wise measure of functional sensitivity\n"
" from a 4D nifti containing fMRI responses to multiple\n"
" (at least 2) tasks (e.g. betas, percent signal changes... |
6d5ce046c4814d624dfd1e9c6946b2bb2fce499266e3feb0c61f572e58020699 | C++ | 4,699 | 142 | // Copyright 2004-present Facebook. All Rights Reserved.
#define TORCH_ASSERT_ONLY_METHOD_OPERATORS
#include <ATen/core/Tensor.h>
#include <ATen/FunctionalInverses.h>
#include <ATen/ScalarOps.h>
#include <ATen/Parallel.h>
#ifndef AT_PER_OPERATOR_HEADERS
#include <ATen/Functions.h>
#include <ATen/NativeFunctions.h>
#e... |
b9a05f04ef8389ba5dd545583b82073222cb99beb295b94f212fbf4fb20763ab | C++ | 4,716 | 138 | // Copyright © 2022 Apple Inc.
#include <c10/metal/common.h>
#include <ATen/ATen.h>
#include <ATen/Tensor.h>
#include <ATen/Utils.h>
#include <torch/library.h>
#include <ATen/mps/EmptyTensor.h>
#include <ATen/mps/MPSDevice.h>
#include <ATen/native/Resize.h>
#include <ATen/native/TensorFactories.h>
#include <ATen/nativ... |
47c3dd990a3252dc6d34a04fc5f8dae9f3b450a9149c6ad6c23cb3da5fbf8b17 | C++ | 4,736 | 130 | #include <ATen/ATen.h>
#include <ATen/core/op_registration/op_registration.h>
#include <ATen/native/metal/MetalPrepackOpContext.h>
#include <c10/util/accumulate.h>
namespace at::native::metal {
static c10::intrusive_ptr<Conv2dOpContext> unpack(
Tensor&& weight,
std::optional<Tensor>&& bias,
std::vector<in... |
5a1a1cad3e4c92c2a94307680a89b78066b93eea9d6e84e116196b3e5b0b6d7d | C++ | 4,779 | 164 | // Functions that fill Tensors with constants.
#define TORCH_ASSERT_ONLY_METHOD_OPERATORS
#include <ATen/native/Fill.h>
#include <ATen/core/Tensor.h>
#include <ATen/ScalarOps.h>
#include <ATen/TensorIterator.h>
#include <ATen/TensorOperators.h>
#include <c10/util/accumulate.h>
#include <c10/util/irange.h>
#ifndef AT_... |
5f8e6b00a6ebf6ef2653f528df839c855860f457f04a6222176fe738e72c75de | C++ | 4,855 | 108 | #define TORCH_ASSERT_ONLY_METHOD_OPERATORS
#include <ATen/core/Tensor.h>
#include <c10/core/impl/COW.h>
#ifndef AT_PER_OPERATOR_HEADERS
#include <ATen/Functions.h>
#include <ATen/NativeFunctions.h>
#else
#include <ATen/ops/_has_same_storage_numel_native.h>
#include <ATen/ops/_make_dual_native.h>
#include <ATen/ops/_ne... |
e3d3baa6debd55b1a764e47deac8f6b5446165c2455a219d820adfb0ee65c3ee | C++ | 4,855 | 205 | #include "bfactor_fit.h"
#include <src/ctf.h>
#include <src/jaz/optics/damage.h>
#include <src/jaz/math/fcc.h>
#include <src/jaz/tomography/tomogram.h>
#include <src/jaz/tomography/motion/proto_alignment.h>
#include <src/jaz/tomography/projection_IO.h>
#include <src/jaz/tomography/prediction.h>
#include <src/jaz/tomogr... |
e22593a4358c4e799151ffc77e567e6474000eb797381bda28a237d344bc83dc | C++ | 4,859 | 152 | #define TORCH_ASSERT_ONLY_METHOD_OPERATORS
#include <ATen/core/Tensor.h>
#include <ATen/Dispatch.h>
#include <ATen/Parallel.h>
#include <ATen/cpu/vec/vec.h>
#include <ATen/native/UnfoldBackward.h>
#include <ATen/native/cpu/Loops.h>
#include <c10/util/irange.h>
#if (defined(_WIN32) || defined(_WIN64))
#define RESTRICT ... |
a594f80c6185374da45ca0d3462b16eb69c623ac018ee8e3cbaba8f012469095 | C++ | 4,862 | 106 | #include <ATen/Config.h>
#if AT_MKLDNN_ENABLED()
#include <ATen/Tensor.h>
#include <ATen/native/mkldnn/ConvPrepack.h>
#include <ATen/native/mkldnn/OpContext.h>
#include <ATen/native/mkldnn/Utils.h>
#include <torch/custom_class.h>
#include <torch/library.h>
namespace at::native::mkldnn {
using namespace internal::co... |
eb714c375d83ef8d51fea49159dcb5e95b196eafe02844baac7b56bb7b0b0135 | C++ | 4,871 | 112 | #include <algorithm>
#include <vector>
#include <mex.h>
double sqr(double x) { return x*x; }
template<typename Number>
double andersonDarlingStat(const mxArray* mat_X, const mxArray* mat_Y)
{
const Number* X = (const Number*) mxGetData(mat_X);
const Number* Y ... |
27ee650f341e16f80b460cdc0bd68ac94da41b712c07d591faf54ddaeacc3aad | C++ | 4,881 | 140 | #include <c10/macros/Macros.h>
#include <ATen/core/dispatch/Dispatcher.h>
#include <ATen/core/op_registration/op_allowlist.h>
#include <ATen/core/op_registration/op_registration.h>
#if !defined(CAFFE2_IS_XPLAT_BUILD)
#endif
namespace c10 {
namespace impl {
void build_feature_required_feature_not_available(const char*... |
d78ee9e05cc0690a7d08590528b77f7cf4eec4a4937f95489d931aaee7548f2e | C++ | 4,894 | 146 | #include <ATen/miopen/Descriptors.h>
#include <ATen/ATen.h>
#include <c10/util/irange.h>
#include <iostream>
namespace at { namespace native {
namespace {
inline miopenDataType_t getDataType(const at::Tensor& t) {
auto scalar_type = t.scalar_type();
if (scalar_type == at::kFloat) {
return miopenFloat;
} e... |
71b6aabca4f1c293209f326b3f0f995b4d3f9e5091c251d3f2aa187d20981eff | C++ | 4,900 | 159 | #define TORCH_ASSERT_ONLY_METHOD_OPERATORS
#include <ATen/core/Tensor.h>
#include <ATen/Config.h>
#include <ATen/ExpandUtils.h>
#ifndef AT_PER_OPERATOR_HEADERS
#include <ATen/NativeFunctions.h>
#else
#include <ATen/ops/add_native.h>
#include <ATen/ops/empty_native.h>
#include <ATen/ops/mul_native.h>
#endif
#if !AT_MK... |
7c3397fb0414d801ed2e23c63d88cb4d04815bb89f16a9176f32ce26064bee8c | C++ | 4,901 | 185 | /***************************************************************************
*
* Author: "Sjors H.W. Scheres"
* MRC Laboratory of Molecular Biology
*
* 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 F... |
856dce3c7dc8bf542734e4e21b204502c7c3867873ce3e68af65da924f6bf95c | C++ | 4,930 | 148 | #define TORCH_ASSERT_ONLY_METHOD_OPERATORS
#include <ATen/core/Tensor.h>
#include <ATen/TensorMeta.h>
#include <ATen/TensorUtils.h>
#include <ATen/native/UpSample.h>
#ifndef AT_PER_OPERATOR_HEADERS
#include <ATen/Functions.h>
#include <ATen/NativeFunctions.h>
#else
#include <ATen/ops/_upsample_nearest_exact1d.h>
#incl... |
4a05ddb31bc0236cc469b1e9aa3e166abd967f97bc62e6111f2cc52abb4ffe75 | C++ | 4,949 | 172 | #define TORCH_ASSERT_ONLY_METHOD_OPERATORS
#include <ATen/core/Tensor.h>
#include <ATen/native/DispatchStub.h>
#include <ATen/native/FusedAdam.h>
#ifndef AT_PER_OPERATOR_HEADERS
#include <ATen/Functions.h>
#include <ATen/NativeFunctions.h>
#else
#include <ATen/ops/_fused_adam_native.h>
#include <ATen/ops/_fused_adamw_... |
5954b53a67c1d203c1e3f2b9fe86cf8e3e337130b9ea0c8fc9f04d2c49b55c1c | C++ | 4,951 | 149 | //***********************************************************************************************
//
// Copyright (c) 1996-1997 Axon Instruments.
// All rights reserved.
//
//***********************************************************************************************
// MODULE: FileReadCache.cpp
// PUR... |
559acd8a1ed757d661c6bd8fe5fc7fa70835f7808092c9570a0d8ae63fb242a7 | C++ | 4,968 | 220 | #include "shift_alignment.h"
#include <src/jaz/image/buffered_image.h>
#include <src/jaz/image/centering.h>
#include <src/jaz/image/interpolation.h>
#include <src/jaz/image/color_helper.h>
#include <src/jaz/image/power_spectrum.h>
#include <src/jaz/tomography/prediction.h>
#include <src/jaz/math/fft.h>
#include <src/ja... |
e382c5aa1c5639992421cf56634495d983e6ca1cd8295ea52b0c6487fccc04aa | C++ | 4,989 | 140 | /* Contact ythomas@csail.mit.edu or msabuncu@csail.mit.edu for bugs or questions */
/*=========================================================================
Copyright (c) 2008 Thomas Yeo and Mert Sabuncu
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are ... |
776697ad67a1fcf43712f1f54b797ec7d6089850e7874407e54ad15c0e05e6f4 | C++ | 5,002 | 101 | /**
Converts a list of lower-triangular elements to a matrix with zeros in the triangle above the diagonal.
*/
#include "mex.h"
#include <vector>
#include <cmath>
#include <cstdint>
template<typename Number>
void makeTriangularMatrix(const mxArray* mat_tril, const mwSize k, mxArray* mat_M, const double ... |
73af36dff68bd051927e14235564d17dcd5768da5fc83bf2b73555be57419b32 | C++ | 5,023 | 172 | #define TORCH_ASSERT_ONLY_METHOD_OPERATORS
#include <ATen/core/Tensor.h>
#include <ATen/Context.h>
#include <ATen/Dispatch.h>
#include <torch/library.h>
#include <ATen/native/quantized/AffineQuantizerBase.h>
#include <ATen/native/quantized/cpu/QuantizedOps.h>
#include <ATen/native/quantized/cpu/init_qnnpack.h>
#include... |
fed076bce8afa6e2fcc756195efa44e67595862ce5cf65e145f4dd90f4dec317 | C++ | 5,081 | 190 | #ifndef __NPP_LOG_UTILITIES_CPP__
#define __NPP_LOG_UTILITIES_CPP__
//#include "npp_log_utilities.h"
#include "string.h"
#include <iostream>
#include <stdexcept>
#include <stdlib.h>
#include <stdio.h>
#include <stdarg.h>
#include <ctime>
namespace log_utilities {
static const uint16_t MAX_SIZE_LINE = 32768; //app... |
0b846408f228fc83c82a85da83ec249705798dd0ddc28c3bf1fa958744f36789 | C++ | 5,084 | 317 | #include "zio.h"
#include <src/pipeline_control.h>
#include <string.h>
#include <stdio.h>
std::vector<double> ZIO::readDoubles(std::string fn)
{
std::vector<double> out(0);
std::ifstream ifs(fn);
std::string line;
if (!ifs)
{
REPORT_ERROR("ZIO::readDoubles: unable to read "+fn);
}
out.reserve(128);
w... |
4417dede71df32bdf36be304eb4227b8b2fa28c92a6d536809535ee275d92ffc | C++ | 5,124 | 128 | #include "utilities.h"
#include <algorithm>
#include <mex.h>
/**
*/
void compactify ( const mxArray* coordArray
, const size_t nData
, const mwSize nDims
, const mwSize* dimensions
, const double* data
... |
0cf218343fe9e8b4770f0a430d00f6fc5e9ac4c34d41c4c0407c01154e2e02c0 | C++ | 5,130 | 166 | /*
* Copyright (c) Facebook, Inc. and its affiliates.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree.
*/
#include <algorithm>
#include <cfloat>
#include <chrono>
#include <cmath>
#include <functional>
#incl... |
cafe26acc15ec6a525be90cc8cd3e2e2d33aba7e98d89b41634c03de0e1913df | C++ | 5,140 | 186 | #include "reconstruct_particle_mpi.h"
#include <src/jaz/tomography/projection/projection.h>
#include <src/jaz/tomography/projection/Fourier_backprojection.h>
#include <src/jaz/tomography/reconstruction.h>
#include <src/jaz/image/centering.h>
#include <src/jaz/image/padding.h>
#include <src/jaz/image/power_spectrum.h>
#... |
f5855dbfaaeec3f75b5e67cbce4916e8991f5169298d1ccf4ab2946b6698369b | C++ | 5,149 | 122 | #include <ATen/core/Tensor.h>
#include <ATen/LegacyBatchedTensorImpl.h>
#include <ATen/WrapDimUtils.h>
#include <ATen/LegacyVmapTransforms.h>
#ifdef AT_PER_OPERATOR_HEADERS
#include <ATen/ops/_add_batch_dim_native.h>
#include <ATen/ops/_remove_batch_dim_native.h>
#endif
namespace at::native {
// Adds a batch dimensi... |
b4f07fe3bf200c2381d3365888e1fe561bcd1b7ccec65f5a49b4802ce750df85 | C++ | 5,173 | 151 | #include "../dep/laynii_lib.h"
int show_help(void) {
printf(
"LN_ZSCORE: Standardize timeseries (z-score). It is calculated by subtracting\n"
" the voxel-wise mean from each voxel value and then dividing the \n"
" difference by the voxel-wise standard deviation.\n"
"\n"
"Us... |
afee11ec7e1d14eeb835c9542e499e7ee4a2cc57e201372a0d93c7d9743d0439 | C++ | 5,183 | 150 | #define TORCH_ASSERT_ONLY_METHOD_OPERATORS
#include <ATen/core/Tensor.h>
#include <ATen/native/AdaptivePooling.h>
#include <ATen/native/xnnpack/Engine.h>
#ifndef AT_PER_OPERATOR_HEADERS
#include <ATen/Functions.h>
#include <ATen/NativeFunctions.h>
#else
#include <ATen/ops/_adaptive_avg_pool2d.h>
#include <ATen/ops/_ad... |
c826a443bc1f83630f7113dc04939619ef2c4285d25dd1a044f6672ae32cecb4 | C++ | 5,190 | 191 | #include <stdlib.h>
#include <string.h>
/*#include <cmath>*/
#include <math.h>
#include "mex.h"
template <typename T> void rescale_XI(mwSize nX, mwSize nXI,
mwSize *XIi, T *XId, const T *X, const T *XI) {
mwSize ix, ixi;
T x1, x2, xi;
for(ixi = 0; ixi < nXI; ixi++) {
xi = XI[ixi];
XIi[ixi] = nX;
XId[ix... |
57add8cac0a54ed1a0c9b1fd4bfc8f74f64684f5b58358a50c9d17056d8e3529 | C++ | 5,221 | 171 | /***************************************************************************
*
* Author: "Sjors H.W. Scheres"
* MRC Laboratory of Molecular Biology
*
* 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 F... |
d3051816902251f83316df03121ff3a5ac55f005fc988bf995e8d14348a4af40 | C++ | 5,240 | 151 | /***************************************************************************
*
* Author: "Dari Kimanius"
*
* 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 2 of the License, ... |
a9ab9b0f5d01e35b1eb935bd3467f261e22fb61c711e160d6c140621c9ecb6f2 | C++ | 5,248 | 137 | #include <tuple>
#include <utility>
#include <vector>
#include <ATen/ATen.h>
#include <torch/library.h>
#include <ATen/native/quantized/cpu/fbgemm_utils.h>
#include <ATen/native/quantized/cpu/QnnpackUtils.h>
#include <ATen/native/quantized/cpu/OnednnUtils.h>
#include <ATen/native/quantized/cpu/QuantUtils.h>
#include <... |
0959271ab3e3f1459fa8f9197cda023906a0e7ea19e581c3e96c003c8b03eba7 | C++ | 5,256 | 147 | #include <ATen/native/mkldnn/xpu/FusionUtils.h>
#include <unordered_set>
using namespace at::native::onednn;
namespace at::native::xpu {
onednn::Attr& handle_argument_less(std::string_view unary, onednn::Attr& attr) {
static const std::unordered_map<
std::string_view,
std::function<onednn::Attr&(onedn... |
28dff57baf4a522e6b5215c20c6a0fad91e8a0380b22efce5f64c3882729e3e7 | C++ | 5,259 | 228 | #include <ATen/Version.h>
#include <ATen/Config.h>
#if AT_MKL_ENABLED()
#include <mkl.h>
#endif
#if AT_MKLDNN_ENABLED()
#include <dnnl.hpp>
#endif
#include <caffe2/core/common.h>
#include <ATen/native/DispatchStub.h>
#include <sstream>
namespace at {
std::string get_mkl_version() {
std::string version;
#if A... |
7f0dec4749300c29bd9d600ff3e71227388773e335d25610f025d6e4739a6309 | C++ | 5,261 | 172 | /*
* Copyright (c) Facebook, Inc. and its affiliates.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree.
*/
#include <algorithm>
#include <cmath>
#include <functional>
#include <random>
#include <vector>
#inc... |
b8ed98dfc3a55b011aa6cf90e45f131b0a96a933246db3c45eb8a23008f2abb6 | C++ | 5,278 | 215 | #include "refinement.h"
#include <src/jaz/tomography/dynamo/catalogue.h>
#include <src/jaz/tomography/projection/projection.h>
#include <src/jaz/tomography/projection/Fourier_backprojection.h>
#include <src/jaz/tomography/reconstruction.h>
#include <src/jaz/image/centering.h>
#include <src/jaz/image/padding.h>
#include... |
16b28c38c51ba33bfa25c725809246f7c5cb72a3966daaad1cd7b84a1acf9ad7 | C++ | 5,284 | 130 | #include <ATen/functorch/Interpreter.h>
#include <ATen/functorch/BatchedTensorImpl.h>
#include <ATen/functorch/TensorWrapper.h>
#include <ATen/functorch/VmapInterpreter.h>
#include <ATen/functorch/FunctionalizeInterpreter.h>
#include <ATen/functorch/ADInterpreters.h>
#include <ATen/functorch/DynamicLayer.h>
namespace ... |
034983860c28242ced483d7d577578c45f872476e60214a034f420bdff7ffc92 | C++ | 5,311 | 140 | #include <vector>
#include <algorithm>
#include <mex.h>
// http://www.geeksforgeeks.org/dynamic-programming-set-9-binomial-coefficient/
size_t binomialCoefficient(size_t n, size_t k, std::vector<size_t>& C)
{
size_t N = n + 1;
C.assign(N * (k+1), 0);
// Caculate value of Binomial Co... |
f445e630898beb3823ffddbdfbbab236efd4675293f112272ac35512eebce948 | C++ | 5,343 | 207 | #include "legacy_obs_model.h"
#include "stack_helper.h"
#include "img_proc/filter_helper.h"
#include "Fourier_helper.h"
#include <src/backprojector.h>
LegacyObservationModel::LegacyObservationModel()
: angpix(-1),
anisoTilt(false)
{
}
LegacyObservationModel::LegacyObservationModel(double angpix, double Cs, dou... |
306ef7a229166fdf4edeab1d9da38711d54949d37e389ffcd824f322d587afef | C++ | 5,369 | 157 | #include <ATen/Context.h>
#include <ATen/core/CachingHostAllocator.h>
#include <ATen/DeviceAccelerator.h>
#include <c10/core/impl/VirtualGuardImpl.h>
namespace at::accelerator {
std::optional<c10::DeviceType> getAccelerator(bool checked) {
// 1. Check PrivateUse1 backends
// We explicitly allow PrivateUse1 and an... |
39f23a217b4f4fd45ecc8e8a482ea43c57fe599d3e7bef936909ecbe863b6b0c | C++ | 5,379 | 222 | #include "optimisation_set.h"
void OptimisationSet::read(
IOParser &parser, bool showOptimisationSet,
bool showParticles, bool particlesMandatory,
bool showTomograms, bool tomogramsMandatory,
bool showTrajectories, bool trajectoriesMandatory,
bool showManifolds, bool manifoldsMandato... |
d7dc3c06cc6f2ccebd9096ab17c69c32ff0654b432af38f42b890250354f9f0e | C++ | 5,382 | 181 | #include <ATen/core/Tensor.h>
#include <ATen/core/VariableHooksInterface.h>
#ifndef AT_PER_OPERATOR_HEADERS
#include <ATen/MethodOperators.h>
#else
#include <ATen/ops/contiguous_ops.h>
#include <ATen/ops/fill_ops.h>
#include <ATen/ops/to_ops.h>
#include <ATen/ops/zero_ops.h>
#endif
#include <iostream>
namespace at {... |
2ba34491fe489ce0217ac198e0ee88241e77b9d3a6c7b84d81f6f2ea0f61c51f | C++ | 5,410 | 141 | #define TORCH_ASSERT_ONLY_METHOD_OPERATORS
#include <ATen/core/Tensor.h>
#include <ATen/Context.h>
#include <ATen/cpp_custom_type_hack.h>
#include <ATen/native/quantized/cpu/fbgemm_utils.h>
#include <ATen/native/quantized/PackedParams.h>
#include <ATen/native/quantized/cpu/OnednnUtils.h>
#include <ATen/native/quantized... |
76a08cce4697710d70b7a99fade4cebbbeca50451517072637683b588d8f62c6 | C++ | 5,450 | 163 | // Copyright © 2022 Apple Inc.
#include <ATen/ATen.h>
#include <ATen/Tensor.h>
#include <ATen/Utils.h>
#include <torch/library.h>
#include <ATen/mps/EmptyTensor.h>
#include <ATen/mps/MPSDevice.h>
#include <ATen/native/Resize.h>
#include <ATen/native/ResizeCommon.h>
#include <ATen/native/mps/Copy.h>
#include <ATen/nat... |
a5d427629f8f5af97cc8aab169c1c286083379f5222ff81dca5c0d78fe3d8d0c | C++ | 5,451 | 182 | #define TORCH_ASSERT_ONLY_METHOD_OPERATORS
#include <ATen/core/Tensor.h>
#include <ATen/TensorUtils.h>
#include <ATen/native/xnnpack/Engine.h>
#include <c10/util/Exception.h>
#ifndef AT_PER_OPERATOR_HEADERS
#include <ATen/Functions.h>
#include <ATen/NativeFunctions.h>
#else
#include <ATen/ops/adaptive_avg_pool1d_nativ... |
176902ef45909b0fcc3ab126e4f111909bdc50a1d6c34d1e68b1595e44c84460 | C++ | 5,492 | 142 | #include "../dep/laynii_lib.h"
#include <sstream>
int show_help(void) {
printf(
"LN2_GRAMAG: Compute gradient magnitude image that is the Euclidean norm of \n"
" the first spatial derivatives (sqrt(D_x^2 + D_y^2 + D_z^2)).\n"
" Uses 1-jump voxel neighbors for computations.\n"
... |
ad7b396f72f497ac1bb4552068ae8abd6117193a4e87dca6efbfc5e7d5714dea | C++ | 5,528 | 127 | #include <ATen/autocast_mode.h>
#include <torch/library.h>
// pulls in AT_CUDNN_ENABLED() as defined by cmake
#include <ATen/cuda/CUDAConfig.h>
#if AT_CUDNN_ENABLED()
#include <ATen/native/cudnn/RNNUtils.h>
#endif
namespace at::autocast {
/***************************************************************************... |
6c11ff2a67faf6b4632800369884bb06259e2f10d30799b4c1b2a0606d5774c8 | C++ | 5,569 | 263 | #include "mesh_builder.h"
#include <src/macros.h>
using namespace gravis;
Mesh MeshBuilder::makeBar(
d3Vector p0,
d3Vector p1,
double rad,
int segments)
{
d3Vector d = p1 - p0;
d3Vector q;
if (std::abs(d.x) < std::abs(d.y))
{
q = d.cross(d3Vector(1,0,0)).normalize();
}
else
{
q = d.cross(d3... |
aef3e1389227fb0a165f876826da51caf7bb821d9f6967ab0c7fb846dab55d96 | C++ | 5,605 | 81 | // Generated by using Rcpp::compileAttributes() -> do not edit by hand
// Generator token: 10BE3573-1514-4C36-9D1C-5A225CD40393
#include <RcppArmadillo.h>
#include <Rcpp.h>
using namespace Rcpp;
#ifdef RCPP_USE_GLOBAL_ROSTREAM
Rcpp::Rostream<true>& Rcpp::Rcout = Rcpp::Rcpp_cout_get();
Rcpp::Rostream<false>& Rcpp::R... |
b98c14e639f089e6ff8d8bcc47656a018b94d08220d97b06cdd85c0059a0af82 | C++ | 5,621 | 183 | #define TORCH_ASSERT_ONLY_METHOD_OPERATORS
#include <ATen/core/Tensor.h>
#include <ATen/TensorMeta.h>
#include <ATen/native/Padding.h>
#ifndef AT_PER_OPERATOR_HEADERS
#include <ATen/Functions.h>
#include <ATen/NativeFunctions.h>
#else
#include <ATen/ops/replication_pad1d_backward_native.h>
#include <ATen/ops/replicati... |
3ed45efc4dff500c42e7a6e16f9eb2a4bcac46994add35097be8f117b4551232 | C++ | 5,628 | 229 | /*
* Copyright (c) Facebook, Inc. and its affiliates.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree.
*/
#include <gtest/gtest.h>
#include "tanh-operator-tester.h"
#include <qnnpack/params.h>
TEST(TANH_O... |
bfeb80561360fbadfc8373f569669cf183ae3243e03537d17dd7e9cb07a14203 | C++ | 5,632 | 140 | #include <vector>
#include <cmath>
#include <mex.h>
//-------------------------------------------------------------------------
// Statistics
//-------------------------------------------------------------------------
class SampleStatistics {
protected:
std::vector<int > numEntries;
std::... |
5c17bacf19768817775acefcc9c21d170e1c674fa49e52b8db68689b888f0bbd | C++ | 5,660 | 169 | /***************************************************************************
*
* Author: "Sjors H.W. Scheres"
* MRC Laboratory of Molecular Biology
*
* 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 F... |
2a33a0529e4086d928fe83877583247fe3022ec567ca89d71eb01952c93f3df8 | C++ | 5,681 | 182 | #define TORCH_ASSERT_ONLY_METHOD_OPERATORS
#include <ATen/core/Tensor.h>
#include <ATen/Dispatch.h>
#include <ATen/native/Pool.h>
#include <ATen/native/quantized/cpu/init_qnnpack.h>
#include <ATen/native/quantized/cpu/QnnpackUtils.h>
#include <ATen/native/quantized/cpu/QuantizedOps.h>
#ifndef AT_PER_OPERATOR_HEADERS
#... |
d5034400c93dfa361dfc24763fe08c9bf81b0537b2a2723d3054187b36c6101b | C++ | 5,682 | 192 | /*
* Copyright (c) Facebook, Inc. and its affiliates.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree.
*/
#include <algorithm>
#include <cfloat>
#include <chrono>
#include <cmath>
#include <functional>
#incl... |
c2a0bd07b28461d5d79226602a581ab0072964c7daeee53c202df39b4b8db00e | C++ | 5,689 | 234 | #include "filament.h"
#include "closest_spline_point_problem.h"
#include <src/jaz/optimization/recursive_line_search.h>
#include <src/jaz/optimization/nelder_mead.h>
#include <map>
#include <omp.h>
using namespace gravis;
void Filament::computeArcLength(
const Spline<d3Vector, double>& spline,
int samples,
st... |
13fc44b8d91646dafb89623aaba27fb9ea7e3b4e95e96bed6817ada6cd67834a | C++ | 5,700 | 226 |
#include <unistd.h>
#include <string.h>
#include <fstream>
#include <src/args.h>
#include <src/image.h>
#include <src/metadata_table.h>
#include <src/jaz/single_particle/img_proc/filter_helper.h>
#include <src/jaz/single_particle/stack_helper.h>
#include <src/jaz/single_particle/obs_model.h>
#include <src/jaz/single_... |
673c9f4719d9883d6580cdba0f083467d605a01afcb230b0ffc8dd23693a8105 | C++ | 5,705 | 114 | #define TORCH_ASSERT_ONLY_METHOD_OPERATORS
#include <ATen/mps/MPSDevice.h>
#include <ATen/native/mps/operations/ConvolutionHeuristics.h>
#include <c10/metal/common.h>
#include <algorithm>
#include <limits>
namespace at::native::mps {
// Estimate padded work adjusted for staging efficiency and device occupancy.
// Lo... |
0baa61e550b83585b9a7c09d4fe9247822e2a40ac9a45b7640c2af6e1d60486a | C++ | 5,709 | 150 | /**
Returns the n-th most extreme elements, where n = 1 are the min and max elements.
Different columns of the input data are processed separately, i.e. the most extreme
elements down the column are searched for.
*/
#include "mex.h"
#include <vector>
#include <numeric>
#include <algorithm>
#include <fu... |
81fceed6b5dfcabae23625ab92177039ca4448cdd84e9c190e22465e6a2c8856 | C++ | 5,727 | 203 | #include "find_fiducials.h"
#include <src/args.h>
#include <src/jaz/tomography/tomogram.h>
#include <src/jaz/tomography/projection/real_backprojection.h>
#include <src/jaz/tomography/tomogram_set.h>
#include <src/jaz/image/resampling.h>
#include <src/jaz/image/filter.h>
#include <src/jaz/image/detection.h>
#include <sr... |
7e096f9d62b9ab2d25660fe5c616f0ef1e8fd8868bfa0a69ca010a19eed2d9af | C++ | 5,739 | 229 | /*
* Copyright (c) Facebook, Inc. and its affiliates.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree.
*/
#include <gtest/gtest.h>
#include "sigmoid-operator-tester.h"
#include <qnnpack/params.h>
TEST(SIG... |
8c20ef0bf142493024be4589f2de724c2f098adbeadc975b7d3929e64cc44ff4 | C++ | 5,742 | 110 | #include <algorithm>
#include <numeric>
#include <cstdint>
#include <mex.h>
template<typename Number>
void histcounts(const mxArray* mat_X, const double* weight, const double* edges, const size_t nEdges, double* N, double* bin, const bool includeOverflow, const bool normalize)
{
const size_t nX ... |
da6d432dbcf1c5fe5fdc9fda79cc5663e0c3be6e0de7cf119a369451d57e8058 | C++ | 5,755 | 204 | #include <src/args.h>
#include <src/jaz/tomography/imod_import.h>
#include <src/jaz/tomography/tomo_ctf_helper.h>
#include <src/jaz/tomography/tomogram_set.h>
#include <src/jaz/image/buffered_image.h>
#include <src/jaz/util/log.h>
#include <src/jaz/util/zio.h>
#include <src/ctf.h>
enum CtfSource
{
None = 0,
CtfFind ... |
8583cb8ca1d1da7a6607fe3e2df03a04a38ccb63e396d24f76f3c3c844ddc5d6 | C++ | 5,814 | 167 |
#include "../dep/laynii_lib.h"
int show_help(void) {
printf(
"LN_RAGRUG: Generating a file where every voxel has a specific value \n"
" that is indicates its position.\n"
"\n"
" This program is inspired by Kendrick Kay's way of visualizing \n"
" which position at the surface c... |
0506a4079a3c32aeb4cdec79a2f54ed086ad35aef16c5f09bd79ad93adfbdd2a | C++ | 5,842 | 170 | #include <algorithm>
#include <fstream>
#include <iostream>
#include <math.h>
#include <random>
#include <cstdio>
#include <ctime>
#include <vector>
struct ufunc {
std::string name;
double (*f32func)(double);
long double (*f64func)(long double);
float f32ulp;
float f64ulp;
};
template <typename T>... |
fb279805ffe654acb4d31067408b9b3ad191d60750fa2f68f6bbf0ef56d5c549 | C++ | 5,856 | 113 | #include <ATen/SparseTensorImpl.h>
#include <ATen/InitialTensorOptions.h>
namespace at {
namespace {
DeviceType sparseTensorSetToDeviceType(DispatchKeySet key_set) {
auto k = c10::highestPriorityBackendTypeId(key_set);
TORCH_CHECK(c10::toFunctionalityKey(k) == DispatchKey::Sparse,
"cannot create spars... |
8e1cdc944b77f44cd3491f7d8f516a9fb6dc83571cdae144d40be2d2ab7b0ec3 | C++ | 5,859 | 161 | #include <ATen/LegacyBatchedTensorImpl.h>
#include <ATen/WrapDimUtils.h>
#include <c10/util/Exception.h>
#include <c10/util/irange.h>
namespace at {
BatchedTensorImpl::BatchedTensorImpl(Tensor value, BatchDims bdims)
: TensorImpl(
c10::DispatchKeySet(DispatchKey::Batched),
value.dtype(),
value.de... |
9b37e3a75718d40fcec694a896d7fb66685130337398825b5fc1a509222ea2da | C++ | 5,863 | 193 | #define TORCH_ASSERT_ONLY_METHOD_OPERATORS
#include <ATen/Context.h>
#include <ATen/core/Tensor.h>
#include <ATen/cuda/CUDAConfig.h>
#include <ATen/native/GridSamplerUtils.h>
#ifndef AT_PER_OPERATOR_HEADERS
#include <ATen/Functions.h>
#include <ATen/NativeFunctions.h>
#else
#include <ATen/ops/cudnn_grid_sampler_backwa... |
9afce3c747669385b3ad1a0b35cf197fadfeebe8518373ffcfed497715be05e2 | C++ | 5,880 | 186 | #include <ATen/ATen.h>
#include <torch/library.h>
#ifdef USE_RUY_QMATMUL
#include <ATen/Parallel.h>
#include <ATen/native/quantized/cpu/RuyUtils.h>
#include <ruy/ruy.h>
#endif
namespace at::native {
namespace {
inline void check_inputs(const Tensor& qa, const Tensor& qb) {
TORCH_CHECK(
qa.scalar_type() == c... |
36d23ec8103d4d152535a2a48f74fd07ab23c85b2f33f8c9ea09b56028966888 | C++ | 5,887 | 229 | /*
* Copyright (c) Facebook, Inc. and its affiliates.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree.
*/
#include <gtest/gtest.h>
#include "hardsigmoid-operator-tester.h"
#include <qnnpack/params.h>
TEST... |
df3e1ffe7af9b5137c3673fa38d311d8a02112871480977872224786dd15aa01 | C++ | 5,892 | 150 | //******************************************************************************************************************************************************
//Modified version by Ueli Rutishauser, Dec 2011 to allow compilation with GCC on Unix.
//Originals provided by Neuralynx.
//
// Mat2NlxCSC.cpp
// Author: Kevin Iamic... |
5b37d01b4c8658e18cbcdc122db504564373ee856ca6a9b67e076cd70695ac0e | C++ | 5,893 | 191 | #define TORCH_ASSERT_ONLY_METHOD_OPERATORS
#include <ATen/core/Tensor.h>
#include <ATen/native/TypeProperties.h>
#ifndef AT_PER_OPERATOR_HEADERS
#include <ATen/Functions.h>
#include <ATen/NativeFunctions.h>
#else
#include <ATen/ops/_has_compatible_shallow_copy_type_native.h>
#include <ATen/ops/_is_zerotensor_native.h>... |
1e28b26859fe6679ad30da6a9f21fcf5f6875473dff67944251941886267ed63 | C++ | 5,903 | 242 | #include "tomo_ctf_helper.h"
#include <src/jaz/optics/damage.h>
#include <src/jaz/util/zio.h>
using namespace gravis;
std::vector<CTF> TomoCtfHelper :: loadCtffind4(
std::string path, int imageCount,
double voltage, double Cs, double Q0, double Bfac, double scale)
{
/*
example:
# Output from CTFFind... |
58e71775511f6b26f3340823fbab5a56b5600ceafe96a55bec93aee18ffec512 | C++ | 5,904 | 202 | #define TORCH_ASSERT_ONLY_METHOD_OPERATORS
#include <ATen/native/cuda/Sorting.h>
#include <ATen/core/Tensor.h>
#include <ATen/Context.h>
#include <ATen/TensorUtils.h>
#include <ATen/MemoryOverlap.h>
#include <ATen/WrapDimUtils.h>
#include <ATen/cuda/CUDAContext.h>
#include <ATen/cuda/detail/TensorInfo.cuh>
#include <A... |
47f44c0b9a86a9d8562e9e082c2e503602047efbe98bfd6886c0d19e67b4ed0d | C++ | 5,919 | 138 | #define TORCH_ASSERT_ONLY_METHOD_OPERATORS
#include <ATen/native/Pow.h>
#include <ATen/core/Tensor.h>
#include <ATen/ScalarOps.h>
#ifndef AT_PER_OPERATOR_HEADERS
#include <ATen/Functions.h>
#include <ATen/NativeFunctions.h>
#else
#include <ATen/ops/float_power_native.h>
#include <ATen/ops/pow.h>
#include <ATen/ops/po... |
e16d22658afcab2856c9ffc775d73c0329b71e839417ffde90446ea2bb7077ee | C++ | 5,928 | 158 | #define TORCH_ASSERT_ONLY_METHOD_OPERATORS
#include <ATen/core/Tensor.h>
#include <ATen/TensorIterator.h>
#include <ATen/TensorOperators.h>
#include <ATen/native/Activation.h>
#ifndef AT_PER_OPERATOR_HEADERS
#include <ATen/Functions.h>
#include <ATen/NativeFunctions.h>
#else
#include <ATen/ops/cat.h>
#include <ATen/op... |
d5be82f2d2d59fcdb99380e0ed3e78ab92ab7509c2f3c0f3f846989ca918766e | C++ | 5,936 | 173 | #include "spike_collector.h"
// Constructor
SpikeCollector::SpikeCollector()
: running_(false),
zmq_context_(1),
zmq_spike_pub_(zmq_context_, ZMQ_PUB),
zmq_package_pub_(zmq_context_, ZMQ_PUB) {
// Step 1: Set up UNIX sockets and ZeroMQ publishers
setup_internal_sockets();
}
// Destruc... |
cd31a39adc5c0451c9877616558233894152cf224dd1fbbb9ae783633eadfc43 | C++ | 5,953 | 282 | #include "dark_erase.h"
#include <src/jaz/tomography/tomo_stack.h>
#include <src/jaz/tomography/projection/projection.h>
#include <src/jaz/tomography/extraction.h>
#include <src/jaz/optimization/nelder_mead.h>
#include <src/jaz/optimization/lbfgs.h>
#include <src/jaz/optimization/gradient_descent.h>
#include <src/jaz/i... |
388f03a545d10ad6eb5c0035c084618a10d2c399a551a328faa63657d4768cc1 | C++ | 5,954 | 151 | //******************************************************************************************************************************************************
// Mat2NlxEV.cpp
// Author: Kevin Iamiceli
// Created Sept 17, 2003
// Version 2.00
//*********************************************************************************... |
f0cfaa89a33d71fdf582c2ef725993e243e0dcb03c16f926c1755c3ae8912a57 | C++ | 5,966 | 115 | /**
Converts a list of upper-triangular elements to a symmetric matrix.
*/
#include "mex.h"
#include <vector>
#include <cmath>
#include <cstdint>
template<typename Number>
void fillMatrix(mxArray* mat, double value)
{
Number* data = (Number*) mxGetData(mat);
std::fill(data, data + ... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.