sha256 stringlengths 64 64 | language stringclasses 27
values | size int32 1 491k | lines int32 1 21.8k | content stringlengths 1 200k |
|---|---|---|---|---|
07d83bf7f9a4ce480eb2d5aaaa1717f5f095a2859fd800b64061d96b699df52d | C/C++ | 5,244 | 204 | #pragma once
#include <type_traits>
#include <c10/util/intrusive_ptr.h>
#include <c10/util/typeid.h>
#include <c10/macros/Macros.h>
namespace caffe2 {
class Tensor;
/**
* @brief Blob is a general container that hosts a typed pointer.
*
* A Blob hosts a pointer as well as its type, and takes charge of deleting i... |
d6787672cf997fffd72074c41f3389217a82e92cb6f94a5e79e622c61bddc715 | C/C++ | 5,244 | 167 | #ifndef __LIBGRAVIS_LAPACK_H__
#define __LIBGRAVIS_LAPACK_H__
/******************************************************************************
** Title: lapack.h
** Description: Connect our matrix classes to lapack.
**
** Author: Brian Amberg, 2007
** Computer Science Department, Univers... |
07274503281ca108f7c4d8c65164cc0192a5f990316188447316e3c1450226b7 | C/C++ | 5,265 | 164 | /******************************************************************************
** Title: gravis/io/image/f.h
** Description: Implements reader/writer for the .f (vector) file format
**
** Author: Pascal Paysan
** Brian Amberg
** Computer Science Department, University Basel (C... |
7194b6ed1eafc916bb2b39778a29eb8a8d5c3f3a590cd2c7e576a723b431875e | C/C++ | 5,294 | 163 | /*
* Copyright (C) 2016 Bernd Feige
* This file is part of avg_q and released under the GPL v3 (see avg_q/COPYING).
*/
#include <read_struct.h>
#include <inttypes.h>
enum var_type_enum {
FILEVAR=0,
DSVAR
};
enum var_storage_enum {
INT1=0,
WRD1,
INT2,
WRD2,
INT4,
RL4,
RL8,
LSTR
};
enum chan_storage_type_... |
9221961e1aa91d273527561f889bae2da5cfa37122773577468a4642cb4e7218 | C/C++ | 5,345 | 130 | // This file is part of Eigen, a lightweight C++ template library
// for linear algebra.
//
// Copyright (C) 2009-2010 Gael Guennebaud <gael.guennebaud@inria.fr>
//
// This Source Code Form is subject to the terms of the Mozilla
// Public License v. 2.0. If a copy of the MPL was not distributed
// with this file, You c... |
20bfca2858f357fbd212be62849bb8061f141d23558b92fb4c927de7923288c0 | C/C++ | 5,415 | 128 | #pragma once
#include <ATen/native/DispatchStub.h>
#include <ATen/Generator.h>
#include <c10/core/Scalar.h>
namespace at {
class Tensor;
class TensorBase;
struct TensorIteratorBase;
}
namespace at::native {
using unary_fn = void(*)(TensorIteratorBase&);
using unary_fn_with_scalar = void(*)(TensorIteratorBase&, cons... |
8b17a4958dd7488ec6b10ae10243770c165c782cdda49db235f4635c2af7756e | C/C++ | 5,419 | 170 | #pragma once
#include <ATen/Dispatch.h>
#include <ATen/Dispatch_v2.h>
#include <ATen/EmptyTensor.h>
#include <ATen/TensorIterator.h>
#include <ATen/core/Tensor.h>
#include <ATen/native/DispatchStub.h>
#ifndef AT_PER_OPERATOR_HEADERS
#include <ATen/Functions.h>
#else
#include <ATen/ops/scalar_tensor.h>
#endif
namespa... |
ab0ebda1f96baec67ddd1d50a59b9d149f83447605c0de92d852d600060f5153 | C/C++ | 5,428 | 198 | /*
* 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.
*/
#pragma once
#include <algorithm>
#include <cassert>
#include <cmath>
#include <cstddef>
#include <c... |
8ffc31b8c80e58a2eff6ea2d77c496dc59b740ccaf554f5741078f76b6a8d5f3 | C/C++ | 5,430 | 110 | // STOP STOP STOP STOP STOP STOP STOP STOP STOP STOP STOP STOP STOP STOP STOP
// STOP STOP STOP STOP STOP STOP STOP STOP STOP STOP STOP STOP STOP STOP STOP
// STOP STOP STOP STOP STOP STOP STOP STOP STOP STOP STOP STOP STOP STOP STOP
// STOP STOP STOP STOP STOP STOP STOP STOP STOP STOP STOP STOP STOP STOP STOP
// STOP ... |
feff690b74dc6c049e8ec3aba2a06e9bf1dc01fa23596b100282aeaa94d2ab93 | C/C++ | 5,444 | 164 | #pragma once
// See NOTE: [Tensor vs. TensorBase]
// https://github.com/pytorch/pytorch/pull/66979
#include <ATen/core/TensorBase.h>
#include <ATen/native/TensorProperties.h>
#include <ATen/native/CanUse32BitIndexMath.h>
#include <c10/util/DimVector.h>
namespace at::native {
namespace detail {
enum class GridSample... |
83adc152dd2a4fa4ec26ebdb3f4c4a3fe3d0651c46b8b51966d3223f285bae83 | C/C++ | 5,456 | 146 | // Copyright 2004-present Facebook. All Rights Reserved.
#pragma once
#include <ATen/core/Tensor.h>
#include <ATen/MemoryOverlap.h>
#include <ATen/Parallel.h>
#include <ATen/TensorIterator.h>
#include <ATen/cpu/vec/functional.h>
#include <ATen/cpu/vec/vec.h>
#include <c10/util/irange.h>
namespace at::native::detail ... |
e7f230f9e7516fd01bf441221bf60eedf61c05c478495f7235a34f35fead326d | C/C++ | 5,504 | 160 | #pragma once
// Light-weight version of CUDAContext.h with fewer transitive includes
#include <cstdint>
#include <map>
#include <shared_mutex>
#include <cuda_runtime_api.h>
#include <cusparse.h>
#include <cublas_v2.h>
#include <cublasLt.h>
#ifdef CUDART_VERSION
#include <cusolverDn.h>
#endif
#if defined(USE_CUDSS)... |
4b941e6d8601ddba455486b25504c72cca6b390c8f8acff265bc22395486fb07 | C/C++ | 5,509 | 132 | #pragma once
#include <c10/core/impl/LocalDispatchKeySet.h>
#include <c10/macros/Export.h>
#include <c10/macros/Macros.h>
// NOTE [Tracing Mode Switches]
//
// Historically, tracing function was controlled by two switches:
//
// - `AutoDispatchBelowADInplaceOrView` guard
//
// Tracing function used to be script-ge... |
7268e6236df8536cf466e482c022f3f331d6fb83a8ccb8a83f5537889d5a0e5b | C/C++ | 5,524 | 292 | #ifndef __LIBGRAVIS_T_BGR_H__
#define __LIBGRAVIS_T_BGR_H__
/******************************************************************************
** Title: tBGR.h
** Description: Represents an BGR color tupel.
**
** Author:
**
** Computer Science Department, University Basel (CH)
**
**************... |
ea89da4609599d4a992fb4790b4ccfa702d84ee72d8444e00b1b0358f7723dc3 | C/C++ | 5,537 | 251 | #ifndef POWER_SPECTRUM_H
#define POWER_SPECTRUM_H
#include "raw_image.h"
#include "resampling.h"
#include "radial_avg.h"
class PowerSpectrum
{
public:
template <class T>
static std::vector<double> fromFftwHalf(const RawImage<tComplex<T>>& complex);
template <class T>
static T interpolate(double x, double ... |
d5528eb62b6a0ab206937943863ad61face66d5faaa68e8816748be899f98c32 | C/C++ | 5,563 | 161 | #pragma once
#include <bitset>
#include <ATen/ArrayRef.h>
#include <ATen/SmallVector.h>
#include <ATen/Tensor.h>
namespace at {
// We assume this in a few other places in the codebase,
// but there isn't a centralized definition.
constexpr int64_t kVmapMaxTensorDims = 64;
// The valid vmap levels range from [0, 64... |
f176c14b3a62589a684ec36ec17fdd24e5d23649f03debdbba805b304776d138 | C/C++ | 5,569 | 177 | /***************************************************************************
*
* Author: "Takanori Nakane"
* 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... |
9cdfce2ca009ac434113e949b1bf2f4cb1c3c7cfc469ef7c2c6a1b13da899edf | C/C++ | 5,581 | 214 | /*
* 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.
*/
#pragma once
#include <algorithm>
#include <cassert>
#include <cmath>
#include <cstddef>
#include <c... |
5d9f98baac8ac7f8b7c28033b505cd83072eb9cfabd6e32bca8b96db64a1ff97 | C/C++ | 5,583 | 180 | // This file is part of Eigen, a lightweight C++ template library
// for linear algebra.
//
// Copyright (C) 2010 Gael Guennebaud <gael.guennebaud@inria.fr>
//
// This Source Code Form is subject to the terms of the Mozilla
// Public License v. 2.0. If a copy of the MPL was not distributed
// with this file, You can ob... |
a8eba2f8fa1dbfa501d89db851f31a527a9f3ecb199e58efebf351719d0b247d | C/C++ | 5,602 | 242 | #ifndef __LIBGRAVIS_T_DEFAULT_VECTOR_H__
#define __LIBGRAVIS_T_DEFAULT_VECTOR_H__
#include <vector>
#include "tArray.h"
namespace gravis
{
/**
* Like a std::vector, but with a default value returned when accessing [-1].
*
* This situation is checked extremely efficiently by positioning the default
* el... |
fc2f1982cffc4dc08e0e30de7003cf0712778f690082f712a9cc39f60eb3ea39 | C/C++ | 5,631 | 142 | // This file is part of Eigen, a lightweight C++ template library
// for linear algebra.
//
// Copyright (C) 2009-2010 Gael Guennebaud <gael.guennebaud@inria.fr>
//
// This Source Code Form is subject to the terms of the Mozilla
// Public License v. 2.0. If a copy of the MPL was not distributed
// with this file, You c... |
f05e82343f8eaa572d83f1580555b2153bea4bb57188d031a2368055aa5c7133 | C/C++ | 5,654 | 185 | /* arm.c: */
void SetupFindArmMove(void);
int FindArmMove(int reg);
/* auto.c: */
void Set_AutoMode(void);
void Do_AutoMode(void);
/* calc.c: */
int FindIntercept(int reg1, int reg2, int time);
/* calib.c: */
void Init_CalibFile(char *inputfile);
void Read_CalibFile(int number);
void Do_Calibration(float *h, fl... |
ab428286d1e8ae1629a9f6c03217673591c5e793b7231ca2fbca825744899982 | C/C++ | 5,667 | 214 | /*
* 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.
*/
#pragma once
#include <algorithm>
#include <cassert>
#include <cmath>
#include <cstddef>
#include <c... |
02eeb5418b161405f978ed9ed2ee7f48718f6594523ac749bd8993eac7f403e0 | C/C++ | 5,684 | 126 | // 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.
#pragma once
#include <ATen/functorch/Macros.h>
#include <c10/core/DispatchKey.h>
#include <ATen/core/functi... |
7ce353177d15f3f7bedfcdd145f9d5032075db3e9b4dc09ff8149df99fb8365d | C/C++ | 5,704 | 144 | #pragma once
#include <c10/macros/Export.h>
#include <cstdint>
#include <functional> // For std::hash
#include <string>
namespace c10 {
// 'prim' symbols are synthetic operators that occur only in the IR
// and don't have corresponding implementations in ATen.
// 'onnx' symbols correspond to ONNX operators. Their... |
7486937672ac6ee86bdbe5b31ccaba0453b6250b6fcfe853dd1f9b91bec75b71 | C/C++ | 5,711 | 168 | // 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... |
8454a39dc7ee8f7230871f9cbe70cd898c421e5b04b2eabc2c3aeaa009cda467 | C/C++ | 5,720 | 137 | #include <ATen/core/Tensor.h>
#include <ATen/div_rtn.h>
#include <ATen/TensorUtils.h>
#include <ATen/native/DispatchStub.h>
#include <ATen/native/PoolingChecks.h>
#include <c10/util/TypeCast.h>
#include <c10/util/safe_numerics.h>
#include <c10/util/irange.h>
#include <utility>
#pragma once
namespace at::native {
us... |
345caf5a4f2f532c6df4fdceafa2500ce1fa9167d49288c669b1aa3dd5f1720b | C/C++ | 5,732 | 246 | /*============================================================================*/
/**
* @file PushPull.h
*
* @brief Push-Pull interpolation class
*
* @date 1 Aug 2012
* @authors Jasenko Zivanov\n
* jasenko.zivanov@unibas.ch\n
* University of Basel, Switzerl... |
89467ad645d0099f5a3b9468d342bade191cdf2c4446550ffae593e31164ad03 | C/C++ | 5,751 | 160 | // This file is part of Eigen, a lightweight C++ template library
// for linear algebra.
//
// Copyright (C) 2009 Benoit Jacob <jacob.benoit.1@gmail.com>
// Copyright (C) 2009 Gael Guennebaud <gael.guennebaud@inria.fr>
//
// This Source Code Form is subject to the terms of the Mozilla
// Public License v. 2.0. If a cop... |
782a565c77431869525e2503da1ec652b530e3ff15679e8347cd7347074069ba | C/C++ | 5,785 | 256 | /*
* assembly.h
*
* Created on: Apr 16, 2013
* Author: "Sjors H.W. Scheres"
*/
#ifndef ASSEMBLY_H_
#define ASSEMBLY_H_
#include <cstdlib>
#include <cstdio>
#include <string>
#include <iostream>
#include <fstream>
#include <vector>
#include <algorithm>
#include "src/args.h"
#include "src/matrix2d.h"
/*
* H... |
863acd4f30bad1af41e454dfaa04e8cf70490c531c492a0a5dcafb2bd2ac2dc5 | C/C++ | 5,788 | 191 | /***************************************************************************
*
* 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... |
c136d8cdf752d35300969973a2d57ea01643b06702f622cd271271ae394570b1 | C/C++ | 5,809 | 165 | /***************************************************************************
*
* 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... |
b42a9cca87a205bc44ca6785cb2d12100f6a3613d7c1e72f48862e761e5875f4 | C/C++ | 5,814 | 242 | #ifndef __LIBGRAVIS_TUPLE_H__
#define __LIBGRAVIS_TUPLE_H__
/******************************************************************************
** Title: Tuple.h
** Description: Tuple2 and Tuple3 (tuples of int)
**
** Author: Michael Keller, 2005
** Computer Science Department, University B... |
2eb036a02119c328568f05b8dfbd285439a4095dbbd12f0e1524d3d12fe084a3 | C/C++ | 5,823 | 170 | // This file is part of Eigen, a lightweight C++ template library
// for linear algebra.
//
// Copyright (C) 2009 Rohit Garg <rpg.314@gmail.com>
// Copyright (C) 2009-2010 Gael Guennebaud <gael.guennebaud@inria.fr>
//
// This Source Code Form is subject to the terms of the Mozilla
// Public License v. 2.0. If a copy of... |
edc7d137fb53a0043535ad77550d8acdbdae8cc1d40201ac6d27277cb54e1eab | C/C++ | 5,823 | 173 | #ifndef Py_FORTRANOBJECT_H
#define Py_FORTRANOBJECT_H
#ifdef __cplusplus
extern "C" {
#endif
#include <Python.h>
#ifndef NPY_NO_DEPRECATED_API
#define NPY_NO_DEPRECATED_API NPY_API_VERSION
#endif
#ifdef FORTRANOBJECT_C
#define NO_IMPORT_ARRAY
#endif
#define PY_ARRAY_UNIQUE_SYMBOL _npy_f2py_ARRAY_API
#include "numpy/a... |
c97e6625f41e4546d2dd4739865f7217b1335fe68b8f67d703a0e8de365ff771 | C/C++ | 5,837 | 233 | /***************************************************************************
*
* 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... |
8c14e9191aea775e8c5d622780ba73f04a0487628c5e2c9f1256fa3f88d6e95a | C/C++ | 5,852 | 256 | /*
* 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.
*/
#pragma once
#include <algorithm>
#include <cassert>
#include <cstddef>
#include <cstdlib>
#include ... |
bd0c0b2f317e61d0931651cb543206ca312909d813ce283adc6bc13cc69ab90c | C/C++ | 5,868 | 224 | /*
* 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.
*/
#pragma once
#include <algorithm>
#include <cassert>
#include <cstddef>
#include <cstdlib>
#include ... |
3ef56cd70bd1d81547e922c1f75b3731df24c9899913d02c0c1a5f46b663ae4d | C/C++ | 5,879 | 219 | #pragma once
#include <c10/core/CachingDeviceAllocator.h>
#include <c10/core/Device.h>
#include <c10/util/Exception.h>
#include <c10/core/Stream.h>
#include <c10/util/Registry.h>
#include <c10/core/Allocator.h>
#include <ATen/detail/AcceleratorHooksInterface.h>
#include <c10/util/python_stub.h>
#include <string>
n... |
2a901423887e05ba7c040ababb92cd8830009203735a5f0367bd961c5cea351d | C/C++ | 5,885 | 217 | /*
* 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.
*/
#pragma once
#include <algorithm>
#include <cassert>
#include <cmath>
#include <cstddef>
#include <c... |
5346d786fa639301a788d3d7bbfc7f03f22ded785e1c7616682906e089e7f6c0 | C/C++ | 5,893 | 251 | #ifndef DUAL_CONTRAST_VOXEL_H
#define DUAL_CONTRAST_VOXEL_H
#include <src/complex.h>
#include <src/jaz/gravis/t2Matrix.h>
template <typename T>
class DualContrastVoxel
{
public:
struct Solution
{
tComplex<T> phase, amplitude;
T conditionNumber;
};
DualContrastVoxel();
tComplex<T> data_sin, data_... |
2eab18998689c7052ff5136df4dde5d5451d6079ff003dee4ff1431e0c241907 | C/C++ | 5,901 | 160 | // This file is part of Eigen, a lightweight C++ template library
// for linear algebra.
//
// Copyright (C) 2014 Pedro Gonnet (pedro.gonnet@gmail.com)
//
// This Source Code Form is subject to the terms of the Mozilla
// Public License v. 2.0. If a copy of the MPL was not distributed
// with this file, You can obtain ... |
b8e00057d87d1e01394819c9ede53b1b506e761898280cbea757f74be7426ebc | C/C++ | 5,931 | 240 | /***************************************************************************
*
* 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... |
c86f37dd55f0bde7939848475bd832984903c81883d5e9aa23a565426db24fc7 | C/C++ | 5,941 | 163 | // This file is part of Eigen, a lightweight C++ template library
// for linear algebra.
//
// Copyright (C) 2008 Gael Guennebaud <gael.guennebaud@inria.fr>
// Copyright (C) 2006-2008 Benoit Jacob <jacob.benoit.1@gmail.com>
//
// This Source Code Form is subject to the terms of the Mozilla
// Public License v. 2.0. If ... |
d7518e7deaec9bceee6bcda02578a80454830d9cd9759bc5cbf3aafb78a384c0 | C/C++ | 5,955 | 159 | #undef __HIP_NO_HALF_CONVERSIONS__
#include <ATen/OpMathType.h>
#include <ATen/hip/HIPBlas.h>
#include <ATen/native/hip/ck_types.h>
#include <c10/util/Exception.h>
#include <ck/ck.hpp>
#include <ck/tensor_operation/gpu/device/tensor_layout.hpp>
#include <ck/tensor_operation/gpu/device/gemm_specialization.hpp>
#includ... |
cad8d33c0c664888f815d3a9306e3b90cb5c43c5b06a414bb40c5a76426dccea | C/C++ | 5,958 | 190 | #pragma once
#include <ATen/DimVector.h>
#include <ATen/EmptyTensor.h>
#include <ATen/Tensor.h>
#include <ATen/TensorGeometry.h>
#include <ATen/Utils.h>
#include <utility>
// These functions are NOT in Utils.h, because this file has a dep on Tensor.h
#define TORCH_CHECK_TENSOR_ALL(cond, ...) \
TORCH_CHECK((cond).... |
c4cc3e405b35b8e6f31c5757c97aca35ed863805dbc0c1c88274cfdf963ced60 | C/C++ | 5,960 | 187 | #pragma once
#include <c10/core/ConstantSymNodeImpl.h>
#include <c10/core/SymNodeImpl.h>
#include <c10/macros/Export.h>
#include <c10/util/Exception.h>
#include <c10/util/intrusive_ptr.h>
#include <cstdint>
#include <optional>
#include <string>
namespace c10 {
// The motivating usecase for this is to represent the r... |
02c78bf3230a940662398a2da539684135ed706a6def99edd075e73cdb024273 | C/C++ | 6,089 | 191 | //#include <signal.h>
//#ifdef _CUDA_ENABLED
//#include <cuda_runtime.h>
//#include "src/acc/cuda/cuda_kernels/cuda_device_utils.cuh"
//#elif _HIP_ENABLED
//#include <hip/hip_runtime.h>
//#include "src/acc/hip/hip_kernels/hip_device_utils.h"
//#endif
//#include "src/acc/settings.h"
//#include "src/acc/acc_backprojector... |
f1defbdc257362abe5c4530baf558bb58880d8d5522b411da12b466cf6de7c08 | C/C++ | 6,111 | 173 | #pragma once
#include <ATen/Config.h>
#include <c10/core/DeviceType.h>
#include <c10/core/ScalarType.h>
#include <c10/util/BFloat16.h>
#include <c10/util/Float8_e4m3fn.h>
#include <c10/util/Float8_e4m3fnuz.h>
#include <c10/util/Float8_e5m2.h>
#include <c10/util/Float8_e5m2fnuz.h>
#include <c10/util/Half.h>
// Defines ... |
630d1ccb4852351fa8b954575c1470e97b531048038f3555ac4ed5848b16fbba | C/C++ | 6,122 | 122 | #pragma once
#include <ATen/core/TensorBase.h>
#include <ATen/native/DispatchStub.h>
#include <c10/core/Scalar.h>
#include <c10/util/TypeSafeSignMath.h>
#include <ATen/native/TensorIterator.h>
namespace at {
struct TensorIterator;
struct TensorIteratorBase;
}
namespace at::native {
inline void alpha_check(const Sc... |
a6740b84c74dd5914399745723066ea8b11a734b66c3df5781402d628c8427a2 | C/C++ | 6,134 | 196 | // Copyright © 2022 Apple Inc.
#pragma once
#include <ATen/Context.h>
#include <ATen/mps/MPSEvent.h>
#include <ATen/mps/MPSStream.h>
#include <c10/core/impl/DeviceGuardImplInterface.h>
#include <c10/macros/Macros.h>
#include <c10/util/Exception.h>
#ifdef __OBJC__
#include <Foundation/Foundation.h>
#include <Metal/Me... |
57189f4013026992a4e83420507c4d5de842b113e0f6ef946467618fc44e465e | C/C++ | 6,136 | 218 | #pragma once
#include <ATen/BlasBackend.h>
#include <ATen/core/Tensor.h>
#include <array>
#include <functional>
#include <string>
#include <tuple>
#include <vector>
using at::blas::ScalingType;
using at::blas::SwizzleType;
namespace at::native::scaled {
/**
* Track concrete implementations available
*/
enum clas... |
d67cba7bd93bb17c82ac096be2c1e74b46a5c5803f752c414108300906fadb6c | C/C++ | 6,156 | 148 | #pragma once
#include <ATen/core/DimVector.h>
#include <ATen/core/Tensor.h>
#include <ATen/native/DispatchStub.h>
#include <c10/util/irange.h>
#include <array>
namespace at::native {
using padding_fn = void (*)(const Tensor&, const Tensor&, IntArrayRef);
// reflection padding
DECLARE_DISPATCH(padding_fn, reflectio... |
8307e48859e4e77d0b0ea78e49f5b18acc4177119300efb7ad3501c084bcab1c | C/C++ | 6,180 | 133 | // This file is part of Eigen, a lightweight C++ template library
// for linear algebra.
//
// Copyright (C) 2009 Gael Guennebaud <gael.guennebaud@inria.fr>
//
// This Source Code Form is subject to the terms of the Mozilla
// Public License v. 2.0. If a copy of the MPL was not distributed
// with this file, You can ob... |
1b0313876446468a9a7bfdfa8ead95209b8df57e7ea2129944bd6d1b48a9b05f | C/C++ | 6,181 | 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.
*/
#pragma once
#include <algorithm>
#include <cassert>
#include <cmath>
#include <cstddef>
#include <c... |
c42a68588a0cd0766d384bd89bc38b4cfa05f621cdc441289a1163e89206c766 | C/C++ | 6,200 | 203 | /***************************************************************************
*
* 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... |
18bf96273e8da6347f0d1737a17ca5525d132f1fe8d2b2113fadd1e35b076de2 | C/C++ | 6,206 | 203 | #pragma once
#include <ATen/core/List.h>
#include <ATen/core/Tensor.h>
namespace at {
class Tensor;
class OptionalTensorRef;
}
namespace c10::detail {
/*
* Specializations of `IListRefTagImplBase` that implement the default
* implementation for `IListRefTag::Unboxed`.
*/
template <typename T, typename ListElemT... |
53e1c2494904204d2fb13eef6d5d3fc8bf406390e2d1e73ef1fd81a55a743cf7 | C/C++ | 6,211 | 179 | #pragma once
#include <ATen/Config.h>
#include <ATen/Parallel.h>
#include <ATen/OpMathType.h>
#include <ATen/cpu/vec/functional.h>
#include <ATen/cpu/vec/vec.h>
#include <c10/util/complex.h>
// This header implements various unary operations using a MKL VML style
// interface.
// It implements various functions with... |
d5214d45a33362b5ebb1108dd65f87b1bccdbd77f4c817d9de7985e59c02e853 | C/C++ | 6,233 | 301 | #ifndef __LIBGRAVIS_T2MATRIX_H__
#define __LIBGRAVIS_T2MATRIX_H__
/******************************************************************************
** Title: t2Matrix.h
** Description: Represents a 2x2 matrix with column-major memory layout.
**
** Author: Jean-Sebastien Pierrard, 2005
** Brian... |
8b79f52b686a6911f89f84fc03f3aa41a5556a5555fa90fd581f4a1c3ee80849 | C/C++ | 6,243 | 191 | #ifndef SPIKE_DETECTOR_H
#define SPIKE_DETECTOR_H
#include "spike_event.h"
#include "fpga_constants.h"
#include "inkube_package.h"
#include "helper_functions.h"
#include <thread>
#include <atomic>
#include <string>
#include <vector>
#include <array>
#include <sys/types.h>
#include <sys/socket.h>
#include <sys/uio.h>
... |
df760f930c67d108ac09193e2cba551af7d0bd95c6b694196e53333d3b1153e7 | C/C++ | 6,258 | 194 | #include <cstdio>
#include <cstdlib>
#include <iostream>
#include <vector>
#include <algorithm>
#include <omp.h>
#include <src/image.h>
#include <tiffio.h>
class EERRenderer {
private:
// Constants
static const char EER_FOOTER_OK[];
static const char EER_FOOTER_ERR[];
static const int EER_4K, EER_2K;
static c... |
40ac87b7f5bfa8e33e5793f617a0326906f24b1307193b956716d1b0cc5997a7 | C/C++ | 6,262 | 127 | /***************************************************************************************************
* Copyright (c) 2017 - 2022 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
* SPDX-License-Identifier: BSD-3-Clause
*
* Redistribution and use in source and binary forms, with or without
* modification, are p... |
85e318811f094ecaa52847a1a1526a9e3bf607ec2820aa83addfc1d109363bcc | C/C++ | 6,272 | 213 | #ifndef SYCL_UTILITIES_H
#define SYCL_UTILITIES_H
#include <cstring>
#include <cmath>
#include <limits>
#include <cstdint>
#include <sycl/sycl.hpp>
#include "src/macros.h"
#include "src/acc/sycl/sycl_settings.h"
namespace syclKernels
{
template< typename T1, typename T2 >
static inline
int floorfracf(T1 a, T2 b)
{
... |
f70849ca56b09e1b743e27b502830b585667062b83f3e5d1e435d1b8e55d13f1 | C/C++ | 6,285 | 182 | // This file is part of Eigen, a lightweight C++ template library
// for linear algebra.
//
// Copyright (C) 2007 Julien Pommier
// Copyright (C) 2009 Gael Guennebaud <gael.guennebaud@inria.fr>
//
// This Source Code Form is subject to the terms of the Mozilla
// Public License v. 2.0. If a copy of the MPL was not dist... |
3d462b601b42d51516bd9aefdd1176ee1cd266420f07665f3fd1ecfbd4035481 | C/C++ | 6,287 | 262 | #ifndef __LIBGRAVIS_T_LAB_H__
#define __LIBGRAVIS_T_LAB_H__
/******************************************************************************
** Title: tLab.h
** Description: Represents an L*a*b* color tupel.
**
******************************************************************************/
#include <iostream>
... |
da818c3326da037a3c6e3073d77795832155623ef816c5a537c07c202313792c | C/C++ | 6,305 | 181 | #pragma once
// TODO: unify to C10_MOBILE. In theory this header could be used in OSS.
#ifdef TEMPLATE_SELECTIVE_BUILD
#include <ATen/selected_mobile_ops.h>
#endif
/**
* This header implements functionality to build PyTorch with only a certain
* set of operators (+ dependencies) included.
*
* - Build with -DTORCH... |
bddf663a7674b680a616add351dd3efb47b8c471955ce4cd6ba90e53be2f2428 | C/C++ | 6,369 | 218 | /* FILE deffs.h */
#include <stdio.h>
#include <math.h>
#include "anal.h"
/* clude "function.h" * All files see all public functions */
/* Included AFTER (struct) typedefs */
#define sizeof(x) ((int) sizeof(x))
/* defined as size_t?? - diff in intel vs AMD chip */
#define MAX_SPIKES 64000 /* for multiunit [R... |
bd6a0df8701fe9c811113c606a1bfcb08cd14fea915e0b73bd4ac9d2cdc4c45f | C/C++ | 6,383 | 187 | #pragma once
#include <cstdint>
#include <deque>
#include <mutex>
#include <utility>
#include <c10/util/Exception.h>
#include <c10/util/intrusive_ptr.h>
#include <c10/core/Device.h>
#include <c10/core/DispatchKeySet.h>
// For the record I don't think this is a correct pimpl idiom.
// Including Impl header in interfa... |
df42b36b1dd4799194e2c21d7a00f8d4d4ea1bf00d697b3985580b15b437c0e5 | C/C++ | 6,397 | 182 | // This file is part of Eigen, a lightweight C++ template library
// for linear algebra.
//
// Copyright (C) 2008 Gael Guennebaud <gael.guennebaud@inria.fr>
//
// This Source Code Form is subject to the terms of the Mozilla
// Public License v. 2.0. If a copy of the MPL was not distributed
// with this file, You can ob... |
22d4dda666363b6a7697a339236edb0c3e9b4ebd3758b43ab6f6073fed343ff5 | C/C++ | 6,417 | 240 | /*
* 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.
*/
#pragma once
#include <algorithm>
#include <cassert>
#include <cmath>
#include <cstddef>
#include <c... |
4d96878b8c0aeb601adb46ed96c77d31f537e519aed1ff2bfa08b92922f4839a | C/C++ | 6,422 | 186 | #pragma once
#include <ATen/ExpandUtils.h>
#include <ATen/native/CanUse32BitIndexMath.h>
#include <ATen/native/TensorIterator.h>
#include <ATen/core/IListRef.h>
#include <c10/util/irange.h>
#ifndef AT_PER_OPERATOR_HEADERS
#include <ATen/Functions.h>
#else
#include <ATen/ops/empty.h>
#include <ATen/ops/nonzero.h>
#endi... |
a6268e6f998fb282140b35c979d0e77130c86cbcf9ad39746f87600aa09ed222 | C/C++ | 6,424 | 230 | #pragma once
#include <algorithm>
#include <vector>
#include <ATen/div_rtn.h>
#include <ATen/core/Tensor.h>
#include <c10/util/irange.h>
#define TORCH_CHECK_DIM_SIZE(T, DIM, DIM_SIZE, SIZE) \
TORCH_CHECK( \
T.dim() == DIM && T.size(DIM_SIZE) == SIZE, \
"Need " #... |
30420a2cf694c1f21b3649748e6b99bfa5ec7a839c0a13d6bc3fe3a2490e935a | C/C++ | 6,430 | 209 | #ifndef CPU_UTILITIES_H
#define CPU_UTILITIES_H
#include <src/macros.h>
#include <math.h>
#include "src/acc/cpu/cpu_settings.h"
#include <cassert>
namespace CpuKernels
{
#define CHECK_INDEX_DEBUG_FATAL( err ) (HandleCheckIndexPtrDebugFatal( err, __FILE__, __LINE__ ))
static void HandleCheckIndexPtrDebugFatal( const... |
789668d5cf912cf186b275bc68bd69dc789fa74cd338f33335a7e4b4e2ec41e1 | C/C++ | 6,433 | 323 | /***************************************************************************
*
* 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... |
96d6a9931e49e57de10c9b42c7b37f514e3e6029c85e6b913297fa13b05b49a9 | C/C++ | 6,451 | 226 | #pragma once
#include <ATen/BlasBackend.h>
#include <ATen/native/mkldnn/xpu/detail/Attr.h>
#include <ATen/native/mkldnn/xpu/detail/Utils.h>
#include <ATen/native/mkldnn/xpu/detail/oneDNNContext.h>
namespace at::native::onednn {
TORCH_API sycl::event matmul(
at::Tensor& result,
const at::Tensor& mat1,
con... |
59304bd22c538e80ea1de40f07c7c5874c81bed3e5b4b7cbd918025b43a62186 | C/C++ | 6,472 | 187 | // 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... |
eadac37e9e49430f82d6a32121c349fb7cf80a9254a5c996da7997a9c6e91ab4 | C/C++ | 6,474 | 262 | #ifndef __LIBGRAVIS_T_YCB_CR_H__
#define __LIBGRAVIS_T_YCB_CR_H__
/******************************************************************************
** Title: tYCbCr.h
** Description: Represents an CIE Y/Cb/Cr color tupel.
**
******************************************************************************/
#include... |
b2b90987f4c0b5556750fba3eef26deb040a752937cafe84fa00e50f2f204785 | C/C++ | 6,500 | 190 | #pragma once
#include <ATen/Parallel.h>
#include <ATen/SparseTensorImpl.h>
#include <ATen/core/Tensor.h>
#ifndef AT_PER_OPERATOR_HEADERS
#include <ATen/Functions.h>
#else
#include <ATen/ops/empty.h>
#include <ATen/ops/tensor.h>
#endif
namespace at::sparse {
// Just for documentary purposes
using SparseTensor = Tens... |
51b8aa341c0fc6676ef27c29730bfd8acb7f1151ffeb3d6259dc02f84e26d657 | C/C++ | 6,509 | 179 | // Copyright 2008, Google Inc.
// All rights reserved.
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are
// met:
//
// * Redistributions of source code must retain the above copyright
// notice, this list of conditions ... |
504efc955015b6735e07f5e418b0f4f106a3fa65baefc34c9b2eed7fca8d287f | C/C++ | 6,510 | 194 | #pragma once
#include <c10/util/irange.h>
// define constants like M_PI and C keywords for MSVC
#ifdef _MSC_VER
#ifndef _USE_MATH_DEFINES
#define _USE_MATH_DEFINES
#endif
#include <math.h>
#endif
#include <array>
#include <cmath>
#include <cstdint>
namespace at {
constexpr int MERSENNE_STATE_N = 624;
constexpr int... |
7d92c4c8581f74aa1832735afadbd211ce3b9eda60d157abf4b8b98d830b2e86 | C/C++ | 6,510 | 230 | #ifndef RELION_JAZ_EULER_ANGLES_H
#define RELION_JAZ_EULER_ANGLES_H
#include <src/jaz/gravis/t4Matrix.h>
#include <src/euler.h>
#include <iostream>
class Euler
{
public:
inline static gravis::d4Matrix anglesToMatrix4(double phi, double theta, double chi);
inline static gravis::d3Matrix anglesToMatrix3(double ph... |
f52c12a92f276b4b77e2bcd8582412c1b81780f82818bca0222be1ed7f7fa0d8 | C/C++ | 6,525 | 186 | // This file is part of Eigen, a lightweight C++ template library
// for linear algebra.
//
// Copyright (C) 2017 Gael Guennebaud <gael.guennebaud@inria.fr>
//
// This Source Code Form is subject to the terms of the Mozilla
// Public License v. 2.0. If a copy of the MPL was not distributed
// with this file, You can ob... |
262341e718658dd199c07725abc3c44164f23c7229503a8245b1eb0a50dad4e2 | C/C++ | 6,543 | 212 | /************************************************************************************************
**
** Copyright (c) 1993-1997 Axon Instruments.
** All rights reserved.
**
*************************************************************************************************
** HEADER: AXODEFN.H
** PURPOSE: Co... |
b47b7f9ff0afc913daf445efbf661ef2790b2f048314d87cba0a0d0518d37e5d | C/C++ | 6,547 | 189 | /***************************************************************************
*
* 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... |
af3e69590e4911493119d7f993117c16ac5d0811c0d3528d5026da5af48b89e7 | C/C++ | 6,549 | 177 | // 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.
#pragma once
#include <bitset>
#include <ATen/ArrayRef.h>
#include <ATen/SmallVector.h>
#include <ATen/Ten... |
7ef7e36101824aa406082707ce06ecdb5bc5cff33da8b3259a19a5cfc34d543d | C/C++ | 6,559 | 148 |
#include <stdio.h>
//#include <math.h>
#include <cmath>
#include <stdlib.h>
#include <vector>
#include <iostream>
#include <string>
#include <tuple>
#include <algorithm>
#include <limits>
#include "./nifti2_io.h"
using namespace std;
// ============================================================================
// ... |
33e49851f01b570da1c480eb729fa961491d1fbae33d13317ffa1cdc28cb6d83 | C/C++ | 6,565 | 191 | /***************************************************************************
*
* 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... |
e7aaedf4e71dd0b55b976a8e0dba90a1631cfe247eb87560136da8ac0d5df3d1 | C/C++ | 6,569 | 170 | /*****************************************************************************
**
** machine.h
**
** Copyright (c) Cambridge Electronic Design Limited 1991,1992
**
** This file is included at the start of 'C' or 'C++' source file to define
** things needed to make Macintosh DOS and Windows sources more compatibl... |
d809b2124d2d3f27597fb7121b61bbbabe0183d0793d3fd9b947566541ed060b | C/C++ | 6,583 | 117 | /** \file nifti2.h
\brief Header structure for NIFTI-2 format.
*/
#ifndef __NIFTI2_HEADER
#define __NIFTI2_HEADER
/*---------------------------------------------------------------------------*/
/* Changes to the header from NIFTI-1 to NIFTI-2 are intended to allow for
larger and more accurate fields. The cha... |
53c6740a01b2bce82776c93c1c053a6a58eb682abbfd86574f96f975ab864ef9 | C/C++ | 6,617 | 186 | #ifndef PARTICLE_H
#define PARTICLE_H
#include <string>
#include <vector>
#include <src/macros.h>
#include <src/jaz/gravis/t4Matrix.h>
class DynamoParticle
{
public:
DynamoParticle();
DynamoParticle(std::string line);
int tag; // tag of particle file in data folder
int aligned; // value 1: marks t... |
69e060171893d7ec3d6788b8c54661754466e308da1bbe4a50c21652c00f0053 | C/C++ | 6,622 | 250 | #pragma once
// Complex number math operations that act as no-ops for other dtypes.
#include <c10/util/complex.h>
#include <c10/util/MathConstants.h>
#include<ATen/NumericUtils.h>
namespace at::native {
inline namespace CPU_CAPABILITY {
template <typename SCALAR_TYPE, typename VALUE_TYPE=SCALAR_TYPE>
inline VALUE_TY... |
47cece03cd6eb9a6fdb5c51a6a2d44d4bbe524576298a690b0addcf50ea415e9 | C/C++ | 6,626 | 212 | // Copyright © 2022 Apple Inc.
#pragma once
#include <cstdint>
#include <mutex>
#include <optional>
#include <string>
#include <utility>
#include <ATen/mps/MPSDevice.h>
#include <c10/core/DeviceGuard.h>
#include <c10/core/Stream.h>
#include <c10/util/Exception.h>
#ifdef __OBJC__
// Apple framework headers emit dep... |
008d3a7dc977963d1ee79022f2892d5e3174e4604f6bdb7cbfc9df5bca0860df | C/C++ | 6,635 | 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... |
2a11068de2f323c4e8529042e415663769a1e996ded2d2155dcc235894801ceb | C/C++ | 6,643 | 305 | #ifndef DETECTION_H
#define DETECTION_H
#include "raw_image.h"
#include "normalization.h"
#include "local_extrema.h"
#include <src/jaz/gravis/t3Vector.h>
#include <src/jaz/tomography/tomogram.h>
#include <src/jaz/tomography/projection/projection.h>
class Detection
{
public:
template <typename T>
static Buffer... |
6b2de8906a77d4f7a1ca494f2908519888c7f2d2565349ebeb606137d8836848 | C/C++ | 6,683 | 329 | // imgui_ini_embed.h
#pragma once
const char* embedded_imgui_ini = R"(
[Window][Debug##Default]
Pos=470,87
Size=400,400
Collapsed=1
[Window][Dear ImGui Demo]
Pos=415,81
Size=602,559
Collapsed=1
[Window][Hello, world!]
Pos=0,19
Size=695,177
Collapsed=0
[Window][Example: Documents]
ViewportPos=77,482
ViewportId=0x1F... |
74ec890d1e16dcb0b2b6cee1de591d9527d0a1efc08c921b189be6c68b5754b2 | C/C++ | 6,703 | 193 | #ifndef _psplot_defines_
#define _psplot_defines_ 1
#include <stdarg.h>
#include <stdio.h>
int deviceID (va_list *args);
int openplID (void);
int closeplID (void);
int flushplID (void);
int spaceID (int x0, int y0, int x1, int y1);
int colorID (int red, int green, int ... |
547e6b34a01354124594822816242fe2b044d4b6326a54de25b4b38295c94b6a | C/C++ | 6,717 | 188 | // This file is part of Eigen, a lightweight C++ template library
// for linear algebra.
//
// Copyright (C) 2008 Gael Guennebaud <gael.guennebaud@inria.fr>
//
// This Source Code Form is subject to the terms of the Mozilla
// Public License v. 2.0. If a copy of the MPL was not distributed
// with this file, You can ob... |
478e9cb0761668685e361723de2af172f66fd917d360cc1569e4d3fa1429ff4f | C/C++ | 6,733 | 263 | #include <utility>
#pragma once
namespace at::native {
namespace {
// operator_brackets_proxy is used in
// CompositeRandomAccessor in place of operator[].
// For some iterators, references returned by operator[]
// could become invalid, operator_brackets_proxy tries to
// resolve that by making accessor[n] to be e... |
93016b8ef99244c3dab7fbf6df62135188459ea752658df78626d81d5533d826 | C/C++ | 6,738 | 157 | #pragma once
/**
* This file contains functionality to take a C++ function and infer its
* c10::FunctionSchema.
*/
#include <ATen/core/function_schema.h>
#include <c10/util/Metaprogramming.h>
namespace c10 {
namespace detail::infer_schema {
/// The templated inference code creates `ArgumentDef` instead of `Argum... |
f268983e8db798b7db7e1f71b0d1e7dbc039fc5cf7074091cae7a40c1a9df122 | C/C++ | 6,755 | 226 | // This file is part of Eigen, a lightweight C++ template library
// for linear algebra.
//
// Copyright (C) 2011-2014 Gael Guennebaud <gael.guennebaud@inria.fr>
//
// This Source Code Form is subject to the terms of the Mozilla
// Public License v. 2.0. If a copy of the MPL was not distributed
// with this file, You c... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.