sha256 stringlengths 64 64 | language stringclasses 27
values | size int32 1 491k | lines int32 1 21.8k | content stringlengths 1 200k |
|---|---|---|---|---|
edeeb9512e74d79dc8987b6b8a442d395c4ec6b267c55b5ecd672bb1bf5ba8cd | C/C++ | 6,775 | 209 | // 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... |
d6326bb1d4343700c29d15443379b5d71dc2983227190c7551c041efdcf9692f | C/C++ | 6,797 | 188 | // This file is part of Eigen, a lightweight C++ template library
// for linear algebra.
//
// Copyright (C) 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 can ob... |
1dae2d0cc22af39370ea9cc9ad5b1cb81a588c8b03f9ed44a04c5cac932b0693 | C/C++ | 6,803 | 321 | #ifndef __LIBGRAVIS_T2VECTOR_H__
#define __LIBGRAVIS_T2VECTOR_H__
/******************************************************************************
** Title: t2Vector.h
** Description: Represents a two dimensional vector.
**
** Author: Pascal Paysan, 2005
** Computer Science Department, Univer... |
c62afe3b02f1d2d6d4493d17790ae35e8046e692fca18ce1fa213a9bfcb31501 | C/C++ | 6,815 | 206 | #pragma once
#include <c10/core/MemoryFormat.h>
#include <c10/core/SymIntArrayRef.h>
#include <c10/core/TensorImpl.h>
#include <c10/util/Exception.h>
namespace at {
// An "Opaque" TensorImpl -- there are no strides and (for now)
// even data() is not supported (thus no pointer arithmetic).
// NOTE: We could allow d... |
adbb8d572ae7bea53e491622733e617cf8a08a4476b00604ec54f5525c8f6cd2 | C/C++ | 6,831 | 175 | #include <ATen/NumericUtils.h>
#include <c10/macros/Macros.h>
#include <c10/util/Half.h>
#include <c10/util/BFloat16.h>
#include <c10/util/MathConstants.h>
#include <cmath>
#include <cstdint>
#include <cassert>
#include <limits>
#include <type_traits>
namespace at {
// Using DistAccumType in accumulate types for dist... |
70f3204806cdab9411f33c0a60f6bd98ac5197fd713d0940b14822f93e317ba4 | C/C++ | 6,835 | 301 | #pragma once
namespace at::native {
// (Const)StridedRandomAccessor is a
// (const) random access iterator defined over
// a strided array.
// The traits below are to introduce __restrict__
// modifier on different platforms.
template <typename T>
struct DefaultPtrTraits {
using PtrType = T*;
};
#if (defined(_WI... |
ddc188f6752d2b7c04f443a476461d507f041ab6a2a141aa459a8cfa10ce3170 | C/C++ | 6,908 | 211 | #pragma once
#include <array>
#include <cstring>
#include <utility>
#include <ATen/Parallel.h>
#include <ATen/OpMathType.h>
#include <ATen/cpu/vec/vec.h>
#include <ATen/native/cpu/utils.h>
#include <c10/util/irange.h>
namespace at::native {
inline namespace CPU_CAPABILITY {
template<typename T> using opmath_t = at:... |
9585e969347d7618a0045b52c025cc7373e715948304306c05a96e5a03f300cd | C/C++ | 6,941 | 244 | #pragma once
#include <c10/util/Exception.h>
#include <c10/util/irange.h>
#include <sstream>
#include <string>
#include <unordered_map>
#include <vector>
namespace at::jit {
// A template environment is a mapping from template variable names, e.g.,
// identifier (corresponding to $identifier) to their expansions.
/... |
6f757f0235c2e0df7aa06bca64d0d05a5b2826c1c5cc74f90298d468df50b444 | C/C++ | 6,968 | 167 | // Copyright 2005, 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 ... |
e4cdb56491dba623c9257f78144cda6fe6d2ee0ae3c04c77db7479987d501845 | C/C++ | 6,972 | 222 | /***************************************************************************
*
* 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... |
e376b5f6de76cae6b8c9410143e987d30c3d7cdb6fcc6603eaba82ef6acfcbaf | C/C++ | 7,008 | 205 | #pragma once
#include <ATen/Context.h>
#include <ATen/core/Generator.h>
#include <ATen/core/TensorBase.h>
#include <ATen/cuda/PhiloxCudaState.h>
#include <c10/core/Allocator.h>
#include <c10/util/flat_hash_map.h>
#include <atomic>
#include <memory>
#include <mutex>
namespace at {
namespace cuda {
struct CUDAGraph;
}... |
f4edf9608c9439c47bbe0c0693fb1a1e4ee4969af8045154c783babcb6e8a95f | C/C++ | 7,028 | 282 | #ifndef POLISH_PROGRAM_H
#define POLISH_PROGRAM_H
#include <string>
#include <src/jaz/math/t_complex.h>
#include <src/jaz/image/buffered_image.h>
#include <src/jaz/gravis/t4Matrix.h>
#include <src/jaz/tomography/motion/motion_fit.h>
#include <src/jaz/tomography/motion/modular_alignment/modular_alignment.h>
#include <s... |
8d0a21e55231790613deb93366daf2170909ad26c2abcd031ebadafb4c536ae7 | C/C++ | 7,034 | 282 | #ifndef JAZ_MOVIE_LOADER_H
#define JAZ_MOVIE_LOADER_H
#include <src/image.h>
#include <src/jaz/image/buffered_image.h>
#include <src/renderEER.h>
#include <string>
class MovieLoader
{
public:
template <typename T>
static BufferedImage<T> readDense(
std::string movieFn,
const RawImage<RFLOAT>* gainRef,
... |
9f297481241d67f2f4df4d69c168c44f1d911ba0ea26fe35580cc19a2bf7cd89 | C/C++ | 7,040 | 164 | /* FILE Functions.h */
/* Public function declarations FOR MACROS */
/* align.c */ int Get_AlignTime();
/* anova.c */ double *anova(double **rankdata, int rows, int cols);
/* arm.c */ int Get_Arm_Move_Time(int time, int InitialAlignment);
/* arm.c */ int Get_Arm_Stop_Time(int time, int InitialAlignment);
/... |
490ac278fe8263f170d507d990f933712cb3e90112e6f1ea2c40575a8fa380d2 | C/C++ | 7,050 | 169 | // This file is part of Eigen, a lightweight C++ template library
// for linear algebra.
//
// Copyright (C) 2008-2015 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... |
bc0a5bcbc9578087788c48cc1e79ecc8bce35223fc55274194885b39055b3b81 | C/C++ | 7,055 | 285 | /***************************************************************************
*
* 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... |
78a69de8b14294d656ed3951bf537b3c74a2e8b635ee7c8c0c6b67548bcc26f3 | C/C++ | 7,063 | 268 | // Windows macros to compile on Unix machines.
// Taken from MSDOS.H and from various wine headers.
// Only the absolute minimum has been integrated.
// 2007, CSH, University of Freiburg
// Error return from SetFilePointer()
#ifndef INVALID_SEEK_VALUE
#define INVALID_SEEK_VALUE (0xFFFFFFFF)
#endif
#define ... |
5d47067c6289432f98228ffda3b510540e40b4817422646be30b45b67215e21c | C/C++ | 7,064 | 263 | /***************************************************************************
*
* 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... |
3d2234ec31c047102b40fdf63670e045e355879f7c901ec891e2d4a66b8ce1d4 | C/C++ | 7,101 | 233 | #pragma once
#include <tuple>
#include <type_traits>
#include <utility>
#include <ATen/core/ivalue.h>
#include <c10/util/Deprecated.h>
#include <c10/util/irange.h>
// TODO move this to c10 namespace
namespace torch::jit {
using c10::IValue;
using Stack = std::vector<IValue>;
class Operation {
template <typenam... |
0b81484567eda45b086f8ea2a6531319bf86d6b3862c1c6ebb0cc635cfa95204 | C/C++ | 7,107 | 253 | /*
* 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 <cmath>
#include <cstddef>
#include <cstdlib>
#include <f... |
b8b981cf43788a9825883f717abe66e5e428fafa68ef4c6c7a7ce04bebcca2b0 | C/C++ | 7,109 | 225 | /*============================================================================*/
/**
* @file ClearTextIO.h
*
* @brief Gravis Arrays with >> and << reader and writer
*
* @date 06/30/2011 02:18:07 PM
* @authors Sandro Schoenborn (ses)\n
* sandro.schoenborn@unibas.ch\n
* ... |
6f3cb4b59c43a725a1e8b47ca9c2bfb467ae0559b4f641b5bf3eedef4abe5d6b | C/C++ | 7,136 | 197 | #ifndef __SCIPY_SPECIAL_CEPHES
#define __SCIPY_SPECIAL_CEPHES
/* Complex numeral. */
typedef struct {
double r;
double i;
} cmplx;
extern double acosh(double x);
extern int airy(double x, double *ai, double *aip, double *bi,
double *bip);
extern double asin(double x);
extern double acos(double x);
extern d... |
42643d96ff07cb70c4bab34605b639a05d520bef3fa704bfd0f4e74d484d55ba | C/C++ | 7,146 | 252 | #pragma once
#include <ATen/jit_macros.h>
#if AT_USE_JITERATOR()
#include <ATen/native/TensorIterator.h>
#include <ATen/cuda/detail/OffsetCalculator.cuh>
#include <ATen/native/cuda/jit_utils.h>
#include <ATen/native/cuda/MemoryAccess.cuh>
#include <ATen/native/cuda/JitLoops.cuh>
#include <array>
#include <string>
#i... |
0bd10dc9d4d51245c089dd12059f4dde29748b3373556146f84f69a65c965f19 | C/C++ | 7,147 | 281 | /*
* 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 <cmath>
#include <cstddef>
#include <cstdlib>
#include <f... |
3af465adee1e6fd2815adea0004e5c4382be3f6b91988294d6b00ac561728260 | C/C++ | 7,161 | 178 | #ifndef NUMPY_CORE_INCLUDE_NUMPY_NPY_NUMPYCONFIG_H_
#define NUMPY_CORE_INCLUDE_NUMPY_NPY_NUMPYCONFIG_H_
#include "_numpyconfig.h"
/*
* On Mac OS X, because there is only one configuration stage for all the archs
* in universal builds, any macro which depends on the arch needs to be
* hardcoded.
*
* Note that dis... |
817056d7edf80f8ba54a3cdbece84d6ccd02f44b024b62494d6c6489cf00b35a | C/C++ | 7,167 | 207 | #pragma once
#include <ATen/Tensor.h>
#include <c10/core/TensorImpl.h>
#include <c10/core/impl/TorchDispatchModeTLS.h>
#include <c10/util/Exception.h>
namespace at {
// Struct implementing a sparse CSR tensor. It uses three 1-D tensors for
// denoting the data: `crow_indices_`, `col_indices_` and `values_`.
// The `c... |
cf74af2fc8465f1886916c75ac27a39fb350b66d11b6caccd42980e1c5ef2a14 | C/C++ | 7,211 | 220 | // This file is part of Eigen, a lightweight C++ template library
// for linear algebra.
//
// Copyright (C) 2008-2009 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... |
a96e4eecba94e2b9e7cfac9c8e7bf1a5bfd40eb8d523c8313aec05e4f2d12fc9 | C/C++ | 7,224 | 323 | #ifndef ACC_PROJECTORKERNELIMPL_H_
#define ACC_PROJECTORKERNELIMPL_H_
#ifndef PROJECTOR_NO_TEXTURES
#ifdef _CUDA_ENABLED
#define PROJECTOR_PTR_TYPE cudaTextureObject_t
#elif _HIP_ENABLED
#define PROJECTOR_PTR_TYPE hipTextureObject_t
#endif
#else
#define PROJECTOR_PTR_TYPE XFLOAT *
#endif
class AccProjectorKe... |
502d884c07e99db0258014616445fc2fe52f68742fe69c2dcf58ba86a7f01a8d | C/C++ | 7,227 | 171 | // This file is part of Eigen, a lightweight C++ template library
// for linear algebra.
//
// Copyright (C) 2007-2010 Benoit Jacob <jacob.benoit.1@gmail.com>
// 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 ... |
1af29e7ebfaaf5e3ce1e1fb24edbf2ac629e7abe03ea7a00b879868ae1ed83c5 | C/C++ | 7,262 | 229 | // This file is part of Eigen, a lightweight C++ template library
// for linear algebra.
//
// Mehdi Goli Codeplay Software Ltd.
// Ralph Potter Codeplay Software Ltd.
// Luke Iwanski Codeplay Software Ltd.
// Contact: <eigen@codeplay.com>
//
// This Source Code Form is subject to the terms of the Mozilla
// Publi... |
194929b0026088028ae3e70d7d9263447609d70b455afd71db46462b303998cb | C/C++ | 7,274 | 254 | #pragma once
#include <string>
#include <c10/util/irange.h>
#include <ATen/jit_macros.h>
#include <ATen/cuda/detail/LazyNVRTC.h>
namespace at::cuda::jit {
enum class BinaryFuncVariant {NoScalar, RhsScalar, LhsScalar};
struct NvrtcFunction {
CUmodule module = CUmodule();
CUfunction function = nullptr;
};
struc... |
9660b62ee0598cef9ea390e0f678b706ad1036b456305575a48c131e46983301 | C/C++ | 7,280 | 240 | #pragma once
#include <ATen/core/Tensor.h>
#include <ATen/TensorUtils.h>
#include <ATen/div_rtn.h>
#include <c10/util/safe_numerics.h>
namespace at::native {
// Number of sliding-window positions along one spatial dimension (floor division, int64_t).
inline int64_t sliding_window_count(
int64_t input_size,
in... |
fbe56d9cca7349827b9380e539b777142e4a40cfc3606546416904803b636059 | C/C++ | 7,307 | 213 | // 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... |
cfa4ec76235b16f018bc3e965b525042692f031f6c730a8e58b29e063e74543a | C/C++ | 7,309 | 224 | /*
* This file is part of Healpix_cxx.
*
* Healpix_cxx 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.
*
* Healpix_cxx is... |
e92d480ff303a0c8578522e51e1e6a365ea803fa46edf0fff3868396993ea2a6 | C/C++ | 7,318 | 157 | #include <ATen/core/Tensor.h>
#include <ATen/core/dispatch/Dispatcher.h>
#include <ATen/core/op_registration/op_registration.h>
#include <ATen/native/UnaryOps.h>
#include <ATen/native/Resize.h>
#include <c10/util/irange.h>
#include <torch/library.h>
#ifndef AT_PER_OPERATOR_HEADERS
#include <ATen/Functions.h>
#else
#in... |
ca5dcd03e5ee23c90fd52d0853785df2e7d27b4ff6fe00847c8498eb423ab984 | C/C++ | 7,333 | 191 | // This file is part of Eigen, a lightweight C++ template library
// for linear algebra.
//
// Copyright (C) 2008-2011 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... |
026a62b93cb45d82354dbc83f432aed2cb09818c46170204095fe7bd13710a6f | C/C++ | 7,362 | 242 | #pragma once
#include <c10/hip/HIPCachingAllocator.h>
// Use of c10::hip namespace here makes hipification easier, because
// I don't have to also fix namespaces. Sorry!
namespace c10::hip {
// NB: THIS SHOULD NOT BE USED
// I couldn't find anywhere it was used in public pytorch sources or downstream projects.
// B... |
1bdced07f0c35b5af18ea54f283fd5dff0ae175fa2f93cef6ab4614a06fdb2b5 | C/C++ | 7,381 | 316 | /* Portions of this code are under:
Copyright (c) 2022 Advanced Micro Devices, Inc. All rights reserved.
*/
#ifndef HIP_DEVICE_UTILS_H_
#define HIP_DEVICE_UTILS_H_
#include <hip/hip_runtime.h>
#include "src/acc/hip/hip_settings.h"
#ifdef ACC_DOUBLE_PRECISION
__device__ inline double hip_atomic_add(double* address,... |
488d74f0a1e5d749b0c6f4aa26a32e452405021e06fac7896e010e9f7dd6782b | C/C++ | 7,400 | 288 | /***************************************************************************
*
* 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... |
ba379091cf64635f32afa5cfc3d78422b3b9f02dee43579728da8713d617d88e | C/C++ | 7,417 | 219 | #pragma once
#include <ATen/Parallel.h>
#include <ATen/core/TensorAccessor.h>
#include <ATen/cpu/vec/vec.h>
#include <bit>
#ifdef USE_FBGEMM
C10_DIAGNOSTIC_PUSH_AND_IGNORED_IF_DEFINED("-Wextra-semi")
#include <fbgemm/Fbgemm.h>
C10_DIAGNOSTIC_POP()
#endif
namespace at::native {
template <typename T>
inline void _sto... |
bb8a2210e725b4db640c9e3b432d4e07ee454d64ca0503ccf77f34e6df4f1521 | C/C++ | 7,457 | 215 | // This file is part of Eigen, a lightweight C++ template library
// for linear algebra.
//
// Copyright (C) 2006-2008 Benoit Jacob <jacob.benoit.1@gmail.com>
// Copyright (C) 2009 Ricard Marxer <email@ricardmarxer.com>
// Copyright (C) 2009-2010 Gael Guennebaud <gael.guennebaud@inria.fr>
//
// This Source Code Form is... |
c45d5bcb6e10d4e8bba181754071dcc71dfd3c954e20abcacf270073d5d62b2c | C/C++ | 7,462 | 208 | #pragma once
#include <ATen/core/ivalue.h>
#include <c10/util/hash.h>
namespace c10 {
namespace detail {
inline bool DictKeyEqualTo::operator()(const IValue& lhs, const IValue& rhs) const {
if (lhs.isTensor() && rhs.isTensor()) {
// for tensors, we compare only by identity (following how it's done in Python).
... |
ec20f271ebbf56f07f6e9dd798ca7fc08156341018fb870bad93c5ee6a00f126 | C/C++ | 7,472 | 220 | /*************************************************************************//*!
* Title: tImage/draw.h
* Description: Implements drawing operations on images without the need
* for the libRender library.
*
* Author: Brian Amberg, 2006-2007
* Computer Science Department, Universi... |
29e9655d48e83a1084ef2f6d1d1b319ad757eb4490b1e9f38ba9abc193f6560a | C/C++ | 7,490 | 200 | //********************************************************************************************************************
// TimeBuf.h
//********************************************************************************************************************
#ifndef _Time_TIME
#define _Time_TIME
//#pragma pack(push, before_ti... |
3657d72f4da5682f87a3a89d430dfda14eb60ad6d19d0a2e40ed2797e9a56f6a | C/C++ | 7,521 | 239 | /***************************************************************************
*
* 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... |
1c81f167991e43d0f0d4a02b22a633015cd67b758a69851e8592461a9f446431 | C/C++ | 7,634 | 355 | #ifndef __LIBGRAVIS_T_RGB_A_H__
#define __LIBGRAVIS_T_RGB_A_H__
/******************************************************************************
** Title: tRGB_A.h
** Description: Represents an RGB+Alpha color tupel.
**
** Author: Jean-Sebastien Pierrard, 2005
** Computer Science Department, ... |
2cb602372b2ee52c6a46f2cfab776e45e5b368d6d24afe62dbf00c7beb22008e | C/C++ | 7,636 | 150 | /*
* 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 <stddef.h>
#include <stdint.h>
#include <qnnpack/common.h>
#include <qnnpack/... |
96af5531ac3c69cf19d66022d3c510b26b7e0492f8238e9adeff3ae1b16b7a4c | C/C++ | 7,638 | 172 | /******************************************************************************/
/* For all support and information please contact: */
/* */
/* Sigurd Enghoff ... |
c45d2260abf68312642093344f2940a5b30608ce59bb42c861083fc7df1bca26 | C/C++ | 7,689 | 200 | //********************************************************************************************************************
// TimeBuf.h
//********************************************************************************************************************
#ifndef _Time_TIME
#define _Time_TIME
//#pragma pack(push, bef... |
b76ad11eefe0c9d6f41f1def7ebb093fdb4dadb68efacbc37b5f121ec43ea88f | C/C++ | 7,707 | 284 | /***************************************************************************
*
* 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... |
e01c25e9f86215fc002a7f7afc929890cc6d63446cacdf54eb68f7d55e969ce2 | C/C++ | 7,730 | 240 | #pragma once
// define constants like M_PI and C keywords for MSVC
#ifdef _MSC_VER
#define _USE_MATH_DEFINES
#include <math.h>
#endif
#ifdef __CUDACC__
#include <cuda.h>
#endif
#include <array>
#include <c10/macros/Macros.h>
#include <cmath>
#include <cstdint>
namespace at {
// typedefs for holding vector data
na... |
c2f4a2a6da618bc2efa531fcae52b544839faea65b0cec693d8e00e1a05d4d5d | C/C++ | 7,774 | 213 | /***************************************************************************
*
* 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... |
9a1ea97ca2a7a2b370be4a2f9b04fbc927a4027c15785b085e6b279d08908dcf | C/C++ | 7,777 | 221 | /***************************************************************************
*
* 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... |
2f20e91d6d1cd08b8529f6aa335e40ca1473c58e917759dc0188323278b7d4f2 | C/C++ | 7,780 | 250 | #pragma once
#include <ATen/Tensor.h>
#include <ATen/cuda/CUDAContext.h>
#include <ATen/cuda/CUDASparse.h>
#include <c10/core/ScalarType.h>
#if defined(USE_ROCM)
#include <type_traits>
#endif
namespace at::cuda::sparse {
template <typename T, cusparseStatus_t (*destructor)(T*)>
struct CuSparseDescriptorDeleter {
... |
359f03a085e66dc3d9d713f26d181f9ee9a0897cf58dda6bc2bf6658412cd792 | C/C++ | 7,782 | 284 | /***************************************************************************
*
* 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... |
ee50c7c708f0ac194bc93f698e67392e26764bf076e4b3791509011143fae791 | C/C++ | 7,782 | 173 | #pragma once
#include <ATen/core/Tensor.h>
#include <ATen/native/TypeProperties.h>
#include <ATen/ScalarOps.h>
#ifndef AT_PER_OPERATOR_HEADERS
#include <ATen/NativeFunctions.h>
#else
#include <ATen/ops/result_type.h>
#endif
namespace at::native {
// original values given by raw_*. If an original value is not contig... |
61cd251c548204b07d5213c318c57f32dbfc4bdc5a333026133418ceb7a40c04 | C/C++ | 7,785 | 211 | // 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... |
1f6dfb1b5c67e7ec7bdb373b57ae287e168005f7bb57f1b0e59d4a6e936d46a3 | C/C++ | 7,800 | 216 | /*===================================================================
Program: ASHS (Automatic Segmentation of Hippocampal Subfields)
Module: $Id$
Language: C++ program
Copyright (c) 2012 Paul A. Yushkevich, University of Pennsylvania
This file is part of ASHS
ASHS is free software: you can redis... |
73428b4df6bf3c56a0c1a75ebf6dac342152ca13558aea05af43952266818a28 | C/C++ | 7,814 | 183 | #pragma once
#include <ATen/LegacyBatchedTensorImpl.h>
#include <ATen/core/IListRef.h>
namespace at {
// This file contains abstractions used for transforming *logical* vmap
// arguments into *physical* arguments. (Keep reading for definitions of these
// terms).
// NOTE: [Logical vs physical args]
// Consider the ... |
af18afdb91ae7ff5cc2809bc82e9a868b129cd614b841addd4cd2d0d1a1ea0f2 | C/C++ | 7,880 | 218 | // Created 1/8/01 Steve Franks
// This file 'works' with no modification under MS Visual C++ 6.0
// avoid duplicate definitions
#ifndef _NLX_DATATYPE_H
#define _NLX_DATATYPE_H
//in GCC, byte packing is done with the __packed__attribute and not with the construct below
//This forces all records to be byte-packed for... |
b66ad00a59c7787248dd19d763c5e41d09e9e1d57508e9dbfb0ade0b37e1c9ca | C/C++ | 7,885 | 208 | #pragma once
#include <ATen/core/boxing/OperatorKernel.h>
#include <c10/core/DispatchKeySet.h>
#include <c10/util/intrusive_ptr.h>
namespace c10 {
struct IValue;
using Stack = std::vector<IValue>;
class OperatorHandle;
class KernelFunction;
// This kernel implements the behavior of falling through to the next avai... |
7e1566654b01725b39614a7ddb6f9951e09b3ba3e46245022e9bbd2299de4e27 | C/C++ | 7,887 | 257 | #pragma once
#include <ATen/Config.h>
#if AT_MKLDNN_ACL_ENABLED()
#include <ATen/native/quantized/cpu/OnednnUtils.h>
#include <arm_compute/core/Error.h>
#include <arm_compute/core/TensorInfo.h>
#include <arm_compute/function_info/ActivationLayerInfo.h>
#include <arm_compute/runtime/NEON/functions/NEActivationLayer.h>... |
0d774b636c4ee6da20dfa99bb633ad37ccb4654668846326c1742aaedc54948b | C/C++ | 7,893 | 359 | #ifndef __LIBGRAVIS_T_RGBA_H__
#define __LIBGRAVIS_T_RGBA_H__
/******************************************************************************
** Title: tRGBA.h
** Description: Represents an RGB+Alpha color tupel.
**
** Author: Jean-Sebastien Pierrard, 2005
** Brian Amberg, 2005-2006
** ... |
c92dcf91a7722c23f63702f16edc8e1cb535efae66e95070631f1fe0c845818f | C/C++ | 7,925 | 189 | #pragma once
#include <ATen/core/Tensor.h>
namespace at::native {
using at::blas::ScalingType;
using at::blas::SwizzleType;
namespace {
// TODO: https://github.com/pytorch/pytorch/pull/59380#pullrequestreview-725310492
c10::MaybeOwned<Tensor> inline resolve_conj_if_indicated(const Tensor& tensor, bool resolve_conj... |
eda6a1b30aa5d5d9ec9431233dd97859675ca38dbc6f343c6ced12fdf6994089 | C/C++ | 7,942 | 189 | // This file is part of Eigen, a lightweight C++ template library
// for linear algebra.
//
// Copyright (C) 2008-2014 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... |
a68dce6d2e5329fdc7f3534531692516d08dd7c3e370b28a46a83b9f139b1cc8 | C/C++ | 7,984 | 207 | #pragma once
#include <ATen/miopen/Exceptions.h>
#include <ATen/miopen/miopen-wrapper.h>
#include <ATen/core/Tensor.h>
#include <ATen/TensorUtils.h>
#include <c10/macros/Export.h>
namespace at { namespace native {
std::string miopenTypeToString(miopenDataType_t dtype);
inline int dataSize(miopenDataType_t dataType... |
29825d0b6e437f6f699abb0a16a88061626ce288c3b904fcfe86ae08fa4fe39b | C/C++ | 8,020 | 227 | /*
* Copyright (C) 1996-2001,2003,2004,2006-2010,2014,2018,2025,2026 Bernd Feige
* This file is part of avg_q and released under the GPL v3 (see avg_q/COPYING).
*/
/*{{{}}}*/
/*{{{ Description*/
/*
* transform.h defines the method structures used for the data analysis
* package. The method mechanism follows Thoma... |
33ff1916c3d4cd26e46a6d9f85c0883b973e6eea7cd5afdc1c95b38bcb9015fb | C/C++ | 8,040 | 189 | // This file is part of Eigen, a lightweight C++ template library
// for linear algebra.
//
// Copyright (C) 2008-2016 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... |
22b0c931d713075acffec38f0779dd123c310af1b0125e81135253e292a6d4bf | C/C++ | 8,053 | 208 | /***************************************************************************
*
* 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... |
45ff96c406999d7bd38206409af54728924e307a801cd6134b640e7f322e6b13 | C/C++ | 8,054 | 305 | /***************************************************************************
*
* 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... |
f34f340d6bfaf21d70c26e0ba119ca6d5e7b6518bebac1e1ca0b5ec3d2c1b3c9 | C/C++ | 8,067 | 226 | #pragma once
/*
Provides a subset of MKL Sparse BLAS functions as templates:
mv<scalar_t>(operation, alpha, A, descr, x, beta, y)
where scalar_t is double, float, c10::complex<double> or c10::complex<float>.
The functions are available in at::mkl::sparse namespace.
*/
#include <c10/util/Exception.h>
#incl... |
38bae5645489520889f592b16e8490c01168145217a6745145acb59d2ea48ddb | C/C++ | 8,090 | 407 | #ifndef JAZ_VECTOR_IMAGE_H
#define JAZ_VECTOR_IMAGE_H
#include "raw_image.h"
template <typename T>
class BufferedImage : public RawImage<T>
{
public:
template <typename T2>
static BufferedImage<T> convert(const BufferedImage<T2>& img);
BufferedImage();
BufferedImage(size_t xdim, size_t ydim = 1, size_... |
c5aae1d50960b9f7cf52cd67f9fa4f7cd18901f140f58dd66a0790c49bbfab92 | C/C++ | 8,098 | 218 | // Created 1/8/01 Steve Franks
// This file 'works' with no modification under MS Visual C++ 6.0
// avoid duplicate definitions
#ifndef _NLX_DATATYPE_H
#define _NLX_DATATYPE_H
//in GCC, byte packing is done with the __packed__attribute and not with the construct below
//This forces all records to be byte-... |
860c6db3d9d68a088f719fc7df063f9abc26fec4779d32197875c7e1f66e91dd | C/C++ | 8,101 | 233 | // Copyright 2003 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 a... |
20e99ada275bad022d810f2e4b40139457365bd15028413c2ea9f6ff597ded73 | C/C++ | 8,124 | 306 | /***************************************************************************
*
* 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... |
b548d107d92899c7a89d8bb7efae6ef85e37794f39a724149036be1403467459 | C/C++ | 8,125 | 221 | #pragma once
#include <ATen/Config.h>
#if AT_KLEIDIAI_ENABLED()
#include <unordered_map>
#include <kai/kai_common.h>
#include <kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi4c32p/kai_matmul_clamp_f32_qai8dxp1x8_qsi4c32p8x8_1x8x32_neon_dotprod.h>
#include <kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi4c32p/kai_mat... |
8b99fec4fad43c3eeac51e52f838952a3746dc4ff690c095d93656d7227bdc91 | C/C++ | 8,141 | 250 | #pragma once
#include <ATen/cpu/vec/intrinsics.h>
#include <ATen/cpu/vec/vec256/vsx/vsx_helpers.h>
#include <ATen/cpu/vec/vec_base.h>
// Note: header order is important here
#include <ATen/cpu/vec/vec256/vsx/vec256_double_vsx.h>
#include <ATen/cpu/vec/vec256/vsx/vec256_float_vsx.h>
#include <ATen/cpu/vec/vec256/vsx/v... |
6e899cf5021b7cc75c7bdd808da6b8bf33d7f57523fafc64544cdd91275ac0ef | C/C++ | 8,190 | 236 | /***************************************************************************
*
* 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... |
0816301431878013ad5863789a1a8fdcf79f38a242c976ef02f6877b35ae9a6d | C/C++ | 8,230 | 239 | // 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>
// Copyright (C) 2016 Konstantinos Margaritis <markos@freevec.org>
//
// This Source Code Form is subject to the terms of the ... |
0ec50fe7f5faaff2db839cf33887532b3d91a75759831639bd09ee00d2f7da2f | C/C++ | 8,231 | 240 | #pragma once
#include <ATen/core/Tensor.h>
#include <ATen/core/List.h>
#include <ATen/TensorOperators.h>
#include <c10/util/irange.h>
#include <algorithm>
#include <cmath>
#ifndef AT_PER_OPERATOR_HEADERS
#include <ATen/Functions.h>
#include <ATen/NativeFunctions.h>
#else
#include <ATen/ops/quantize_per_tensor_native.... |
b916da8461a532be46efbcef2e53dcc7abc56374a32f72bf691f1974c41490d4 | C/C++ | 8,251 | 187 | // 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 <ATen/functorch/BatchedTensorImpl.h>
namespace at... |
18f975e229c17a2f185915902a7d5f3862c182a70cd1f3cd6abd211e57098495 | C/C++ | 8,266 | 352 | #ifndef __LIBGRAVIS_T4VECTOR_H__
#define __LIBGRAVIS_T4VECTOR_H__
/******************************************************************************
** Title: t4Vector.h
** Description: Represents a four dimensional vector (3D+homogeneous comp.).
**
** Author: Jean-Sebastien Pierrard, 2005
** ... |
fb5f759bc040c85cc869437501812eaebb79b6d3194e536fb14aa3698bd8e91b | C/C++ | 8,314 | 392 | #ifndef __LIBGRAVIS_T_RGB_H__
#define __LIBGRAVIS_T_RGB_H__
/******************************************************************************
** Title: tRGB.h
** Description: Represents an RGB color tupel.
**
** Author: Jean-Sebastien Pierrard, 2005
** Brian Amberg, 2005-2006
** ... |
b5a746c8f60518abc04e30adaf397cfecafebd326ccd6fd4a3bc5ad77449f93f | C/C++ | 8,321 | 207 | // 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... |
e26c1b3bfe291403e8f1c85c41ed30e184abd9eee22317135d4bd183cdb5a8f7 | C/C++ | 8,328 | 255 | /*===================================================================
Program: ASHS (Automatic Segmentation of Hippocampal Subfields)
Module: $Id: WeightedVotingLabelFusionImageFilter.h 114 2016-02-25 17:11:29Z yushkevich $
Language: C++ program
Copyright (c) 2012 Paul A. Yushkevich, University of Pennsy... |
aa7ede9e370b4be28d8933f150ecb1eace473059f2592650a7f385007b881b5b | C/C++ | 8,342 | 451 | #ifndef RADIAL_AVG_H
#define RADIAL_AVG_H
#include <vector>
#include <src/image.h>
#include "buffered_image.h"
class RadialAvg
{
public:
template<typename T>
static std::vector<T> fftwHalf_2D_lin(const RawImage<T>& img, int boundary = 0);
template<typename T>
static std::vector<T> fftwHalf_3D_lin(const Raw... |
ddbbafcb4056df52e301b5927f21929aa6be0f68839339a00eb1ea06d64a1926 | C/C++ | 8,355 | 309 | #ifndef SPLINE_DEFORMATION_MODEL_H
#define SPLINE_DEFORMATION_MODEL_H
#include <src/jaz/gravis/t2Vector.h>
#include <src/jaz/image/raw_image.h>
#include <src/jaz/image/buffered_image.h>
#include <src/jaz/tomography/motion/2D_deformation.h>
class Spline2DDeformationModel
{
public:
struct DataPoint
{
double... |
665b2ba0b2f4ef45e664ae7b21baf20c639bfd2d313805f56f49c00566c0a157 | C/C++ | 8,372 | 268 | /***************************************************************************
*
* 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... |
2e8e8e1964d3436c6eae109ec90a8c75782fe0efb4dd7df3e7ca0d52f1b570b4 | C/C++ | 8,389 | 280 | #pragma once
// DO NOT DEFINE STATIC DATA IN THIS HEADER!
// See Note [Do not compile initializers with AVX]
#include <ATen/cpu/vec/vec256/vec256_16bit_float.h>
#include <c10/util/irange.h>
namespace at::vec {
// See Note [CPU_CAPABILITY namespace]
inline namespace CPU_CAPABILITY {
#ifdef CPU_CAPABILITY_AVX2
templ... |
20a7b8f1a2536a7a8c0098c69ecdd5b98fc20915bb1b7a732ab9cfd986cd26ab | C/C++ | 8,403 | 234 | #pragma once
// DO NOT DEFINE STATIC DATA IN THIS HEADER!
// See Note [Do not compile initializers with SVE]
#include <ATen/cpu/vec/intrinsics.h>
#include <ATen/cpu/vec/sve/sve_helper.h>
#include <ATen/cpu/vec/vec_base.h>
#if defined(CPU_CAPABILITY_SVE256)
#include <ATen/cpu/vec/sve/vec_bfloat16.h>
#include <ATen/c... |
4115db03b7732432ecc70461d0e877f4b6d7a5aaae2222c1eb2afbaa34041fcd | C/C++ | 8,423 | 322 | /***************************************************************************
*
* 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... |
c786445fcc4c7172090f9ec1162dc30aa61d652612f65828c0a6745513b2eef9 | C/C++ | 8,423 | 247 | // 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... |
e3608a892eca5e719e1ef3a266b74f7469fa1ec4924048481a49dede673293b1 | C/C++ | 8,430 | 235 | /***************************************************************************
*
* 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... |
15508bdacf5ecbf2105b104cdbf98728c10b8862f912afe410c02dcc1292d94a | C/C++ | 8,459 | 238 | /***************************************************************************
*
* 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... |
611bf6d43911b2d232deb6118215c22d8aff789df9ade28fbf1e045d77702e6b | C/C++ | 8,462 | 236 | /***************************************************************************
*
* 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... |
e8c89cc9c2e9642f4fb4efddf4510459de2d8a38c96e47c9b7a02e337b54556f | C/C++ | 8,545 | 226 | #ifndef _SYCL_DEVICE_RELION_H
#define _SYCL_DEVICE_RELION_H
#include "src/acc/sycl/sycl_virtual_dev.h"
#include "src/acc/sycl/sycl_memory_pool.h"
#include <cassert>
#include <string>
#include <array>
#include <mutex>
#include <vector>
#include <cstdint>
#include <sycl/sycl.hpp>
#include <sycl/backend.hpp>
#ifdef USE_... |
c1d8c1efff80b56de8a7aed76e3dc4547e9aa5217b7111ba877739841cfe60cb | C/C++ | 8,546 | 249 | /*
* This header file defines relevant features which:
* - Require runtime inspection depending on the NumPy version.
* - May be needed when compiling with an older version of NumPy to allow
* a smooth transition.
*
* As such, it is shipped with NumPy 2.0, but designed to be vendored in full
* or parts by down... |
2d37867494d441d88d9e4c59dcb692d84cc1aa43bdfacb98807192bf0f70f06c | C/C++ | 8,608 | 258 | #pragma once
#include <c10/core/Allocator.h>
#include <c10/util/Exception.h>
#include <c10/util/Registry.h>
#include <ATen/detail/AcceleratorHooksInterface.h>
// NB: Class must live in `at` due to limitations of Registry.h.
namespace at {
// Forward-declares at::cuda::NVRTC
namespace cuda {
struct NVRTC;
} // names... |
412bf9b75fcd0ef701cb84874db8c4c9657b8ea179e901bf2edd8e1cf61387df | C/C++ | 8,610 | 282 | #pragma once
#include <ATen/core/Tensor.h>
#include <ATen/core/IListRef.h>
#include <ATen/Dispatch.h>
#include <ATen/TensorIterator.h>
#include <ATen/native/Activation.h>
#include <ATen/native/DispatchStub.h>
namespace at::native {
using qrelu_fn = void (*)(const at::Tensor& /*qx*/, at::Tensor& /*qy*/);
using qrelu_l... |
05b75604ba101159c9590fd6e4759ce4a6cb04f08809ae2a13b326be45bb46ae | C/C++ | 8,637 | 253 | #pragma once
#include <ATen/cpu/vec/intrinsics.h>
#include <c10/util/Exception.h>
namespace at::vec {
// See Note [CPU_CAPABILITY namespace]
inline namespace CPU_CAPABILITY {
// Transpose a [4, 64] block to [64, 4] (with contiguous output, ld=4)
template <typename scalar_t, typename = std::enable_if_t<sizeof(scalar_... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.