entry_point
stringlengths
1
65
original_triton_python_code
stringlengths
208
619k
optimised_triton_code
stringlengths
1.15k
275k
repo_name
stringlengths
7
115
module_name
stringlengths
1
65
synthetic
bool
1 class
uuid
int64
0
18.5k
licenses
listlengths
1
6
stars
int64
0
19.8k
sha
stringlengths
40
40
repo_link
stringlengths
72
180
Perceptron
import torch import torch.nn as nn from typing import Any import torch.nn.functional as fn class Perceptron(nn.Module): """Implements a 1-layer perceptron.""" def _forward_unimplemented(self, *input: Any) ->None: pass def __init__(self, input_dimension, hidden_dimension, output_dimension): ...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers import torch.nn as nn from ty...
shi27feng/PDP-Solver
Perceptron
false
12,977
[ "MIT" ]
0
bf6e392f72f8a3572e0987313230943d94d53c95
https://github.com/shi27feng/PDP-Solver/tree/bf6e392f72f8a3572e0987313230943d94d53c95
_Decoder
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers import torch.nn as nn import ...
mori97/revae
_Decoder
false
4,034
[ "MIT" ]
0
465009076a9be78e8ddb9021a0699b32fc695f30
https://github.com/mori97/revae/tree/465009076a9be78e8ddb9021a0699b32fc695f30
CustomSoftplus
import torch import torch.nn as nn import torch.utils.data class Softplus(torch.autograd.Function): @staticmethod def forward(ctx, i): result = torch.log(1 + torch.exp(i)) ctx.save_for_backward(i) return result @staticmethod def backward(ctx, grad_output): return grad...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime.triton_helpers import math as tl_math import torch.nn as nn import torch.utils.data assert_size_stride = torch....
SortAnon/BVAE-TTS
CustomSoftplus
false
14,429
[ "MIT" ]
138
69c2ee0c8bf30fe6133cfa8be68a36916f15bcff
https://github.com/SortAnon/BVAE-TTS/tree/69c2ee0c8bf30fe6133cfa8be68a36916f15bcff
Biaffine
import torch import torch.autograd import torch.nn as nn class Biaffine(nn.Module): def __init__(self, n_in, n_out=1, bias_x=True, bias_y=True): super(Biaffine, self).__init__() self.n_in = n_in self.n_out = n_out self.bias_x = bias_x self.bias_y = bias_y weight = ...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream import torch.autograd import torch.nn as nn assert_size_stride = torch._C._dynam...
dumpmemory/W2NER
Biaffine
false
15,257
[ "MIT" ]
128
fb1b6eb1111eb001b1c965097d995244b840bdda
https://github.com/dumpmemory/W2NER/tree/fb1b6eb1111eb001b1c965097d995244b840bdda
TripletLossDoubleMargin
# AOT ID: ['0_inference'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _al...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers import torch.nn as nn assert_size_stride = torch._C._dynamo.guards.assert_size_stride emp...
ax-le/MusicAE
TripletLossDoubleMargin
false
1,508
[ "BSD-3-Clause" ]
0
9fdc268f6403226b990d9ae5c9f182ed0af82f98
https://github.com/ax-le/MusicAE/tree/9fdc268f6403226b990d9ae5c9f182ed0af82f98
DoubleForwardCrossAttentionLayer
import torch import numpy as np import torch.nn as nn import torch.nn.functional as F class ResidualConnectionLayer(nn.Module): def __init__(self, dim_model, prob_dropout=0.1, add_sublayer=True): super(ResidualConnectionLayer, self).__init__() self.add_sublayer = add_sublayer self.norm = ...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers from torch._inductor.runtime....
KirkGuo/HCN
DoubleForwardCrossAttentionLayer
false
5,493
[ "MIT" ]
1
7d8020c8d76413b6ca3a359fb2e9b34652949e17
https://github.com/KirkGuo/HCN/tree/7d8020c8d76413b6ca3a359fb2e9b34652949e17
SDFNetwork
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime.triton_helpers import libdevice, math as tl_math im...
Junlin-Yin/NeuS
SDFNetwork
false
13,954
[ "MIT" ]
345
b13dba90ba1c65d0ccaaca6b9d65225d5dfa8fe2
https://github.com/Junlin-Yin/NeuS/tree/b13dba90ba1c65d0ccaaca6b9d65225d5dfa8fe2
L2Norm
import torch import torch.nn.functional as F import torch.nn as nn class L2Norm(nn.Module): """L2Norm layer across all channels.""" def __init__(self, in_features, scale): super(L2Norm, self).__init__() self.weight = nn.Parameter(torch.Tensor(in_features)) self.reset_parameters(scale)...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers from torch._inductor.runtime.triton_helpers import libdevice import torch.nn as nn assert...
CVHj/torchcv
L2Norm
false
13,447
[ "MIT" ]
433
6291f3e1e4bbf6467fd6b1e79001d34a59481bb6
https://github.com/CVHj/torchcv/tree/6291f3e1e4bbf6467fd6b1e79001d34a59481bb6
GlobalWeightedAvgPool2d
import torch from torch import nn class GlobalWeightedAvgPool2d(nn.Module): """ Global Weighted Average Pooling from paper "Global Weighted Average Pooling Bridges Pixel-level Localization and Image-level Classification" """ def __init__(self, features: 'int', flatten=False): super().__in...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime.triton_helpers import math as tl_math from torch im...
theNero93/dfdc_deepfake_challenge
GlobalWeightedAvgPool2d
false
4,414
[ "MIT" ]
0
ef275206efc6f1b0b7984b370a14bd8db61d1ec1
https://github.com/theNero93/dfdc_deepfake_challenge/tree/ef275206efc6f1b0b7984b370a14bd8db61d1ec1
ConvRelu
import torch from torch import nn import torch.nn.functional as F import torch.cuda import torch.backends.cudnn import torch.backends.mkl import torch.backends.cuda import torch.backends.quantized class ConvRelu(nn.Module): def __init__(self): super(ConvRelu, self).__init__() self.conv = torch.nn...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers from torch import nn import t...
XiaobingSuper/intel-extension-for-pytorch
ConvRelu
false
9,723
[ "Apache-2.0" ]
0
b61029be10e46e6d2e13b0e700c81f8e59164df0
https://github.com/XiaobingSuper/intel-extension-for-pytorch/tree/b61029be10e46e6d2e13b0e700c81f8e59164df0
SiaLoss
# AOT ID: ['0_inference'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _al...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers from torch._inductor.runtime.triton_helpers import libdevice import torch.nn as nn import...
zwzhang121/OpenUnReID
SiaLoss
false
4,678
[ "Apache-2.0" ]
0
4f399efca3d560c608fb4c9c2ed43f522b17596a
https://github.com/zwzhang121/OpenUnReID/tree/4f399efca3d560c608fb4c9c2ed43f522b17596a
ConditionalBatchNorm
import torch class ConditionalBatchNorm(torch.nn.Module): def __init__(self, no, z_dim): super().__init__() self.no = no self.bn = torch.nn.InstanceNorm2d(no, affine=False) self.condition = torch.nn.Linear(z_dim, 2 * no) def forward(self, x, z): cond = self.condition(...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime.triton_helpers import libdevice assert_size_stride ...
ElementAI/beyond-trivial-explanations
ConditionalBatchNorm
false
17,256
[ "Apache-2.0" ]
3
c517d7bdbab68b6a26f74cee4d15e948b3b47238
https://github.com/ElementAI/beyond-trivial-explanations/tree/c517d7bdbab68b6a26f74cee4d15e948b3b47238
ActorNetwork
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers import torch.nn as nn assert_...
TheCamusean/mushroom-rl
ActorNetwork
false
2,895
[ "MIT" ]
0
48585f883e546ea57224b8d446ecb9b8ba90cf73
https://github.com/TheCamusean/mushroom-rl/tree/48585f883e546ea57224b8d446ecb9b8ba90cf73
ModMBStddevLayer
import torch import torch.nn as nn class ModMBStddevLayer(nn.Module): """Modified MiniBatch Stddev Layer. This layer is modified from ``MiniBatchStddevLayer`` used in PGGAN. In StyleGAN2, the authors add a new feature, `channel_groups`, into this layer. """ def __init__(self, group_size=4, c...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime.triton_helpers import libdevice import torch.nn as nn assert_size_stride = torch._C._dynamo.guards.assert_size_...
Sardhendu/mmediting
ModMBStddevLayer
false
9,891
[ "Apache-2.0" ]
0
623b59ac758d856abc9fab7e845beeab61074d8f
https://github.com/Sardhendu/mmediting/tree/623b59ac758d856abc9fab7e845beeab61074d8f
ScalarBiasScale
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream import torch.nn as nn from torch.nn.parameter import Parameter from torch.nn import init assert_size_stride = torch._C._dynamo.guards.assert...
Ali-Homsi/githubrepo
ScalarBiasScale
false
25
[ "Apache-2.0" ]
0
7163f110193142a97ec05f76ff7d897c6cedb915
https://github.com/Ali-Homsi/githubrepo/tree/7163f110193142a97ec05f76ff7d897c6cedb915
DNHloss
import torch import torch.nn as nn class DNHloss(nn.Module): """DNH loss function Arguments: nn {[type]} -- [description] """ def __init__(self, lamda): """Initializer class Arguments: lamda {[type]} -- [description] """ super(DNHloss, self).__ini...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers from torch._inductor.runtime....
jce2090/palmprint-recognition
DNHloss
false
3,711
[ "MIT" ]
0
d2d93c6817afe1b67650dae6516a3d180aaeca38
https://github.com/jce2090/palmprint-recognition/tree/d2d93c6817afe1b67650dae6516a3d180aaeca38
MaximumLikelihoodLoss
from torch.nn import Module import torch import torch.utils.data import torch.nn.functional import torch.autograd class MaximumLikelihoodLoss(Module): """ <a id="MaximumLikelihoodLoss"></a> ## Type II Maximum Likelihood Loss The distribution $D(\\mathbf{p} ert extcolor{orange}{\\mathbf{lpha}})$ i...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime.triton_helpers import math as tl_math from torch.nn import Module import torch.utils.data import torch.nn.funct...
techthiyanes/annotated_deep_learning_paper_implementations
MaximumLikelihoodLoss
false
16,549
[ "MIT" ]
3,714
8af24da2dd39a9a87482a4d18c2dc829bbd3fd47
https://github.com/techthiyanes/annotated_deep_learning_paper_implementations/tree/8af24da2dd39a9a87482a4d18c2dc829bbd3fd47
DeNormalize
import torch import torch.nn as nn import torch.utils.cpp_extension class DeNormalize(nn.Module): def __init__(self, mean, std): super().__init__() self.mean = mean self.std = std def forward(self, x): return x.mul(self.std).add(self.mean) def get_inputs(): return [torc...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream import torch.nn as nn import torch.utils.cpp_extension assert_size_stride = torch._C._dynamo.guards.assert_size_stride empty_strided_cuda = ...
STomoya/animeface
DeNormalize
false
14,363
[ "MIT" ]
61
37b3cd26097d7874559d4c152e41e5712b7a1a42
https://github.com/STomoya/animeface/tree/37b3cd26097d7874559d4c152e41e5712b7a1a42
FeatureModel
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers import torch.nn as nn assert_...
nassarofficial/pytorch-retina
FeatureModel
false
4,077
[ "Apache-2.0" ]
0
b2f10ffa7617797280c1f44d562c455b996254af
https://github.com/nassarofficial/pytorch-retina/tree/b2f10ffa7617797280c1f44d562c455b996254af
Encoder
import torch import torch.nn as nn import torch.nn.functional as F class Encoder(nn.Module): def __init__(self, sample_size, condition_size, hidden_size): super().__init__() self.fc1 = nn.Linear(sample_size + condition_size, hidden_size) self.fc2 = nn.Dropout(p=0.5) self.fc3 = nn....
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers import torch.nn as nn assert_...
ekrell/learn-planning-space
Encoder
false
3,464
[ "MIT" ]
0
730e448bffa4996b2b1ef3a5b00500dc172962ec
https://github.com/ekrell/learn-planning-space/tree/730e448bffa4996b2b1ef3a5b00500dc172962ec
SmallMnist
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers from torch._inductor.runtime....
arjunsuresh/aimet
SmallMnist
false
12,736
[ "BSD-3-Clause" ]
0
f6e09cb07a91eed3a5e6b8e19e6b065303af5a39
https://github.com/arjunsuresh/aimet/tree/f6e09cb07a91eed3a5e6b8e19e6b065303af5a39
ReOrgLayer
# AOT ID: ['0_inference'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _al...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch import nn assert_size_stride = torch._C._dynamo.guards.assert_size_stride empty_strided_cuda = torch._C._dynamo.guards._empty_str...
MaoXianXin/pytorchx
ReOrgLayer
false
11,687
[ "MIT" ]
0
f46cc9692c3bd11ea9d5d54c20de3ac2f67dabcc
https://github.com/MaoXianXin/pytorchx/tree/f46cc9692c3bd11ea9d5d54c20de3ac2f67dabcc
ZeroPad1d
import torch import torch.nn.functional as F from torch import nn import torch.utils.data import torch.onnx.operators import torch.optim import torch.optim.lr_scheduler class ZeroPad1d(nn.Module): def __init__(self, pad_left, pad_right): super().__init__() self.pad_left = pad_left self.pa...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch import nn import torch.utils.data import torch.onnx.operators import torch.optim import torch.optim.lr_scheduler assert_size_stri...
ChenDdon/AGBTcode
ZeroPad1d
false
7,880
[ "MIT" ]
21
6c259d18b48dc8d6da1357c42a1ee088666fb7b4
https://github.com/ChenDdon/AGBTcode/tree/6c259d18b48dc8d6da1357c42a1ee088666fb7b4
Pooling
import torch import torch.nn as nn import torch.nn.parallel import torch.optim import torch.utils.data from typing import * class ReLUConvBN(nn.Module): """ Parameters --- C_in: int the number of input channels C_out: int the number of output channels stride: int stride...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream import torch.nn as nn import torch.nn.parallel import torch.optim import torch.utils.data from typing import * assert_size_stride = torch._C...
rmfan/nni
Pooling
false
10,941
[ "MIT" ]
0
727ee1ce47e070061fe3dab8a2da5d3cd5e55546
https://github.com/rmfan/nni/tree/727ee1ce47e070061fe3dab8a2da5d3cd5e55546
SplAtConv2d
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers from torch._inductor.runtime....
JHMeusener/detectron2-ResNeSt
SplAtConv2d
false
604
[ "Apache-2.0" ]
0
6abab6fb9496a528f6aa2d4e1e27f3e7ceb42685
https://github.com/JHMeusener/detectron2-ResNeSt/tree/6abab6fb9496a528f6aa2d4e1e27f3e7ceb42685
CorrelationAlignmentLoss
# AOT ID: ['0_inference'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _al...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream import torch.nn as nn import torch.utils.data assert_size_stride = torch._C._dyn...
XianyuanLiu/Transfer-Learning-Library
CorrelationAlignmentLoss
false
10,136
[ "MIT" ]
0
25f83f32437032df88ca6101ecd1f63ec7a0aa2c
https://github.com/XianyuanLiu/Transfer-Learning-Library/tree/25f83f32437032df88ca6101ecd1f63ec7a0aa2c
LIN
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime.triton_helpers import libdevice import torch.nn as nn from torch.nn.parameter import Parameter assert_size_stri...
Gxx-5/MyPhoto2Cartoon
LIN
false
11,460
[ "MIT" ]
0
aa05dfa8b7d6c507c33026a2e8b299d5779357be
https://github.com/Gxx-5/MyPhoto2Cartoon/tree/aa05dfa8b7d6c507c33026a2e8b299d5779357be
discriminator2
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers from torch._inductor.runtime....
layel2/layyer-lib
discriminator2
false
3,881
[ "MIT" ]
0
db48b5c38098ee93d2d34693d98e5ef4d319d919
https://github.com/layel2/layyer-lib/tree/db48b5c38098ee93d2d34693d98e5ef4d319d919
ExtResNetBlock
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime.triton_helpers import libdevice from torch import n...
cviaai/TMJ_tracking
ExtResNetBlock
false
1,774
[ "MIT" ]
0
464ca21dbeb538dc9504bd5d0e5c4d92591e69c4
https://github.com/cviaai/TMJ_tracking/tree/464ca21dbeb538dc9504bd5d0e5c4d92591e69c4
SubPixelConvolutionalBlock
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch import nn assert_size_stride = torch._C._dynamo.guards.assert_size_st...
DanielLiang1/a-PyTorch-Tutorial-to-Super-Resolution
SubPixelConvolutionalBlock
false
361
[ "MIT" ]
0
cf7b519029687fe9726bb194fe3765934afa18b3
https://github.com/DanielLiang1/a-PyTorch-Tutorial-to-Super-Resolution/tree/cf7b519029687fe9726bb194fe3765934afa18b3
Pow
import torch import torch.nn as nn class Pow(nn.Module): """ Applies `x ** sigmoid(a)`, with `a` fixed or trainable. """ def __init__(self, a=0, trainable=False): super(Pow, self).__init__() if trainable: a = nn.Parameter(torch.tensor(a, dtype=torch.get_default_dtype())) ...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime.triton_helpers import libdevice import torch.nn as nn assert_size_stride = torch._C._dynamo.guards.assert_size_...
CPJKU/kagglebirds2020
Pow
false
17,023
[ "MIT" ]
4
f86b459389b1d0b0af96ebc9252ffc8496c272e8
https://github.com/CPJKU/kagglebirds2020/tree/f86b459389b1d0b0af96ebc9252ffc8496c272e8
LinearBlock
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers from torch._inductor.runtime....
JasonMa2016/learn2learn
LinearBlock
false
870
[ "MIT" ]
0
502e1ea6db64481d7464fdda4d4d0be9b0f1089a
https://github.com/JasonMa2016/learn2learn/tree/502e1ea6db64481d7464fdda4d4d0be9b0f1089a
C3D
import torch import torch.nn as nn import torch.nn class C3D(nn.Module): def __init__(self, inplanes, planes): super(C3D, self).__init__() self.c3d = nn.Conv3d(inplanes, planes, kernel_size=3, padding=1) def forward(self, x): x = self.c3d(x) return x def get_inputs(): r...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream import torch.nn as nn import torch.nn assert_size_stride = torch._C._dynamo.guar...
Schmiddo/d2conv3d
C3D
false
8,748
[ "MIT" ]
16
9b330be56f0dfb9657a63e3fb3394ab36b35a67b
https://github.com/Schmiddo/d2conv3d/tree/9b330be56f0dfb9657a63e3fb3394ab36b35a67b
ThreeNet
import torch import torch.nn as nn class ThreeNet(nn.Module): """ A network with three layers. This is used for testing a network with more than one operation. The network has a convolution layer followed by two fully connected layers. """ def __init__(self, input_dim: 'int', conv_dim: 'int',...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream import torch.nn as nn assert_size_stride = torch._C._dynamo.guards.assert_size_s...
DenXX/fvcore
ThreeNet
false
2,232
[ "Apache-2.0" ]
0
4b91cf092f4f5d379b2c93398780a3b5755e7179
https://github.com/DenXX/fvcore/tree/4b91cf092f4f5d379b2c93398780a3b5755e7179
ShiftedSoftplus
import torch import torch.nn.functional as F import torch.fx import torch.utils.data class ShiftedSoftplus(torch.nn.Module): def __init__(self): super(ShiftedSoftplus, self).__init__() self.shift = torch.log(torch.tensor(2.0)).item() def forward(self, x): return F.softplus(x) - self....
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime.triton_helpers import libdevice, math as tl_math import torch.fx import torch.utils.data assert_size_stride = t...
JinheonBaek/pytorch_geometric
ShiftedSoftplus
false
17,511
[ "MIT" ]
4
dfd32d08a3d8191d6290e53458d4eda515d04fd6
https://github.com/JinheonBaek/pytorch_geometric/tree/dfd32d08a3d8191d6290e53458d4eda515d04fd6
ItemToInterestAggregation
import torch import torch.nn as nn class ItemToInterestAggregation(nn.Module): def __init__(self, seq_len, hidden_size, k_interests=5): super().__init__() self.k_interests = k_interests self.theta = nn.Parameter(torch.randn([hidden_size, k_interests])) def forward(self, input_tensor)...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers from torch._inductor.runtime....
dreaming-qin/RecBole
ItemToInterestAggregation
false
12,319
[ "MIT" ]
0
d6de39521484ded60c387ca604abaf86310acdbe
https://github.com/dreaming-qin/RecBole/tree/d6de39521484ded60c387ca604abaf86310acdbe
CO2Regularizer
import torch class MemoryBankModule(torch.nn.Module): """Memory bank implementation This is a parent class to all loss functions implemented by the lightly Python package. This way, any loss can be used with a memory bank if desired. Attributes: size: Number of keys the memo...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers from torch._inductor.runtime.triton_helpers import libdevice assert_size_stride = torch._...
EelcoHoogendoorn/lightly
CO2Regularizer
false
5,118
[ "MIT" ]
1
98e0148967738404fa7f45196ec5eabfe00cd22e
https://github.com/EelcoHoogendoorn/lightly/tree/98e0148967738404fa7f45196ec5eabfe00cd22e
ConvSqu
import torch import torch.nn.functional as F import torch.utils.data import torch import torch.nn as nn def autopad(k, p=None): if p is None: p = k // 2 if isinstance(k, int) else [(x // 2) for x in k] return p class Mish(nn.Module): @staticmethod def forward(x): return x * F.softpl...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime.triton_helpers import libdevice, math as tl_math im...
Beaver48/kaggle-chest-xray-abnormalities
ConvSqu
false
11,310
[ "MIT" ]
0
d41f32d1c59cb5c925795df3291e929b3ea6d5fd
https://github.com/Beaver48/kaggle-chest-xray-abnormalities/tree/d41f32d1c59cb5c925795df3291e929b3ea6d5fd
LayerNorm
import torch import torch.nn.init import torch.optim.lr_scheduler class LayerNorm(torch.nn.Module): """ An implementation of `Layer Normalization <https://www.semanticscholar.org/paper/Layer-Normalization-Ba-Kiros/97fb4e3d45bb098e27e0071448b6152217bd35a5>`_ . Layer Normalization stabilises the traini...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime.triton_helpers import libdevice import torch.nn.init import torch.optim.lr_scheduler assert_size_stride = torch...
azraelzhor/allen-nlp-rc
LayerNorm
false
3,153
[ "Apache-2.0" ]
0
b114c00a8f364b18e3c427c1a447be9c65ede551
https://github.com/azraelzhor/allen-nlp-rc/tree/b114c00a8f364b18e3c427c1a447be9c65ede551
ConvertTHWCtoTCHW
# AOT ID: ['0_inference'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _al...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream import torch.utils.data assert_size_stride = torch._C._dynamo.guards.assert_size_stride empty_strided_cuda = torch._C._dynamo.guards._empty_...
XianyuanLiu/Transfer-Learning-Library
ConvertTHWCtoTCHW
false
10,131
[ "MIT" ]
0
25f83f32437032df88ca6101ecd1f63ec7a0aa2c
https://github.com/XianyuanLiu/Transfer-Learning-Library/tree/25f83f32437032df88ca6101ecd1f63ec7a0aa2c
Rot180
# AOT ID: ['0_inference'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _al...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream import torch.nn as nn assert_size_stride = torch._C._dynamo.guards.assert_size_stride empty_strided_cuda = torch._C._dynamo.guards._empty_st...
JoanFM/kornia
Rot180
false
11,545
[ "ECL-2.0", "Apache-2.0" ]
0
808898887cde69074ca3e3df9b24dea9682aad90
https://github.com/JoanFM/kornia/tree/808898887cde69074ca3e3df9b24dea9682aad90
PSPModule
# AOT ID: ['0_inference'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _al...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers import torch.nn as nn import torch._C import torch.serialization assert_size_stride = tor...
AlexanderDokuchaev/mmsegmentation
PSPModule
false
11,191
[ "Apache-2.0" ]
0
0c443ee370cce6227661b802184072174c4e3f64
https://github.com/AlexanderDokuchaev/mmsegmentation/tree/0c443ee370cce6227661b802184072174c4e3f64
NoiseLayer
import torch from torch import nn import torch.nn class NoiseLayer(nn.Module): """adds noise. noise is per pixel (constant over channels) with per-channel weight""" def __init__(self, channels): super().__init__() self.weight = nn.Parameter(torch.zeros(channels)) self.noise = None ...
import torch from torch import device import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch import nn import torch.nn assert_size_stride = torch._C._dynamo.guards.assert_size_stride empty_strided_...
Qingyang-Xu/GANInversion_with_ConsecutiveImgs
NoiseLayer
false
8,673
[ "MIT" ]
23
9078a48ec3474dacdd02693b051e3addef1c5697
https://github.com/Qingyang-Xu/GANInversion_with_ConsecutiveImgs/tree/9078a48ec3474dacdd02693b051e3addef1c5697
AdaptiveAvgPool
import torch import uuid import torch.utils.data import torch.utils.data.distributed from torch import nn import torch.nn.parallel import torch.optim def _get_right_parentheses_index_(struct_str): """get the position of the first right parenthese in string""" left_paren_count = 0 for index, single_char in...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream import uuid import torch.utils.data import torch.utils.data.distributed from torch import nn import torch.nn.parallel import torch.optim ass...
Adlik/zen_nas
AdaptiveAvgPool
false
16,888
[ "Apache-2.0" ]
7
d820d5c7d5bbb6fd66a76d5f16513647d6ea7a57
https://github.com/Adlik/zen_nas/tree/d820d5c7d5bbb6fd66a76d5f16513647d6ea7a57
SimpleNet
import torch import torch.nn as nn class SimpleNet(nn.Module): def __init__(self, width, input_size, output_size, pool='max'): super(SimpleNet, self).__init__() self.pool = nn.MaxPool2d(width, stride=width ) if pool == 'max' else nn.AvgPool2d(width, stride=width) self.fc1 = nn...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers import torch.nn as nn assert_...
daniel-zeng/SegSort
SimpleNet
false
9,976
[ "MIT" ]
0
7a50e6253df23a7719f962b34acff2626c916354
https://github.com/daniel-zeng/SegSort/tree/7a50e6253df23a7719f962b34acff2626c916354
GatedTanh
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime.triton_helpers import libdevice import torch.nn as ...
VisualJoyce/ChengyuBERT
GatedTanh
false
18,083
[ "MIT" ]
8
605db3a4b3241dd4d02baa41a68bf23b5b00b36d
https://github.com/VisualJoyce/ChengyuBERT/tree/605db3a4b3241dd4d02baa41a68bf23b5b00b36d
MapNet
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers import torch.nn as nn assert_...
DRL-CASIA/Perception
MapNet
false
7,930
[ "MIT" ]
39
a0e7d3957267ce92a82b03ab3eca96916d22c4f2
https://github.com/DRL-CASIA/Perception/tree/a0e7d3957267ce92a82b03ab3eca96916d22c4f2
DeconvBlock
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime.triton_helpers import libdevice, math as tl_math im...
richardlyf/FeatDepth
DeconvBlock
false
12,935
[ "MIT" ]
0
6739ee0ded5a91a97d6cea1aa259c64f8b520fcd
https://github.com/richardlyf/FeatDepth/tree/6739ee0ded5a91a97d6cea1aa259c64f8b520fcd
GaussianKernel
import torch from torch import nn class GaussianKernel(nn.Module): """ Gaussian kernel module. :param mu: Float, mean of the kernel. :param sigma: Float, sigma of the kernel. Examples: >>> import torch >>> kernel = GaussianKernel() >>> x = torch.randn(4, 5, 10) >>...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime.triton_helpers import math as tl_math from torch import nn assert_size_stride = torch._C._dynamo.guards.assert_...
amberhuang01/LearningFromFactCheckers
GaussianKernel
false
18,299
[ "MIT" ]
9
3c21684709bf5e331c4585c7d62596960dd44732
https://github.com/amberhuang01/LearningFromFactCheckers/tree/3c21684709bf5e331c4585c7d62596960dd44732
NCModel
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime.triton_helpers import libdevice from torch import nn from torch.nn import Parameter assert_size_stride = torch....
DavidHidde/backdoors101
NCModel
false
11,334
[ "MIT" ]
0
76ad5b391d3526fa26c3985e611d576c05724714
https://github.com/DavidHidde/backdoors101/tree/76ad5b391d3526fa26c3985e611d576c05724714
DecoderNet
import torch import torch.nn.functional as F import torch.nn as nn class DecoderNet(nn.Module): """ The decoder takes an interpolated feature vector and turn it into the output signal. This net is intended to be very lightweight, it has only one hidden layer. """ def __init__(self, feature_si...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers import torch.nn as nn assert_...
eliemichel/ReACORN
DecoderNet
false
6,649
[ "MIT" ]
1
74501551ecb387352271674efb2ed6240d234df6
https://github.com/eliemichel/ReACORN/tree/74501551ecb387352271674efb2ed6240d234df6
Discriminator
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream import numpy as np import torch.nn as nn assert_size_stride = torch._C._dynamo.g...
jfrancis71/pytorch-lightning-bolts
Discriminator
false
3,838
[ "Apache-2.0" ]
0
8a4cf8f61644c28d6df54ccffe3a52d6f5fce5a6
https://github.com/jfrancis71/pytorch-lightning-bolts/tree/8a4cf8f61644c28d6df54ccffe3a52d6f5fce5a6
GlobalAttentionGeneral
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers from torch._inductor.runtime....
MaxyLee/Style-AttnGAN
GlobalAttentionGeneral
false
8,528
[ "MIT" ]
36
d33d0df061c94b75ad4af5c750b8d6f37ee1a35a
https://github.com/MaxyLee/Style-AttnGAN/tree/d33d0df061c94b75ad4af5c750b8d6f37ee1a35a
LogSumExpPool
import torch import torch.nn as nn class LogSumExpPool(nn.Module): def __init__(self, gamma): super(LogSumExpPool, self).__init__() self.gamma = gamma def forward(self, feat_map): """ Numerically stable implementation of the operation Arguments: feat_map(T...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers from torch._inductor.runtime.triton_helpers import math as tl_math import torch.nn as nn ...
C3-ASV-Team/torchxrayvision
LogSumExpPool
false
4,926
[ "Apache-2.0" ]
1
7e53f0606986562f17a1ffd9f31d006756eff78d
https://github.com/C3-ASV-Team/torchxrayvision/tree/7e53f0606986562f17a1ffd9f31d006756eff78d
GeneratorLat
import torch import torch.onnx import torch.nn as nn import torch.nn.functional as F class GeneratorLat(nn.Module): """Define standard linear + softmax generation step.""" def __init__(self, d_model, tgt_lat_classes): super(GeneratorLat, self).__init__() self.proj = nn.Linear(d_model, tgt_lat...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers from torch._inductor.runtime....
PhilippeW83440/conv-social-pooling
GeneratorLat
false
17,830
[ "MIT" ]
4
93d3a08af8678c3309d75a9bfb37df500da5cc46
https://github.com/PhilippeW83440/conv-social-pooling/tree/93d3a08af8678c3309d75a9bfb37df500da5cc46
elu_modified
# AOT ID: ['0_inference'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _al...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime.triton_helpers import libdevice import torch.nn as nn import torch.utils.data assert_size_stride = torch._C._dy...
aasensio/umal_pytorch
elu_modified
false
9,634
[ "MIT" ]
0
17bf1fee006c26dc277eb31f22aee022246c0367
https://github.com/aasensio/umal_pytorch/tree/17bf1fee006c26dc277eb31f22aee022246c0367
G_Large
import torch import torch.nn as nn class Conv2d(nn.Module): def __init__(self, in_channels, out_channels, kernel_size, stride=1, bn =False, activation='leakyrelu', dropout=False): super(Conv2d, self).__init__() padding = int((kernel_size - 1) / 2) self.conv = nn.Conv2d(in_channels...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers import torch.nn as nn assert_...
RQuispeC/pytorch-ACSCP
G_Large
false
8,766
[ "MIT" ]
25
c83f08632012c2245250ff9c5140814461db575c
https://github.com/RQuispeC/pytorch-ACSCP/tree/c83f08632012c2245250ff9c5140814461db575c
Classify
import torch import torch.nn as nn def autopad(k, p=None): if p is None: p = k // 2 if isinstance(k, int) else [(x // 2) for x in k] return p class Classify(nn.Module): def __init__(self, c1, c2, k=1, s=1, p=None, g=1): super().__init__() self.aap = nn.AdaptiveAvgPool2d(1) ...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream import torch.nn as nn assert_size_stride = torch._C._dynamo.guards.assert_size_s...
Aditya239233/MDP
Classify
false
16,896
[ "MIT" ]
4
87491e1d67e547c11f4bdd5d784d120473429eae
https://github.com/Aditya239233/MDP/tree/87491e1d67e547c11f4bdd5d784d120473429eae
Adder2D
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime.triton_helpers import math as tl_math from torch.autograd import Function import math import torch.nn as nn fro...
poppin-mice/ShiftAddNet
Adder2D
false
16,268
[ "MIT" ]
55
a17369a50da5bba6250fdeac7c065bd00f293f3c
https://github.com/poppin-mice/ShiftAddNet/tree/a17369a50da5bba6250fdeac7c065bd00f293f3c
TwoHiddenLayerFc
import torch import torch.nn as nn import torch.nn.functional as F class TwoHiddenLayerFc(nn.Module): def __init__(self, input_shape, out_dim): super(TwoHiddenLayerFc, self).__init__() self.fc1 = nn.Linear(input_shape, 200) self.fc2 = nn.Linear(200, 200) self.fc3 = nn.Linear(200, ...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers import torch.nn as nn assert_...
jasonyanglu/fedavgpy
TwoHiddenLayerFc
false
6,927
[ "MIT" ]
1
cefbe5854f02d3df1197d849872286439c86e949
https://github.com/jasonyanglu/fedavgpy/tree/cefbe5854f02d3df1197d849872286439c86e949
weightedFeatureFusion
# AOT ID: ['0_inference'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _al...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream import torch.nn as nn assert_size_stride = torch._C._dynamo.guards.assert_size_stride empty_strided_cuda = torch._C._dynamo.guards._empty_st...
heymesut/SJTU_microe
weightedFeatureFusion
false
6,804
[ "BSD-3-Clause" ]
1
7a862d03b4d8fe4c8608173a16082f44001f3f13
https://github.com/heymesut/SJTU_microe/tree/7a862d03b4d8fe4c8608173a16082f44001f3f13
SEModule
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers import torch.nn as nn assert_...
VisualAnalysisOfHumans/LOVEU_TRACK1_TOP3_SUBMISSION
SEModule
false
5,939
[ "MIT" ]
1
6f4d1c7e6883d6b0664fcd04265f437247afab54
https://github.com/VisualAnalysisOfHumans/LOVEU_TRACK1_TOP3_SUBMISSION/tree/6f4d1c7e6883d6b0664fcd04265f437247afab54
ContrastiveLoss
import torch import torch.cuda import torch.nn.functional as F class ContrastiveLoss(torch.nn.Module): """ Triplet loss function based on Contrastive loss function. Based on: http://yann.lecun.com/exdb/publis/pdf/hadsell-chopra-lecun-06.pdf """ def __init__(self, margin=0.2): super(Contra...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers from torch._inductor.runtime.triton_helpers import libdevice import torch.cuda assert_siz...
CS5590-0001-Projject/CS5590-0001-Project
ContrastiveLoss
false
11,284
[ "MIT" ]
0
18a9f0df7b2ef0f5e9ec7a4bd4e77f761abfd8f3
https://github.com/CS5590-0001-Projject/CS5590-0001-Project/tree/18a9f0df7b2ef0f5e9ec7a4bd4e77f761abfd8f3
ClassificationModel
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers import torch.nn as nn assert_...
LLYXC/OXNet
ClassificationModel
false
8,430
[ "Apache-2.0" ]
13
4fb67a8c42b9158a8e563c4b68a157e4dedd9c66
https://github.com/LLYXC/OXNet/tree/4fb67a8c42b9158a8e563c4b68a157e4dedd9c66
BertLayer
from _paritybench_helpers import _mock_config import math import torch import torch.nn as nn import torch.nn.functional as F class BertSelfAttention(nn.Module): def __init__(self, config): super().__init__() self.num_attention_heads = config.num_attention_heads self.attention_head_size = ...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers from torch._inductor.runtime....
Abhimanyu08/minbert-assignment
BertLayer
false
13,211
[ "Apache-2.0" ]
0
1610364213b1aab2d5446175dffabd7e1742833b
https://github.com/Abhimanyu08/minbert-assignment/tree/1610364213b1aab2d5446175dffabd7e1742833b
CriticNet
import torch import torch.nn as nn import torch.nn.functional as F class CriticNet(nn.Module): def __init__(self, num_state, num_action): super(CriticNet, self).__init__() self.num_state = num_state self.num_action = num_action self.fc1 = nn.Linear(num_state, 100) self.fc2...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers import torch.nn as nn assert_...
cugzj/Adaptive-B
CriticNet
false
6,492
[ "Apache-2.0" ]
1
cebc965b1dbad93332ae371bfef8640259d940c4
https://github.com/cugzj/Adaptive-B/tree/cebc965b1dbad93332ae371bfef8640259d940c4
Generator
import torch import torch.nn as nn import torch.nn.functional as F class Decoder(nn.Module): def __init__(self): super(Decoder, self).__init__() self.conv6_1 = nn.Conv2d(512, 512, kernel_size=3, stride=1, padding=1) self.conv6_2 = nn.Conv2d(512, 512, kernel_size=3, stride=1, padding=1) ...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers import torch.nn as nn import ...
bigabig/saliency
Generator
false
6,509
[ "Apache-2.0" ]
1
83618c90ea419ee05fbed116e8ad7bb2b331ecf5
https://github.com/bigabig/saliency/tree/83618c90ea419ee05fbed116e8ad7bb2b331ecf5
MaskedConv1d
import torch import torch.nn as nn import torch.onnx class MaskedConv1d(nn.Conv1d): def __init__(self, in_channels, out_channels, kernel_size, dilation=1, groups=1, bias=True, causal=True): if causal: padding = (kernel_size - 1) * dilation else: padding = (kernel_s...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream import torch.nn as nn import torch.onnx assert_size_stride = torch._C._dynamo.gu...
jonndoe/Character-Level-Language-Modeling-with-Deeper-Self-Attention-pytorch
MaskedConv1d
false
3,772
[ "MIT" ]
0
d27d2d390f0831330405c16bd29c7f331ad2007a
https://github.com/jonndoe/Character-Level-Language-Modeling-with-Deeper-Self-Attention-pytorch/tree/d27d2d390f0831330405c16bd29c7f331ad2007a
SkipLastTargetChannelWrapper
import torch import torch.nn as nn from torch.nn import MSELoss class SkipLastTargetChannelWrapper(nn.Module): """ Loss wrapper which removes additional target channel """ def __init__(self, loss, squeeze_channel=False): super(SkipLastTargetChannelWrapper, self).__init__() self.loss =...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream import torch.nn as nn assert_size_stride = torch._C._dynamo.guards.assert_size_stride empty_strided_cuda = torch._C._dynamo.guards._empty_st...
BioTrillion/pytorch-3dunet
SkipLastTargetChannelWrapper
false
4,897
[ "MIT" ]
1
217781197dd94211ee7fe5d53a8b404f0b8391a6
https://github.com/BioTrillion/pytorch-3dunet/tree/217781197dd94211ee7fe5d53a8b404f0b8391a6
MaskedThing
# AOT ID: ['0_inference'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _al...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers from torch._inductor.runtime.triton_helpers import libdevice import torch.nn as nn assert...
vegetablejuiceftw/soft-pointer-networks
MaskedThing
false
11,072
[ "MIT" ]
0
9705d9688b6b69db3948172771df4c367165c948
https://github.com/vegetablejuiceftw/soft-pointer-networks/tree/9705d9688b6b69db3948172771df4c367165c948
BertMixedLayer
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers from torch._inductor.runtime....
Erotemic/MONAI
BertMixedLayer
false
5,727
[ "Apache-2.0" ]
1
a9cd2d88168107281a2abcc2f63efaed80580e79
https://github.com/Erotemic/MONAI/tree/a9cd2d88168107281a2abcc2f63efaed80580e79
PolicyNetwork
import torch import torch.nn as nn import torch.nn.functional as F class PolicyNetwork(nn.Module): def __init__(self, num_inputs, num_actions, hidden_size, init_w=3e-05): super(PolicyNetwork, self).__init__() self.linear1 = nn.Linear(num_inputs, hidden_size) self.linear2 = nn.Linear(hidde...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers from torch._inductor.runtime....
frknayk/Reinforcement-Learning-In-Control
PolicyNetwork
false
6,703
[ "MIT" ]
1
24c7eb6fa6b6390ee2dd04f25036c37896ecd944
https://github.com/frknayk/Reinforcement-Learning-In-Control/tree/24c7eb6fa6b6390ee2dd04f25036c37896ecd944
CausalConv1d
import torch from torch import nn class CausalConv1d(nn.Module): def __init__(self, in_channels, out_channels, kernel_size=2, dilation=2): super(CausalConv1d, self).__init__() self.padding = dilation self.causal_conv = nn.Conv1d(in_channels, out_channels, kernel_size, padding=...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch import nn assert_size_stride = torch._C._dynamo.guards.assert_size_st...
gaotianyu1350/new_fewrel_bertpair
CausalConv1d
false
15,397
[ "MIT" ]
180
27184050d476fc93576948fb26680d508a2824bb
https://github.com/gaotianyu1350/new_fewrel_bertpair/tree/27184050d476fc93576948fb26680d508a2824bb
MyKernelTorch
import torch import torch.nn as nn class MyKernelTorch(nn.Module): def __init__(self, n_features: 'int'): super().__init__() self.dense1 = nn.Linear(n_features, 20) self.dense2 = nn.Linear(20, 2) def forward(self, x: 'torch.Tensor') ->torch.Tensor: x = nn.ReLU()(self.dense1(x...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers import torch.nn as nn assert_...
sugatoray/alibi-detect
MyKernelTorch
false
16,505
[ "Apache-2.0" ]
1,227
66d7873c248c0be1a1d836e6fe1ef59351b802d9
https://github.com/sugatoray/alibi-detect/tree/66d7873c248c0be1a1d836e6fe1ef59351b802d9
ConcatenateLinear
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream import torch.utils.tensorboard import torch.utils.data import torch.distributed ...
JoeLambourne/SketchGraphs
ConcatenateLinear
false
1,259
[ "MIT" ]
0
183c65f82d71d82c62b253092e9b7fa65846a3e6
https://github.com/JoeLambourne/SketchGraphs/tree/183c65f82d71d82c62b253092e9b7fa65846a3e6
ClassNetVideoConv
import torch import torch.nn as nn import torch.nn.functional as F import torch.utils.data class Unit3D(nn.Module): """Basic unit containing Conv3D + BatchNorm + non-linearity.""" def __init__(self, in_channels, output_channels, kernel_shape=(1, 1, 1), stride=(1, 1, 1), padding=0, activation_fn=F.rel...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream import torch.nn as nn import torch.nn.functional as F import torch.utils.data as...
SheffieldAI/pykale
ClassNetVideoConv
false
16,858
[ "MIT" ]
324
be7670941fb06835883c80477b26702d407017db
https://github.com/SheffieldAI/pykale/tree/be7670941fb06835883c80477b26702d407017db
ScaledDotProductAttention
import torch import numpy as np import torch.nn as nn class ScaledDotProductAttention(nn.Module): """ Scaled Dot-Product Attention """ def __init__(self, temperature, attn_dropout=0.1): super().__init__() self.temperature = temperature self.dropout = nn.Dropout(attn_dropout) s...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers from torch._inductor.runtime....
Jincheng-Sun/Kylearn-pytorch
ScaledDotProductAttention
false
641
[ "MIT" ]
0
e72f2ab45a3f4724e843a27bec37664d3612fdca
https://github.com/Jincheng-Sun/Kylearn-pytorch/tree/e72f2ab45a3f4724e843a27bec37664d3612fdca
NullDiscriminator
# AOT ID: ['0_inference'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _al...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream import torch.nn as nn import torch.utils.data assert_size_stride = torch._C._dynamo.guards.assert_size_stride empty_strided_cuda = torch._C....
HappyBelief/ContraD
NullDiscriminator
false
13,745
[ "MIT" ]
168
abb72562ddac8d8ab37fe9af6ac4c44c61e8ea0f
https://github.com/HappyBelief/ContraD/tree/abb72562ddac8d8ab37fe9af6ac4c44c61e8ea0f
A2CActorDisc
import torch from torch.distributions import Categorical import torch as t import torch.nn as nn class A2CActorDisc(nn.Module): def __init__(self, state_dim, action_num): super().__init__() self.fc1 = nn.Linear(state_dim, 16) self.fc2 = nn.Linear(16, 16) self.fc3 = nn.Linear(16, a...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers from torch._inductor.runtime....
iffiX/machin
A2CActorDisc
false
15,589
[ "MIT" ]
287
7fa986b1bafdefff117d6ff73d14644a5488de9d
https://github.com/iffiX/machin/tree/7fa986b1bafdefff117d6ff73d14644a5488de9d
UpBlok
import torch import torch.nn as nn import torch.nn.functional as F class UpBlok(nn.Module): def __init__(self, in_channels, out_channels): super().__init__() self.conv1x1 = nn.Conv2d(in_channels, in_channels, kernel_size=1, stride=1, padding=0) self.conv3x3 = nn.Conv2d(in_chan...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers import torch.nn as nn assert_...
fendaq/TextRSN
UpBlok
false
6,684
[ "MIT" ]
1
02a6bc06cd64b581414ed5065a8c93e0c68a807a
https://github.com/fendaq/TextRSN/tree/02a6bc06cd64b581414ed5065a8c93e0c68a807a
CompressionFM
import torch class CompressionFM(torch.nn.Module): """ FM layer """ def __init__(self, input_size, fm_size): super(CompressionFM, self).__init__() self.LW = torch.nn.Linear(input_size, 1) self.QV = torch.nn.Parameter(torch.randn(input_size, fm_size)) def forward(self, inp...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream assert_size_stride = torch._C._dynamo.guards.assert_size_stride empty_strided_cu...
haophancs/TREQS
CompressionFM
false
15,498
[ "MIT" ]
149
49e354ce2a08cf963ec139d99936020e0f80ced8
https://github.com/haophancs/TREQS/tree/49e354ce2a08cf963ec139d99936020e0f80ced8
Sum
import torch import torch.nn as nn import torch.onnx class Sum(nn.Module): def __init__(self, n, weight=False): super().__init__() self.weight = weight self.iter = range(n - 1) if weight: self.w = nn.Parameter(-torch.arange(1.0, n) / 2, requires_grad=True ...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream import torch.nn as nn import torch.onnx assert_size_stride = torch._C._dynamo.guards.assert_size_stride empty_strided_cuda = torch._C._dynam...
DDGRCF/YOLOX_OBB
Sum
false
7,963
[ "Apache-2.0" ]
39
27b80953306492b8bc83b86b1353d8cee01ef9b6
https://github.com/DDGRCF/YOLOX_OBB/tree/27b80953306492b8bc83b86b1353d8cee01ef9b6
PredLayer
# AOT ID: ['0_inference'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _al...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream import torch.nn as nn assert_size_stride = torch._C._dynamo.guards.assert_size_stride empty_strided_cuda = torch._C._dynamo.guards._empty_st...
xlx0010/HGNN
PredLayer
false
4,583
[ "MIT" ]
0
219352405db021c1f435f3aa55961adcf2a6df19
https://github.com/xlx0010/HGNN/tree/219352405db021c1f435f3aa55961adcf2a6df19
AFMS
import torch import torch.nn as nn import torch.nn.functional as F class AFMS(nn.Module): """ Alpha-Feature map scaling, added to the output of each residual block[1,2]. Reference: [1] RawNet2 : https://www.isca-speech.org/archive/Interspeech_2020/pdfs/1011.pdf [2] AMFS : https://www.koreascie...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream import torch.nn as nn assert_size_stride = torch._C._dynamo.guards.assert_size_s...
hdubey/RawNet
AFMS
false
3,585
[ "MIT" ]
0
45589b2da9b0562ef2810e6097d4bdba23eb8a0a
https://github.com/hdubey/RawNet/tree/45589b2da9b0562ef2810e6097d4bdba23eb8a0a
Normalize3D
import torch import torch.nn as nn class Normalize3D(nn.Module): """ Scale Spectrogram to be between 0 and 1 """ def __init__(self): super(Normalize3D, self).__init__() def forward(self, X: 'torch.Tensor'): if len(X.shape) != 3: raise ValueError( 'Inp...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers import torch.nn as nn assert_size_stride = torch._C._dynamo.guards.assert_size_stride emp...
dariocazzani/vo-id
Normalize3D
false
1,787
[ "MIT" ]
0
41d0f2779e7909cfa15afcb6c8222c48a5855eb8
https://github.com/dariocazzani/vo-id/tree/41d0f2779e7909cfa15afcb6c8222c48a5855eb8
IndepAnisotropicGaussianUVLoss
import math import torch import torch.utils.data import torch.nn.functional as F from torch import nn class IndepAnisotropicGaussianUVLoss(nn.Module): """ Loss for the case of independent residuals with anisotropic covariances: $Sigma_i = sigma_i^2 I + r_i r_i^T$ The loss (negative log likelihood) is ...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers from torch._inductor.runtime.triton_helpers import libdevice, math as tl_math import math...
Magixxxxxx/detectron2
IndepAnisotropicGaussianUVLoss
false
2,640
[ "Apache-2.0" ]
0
c1ee8cf73777c96cc8a89463d0dca6e0ffe148f4
https://github.com/Magixxxxxx/detectron2/tree/c1ee8cf73777c96cc8a89463d0dca6e0ffe148f4
Actor
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers from torch._inductor.runtime....
Mika412/deep-reinforcement-learning
Actor
false
11,699
[ "MIT" ]
0
9b5ba901f760e50cd64d272939eff75881af5a9c
https://github.com/Mika412/deep-reinforcement-learning/tree/9b5ba901f760e50cd64d272939eff75881af5a9c
NTimesTanh
# AOT ID: ['0_inference'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _al...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime.triton_helpers import libdevice import torch.nn as nn assert_size_stride = torch._C._dynamo.guards.assert_size_...
liuzeyuMr/ELEGANT_cvte
NTimesTanh
false
3,923
[ "MIT" ]
0
eb8039310023f91e25e37ff8d907844afd50e0a5
https://github.com/liuzeyuMr/ELEGANT_cvte/tree/eb8039310023f91e25e37ff8d907844afd50e0a5
SigmoidRange
# AOT ID: ['0_inference'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _al...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch.nn import Module import functools import torch.nn as nn from typing import * assert_size_stride = torch._C._dynamo.guards.assert_...
davidpfahler/fastai_dev
SigmoidRange
false
10,053
[ "Apache-2.0" ]
0
a86b15f86138a9902e8649e3f745e76a19139ab3
https://github.com/davidpfahler/fastai_dev/tree/a86b15f86138a9902e8649e3f745e76a19139ab3
Block_MLP
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime.triton_helpers import libdevice import torch.nn as ...
yifanc96/yifanc-DL
Block_MLP
false
11,095
[ "MIT" ]
0
25d56cec776fb151c8f6bcbd997bca94f07f3597
https://github.com/yifanc96/yifanc-DL/tree/25d56cec776fb151c8f6bcbd997bca94f07f3597
SharpenedCosineSimilarity
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime.triton_helpers import libdevice, math as tl_math import torch.nn as nn import torch.nn.functional as F assert_s...
quickgrid/sharpened_cosine_similarity_torch
SharpenedCosineSimilarity
false
4,162
[ "MIT" ]
0
d652d76a4994a0b3817e248d5899827d35a5ebeb
https://github.com/quickgrid/sharpened_cosine_similarity_torch/tree/d652d76a4994a0b3817e248d5899827d35a5ebeb
ToRGB
from torch.autograd import Function import math import torch import torch.nn as nn from torch.nn import functional as F import torch.nn.parallel import torch.utils.data def make_kernel(k): k = torch.tensor(k, dtype=torch.float32) if k.ndim == 1: k = k[None, :] * k[:, None] k /= k.sum() return ...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch.autograd import Function import math import torch.nn as nn from torch...
kampta/multiview-shapes
ToRGB
false
3,799
[ "MIT" ]
0
a79eb4b492be8c2c279e2c69b13d5a19dff1621b
https://github.com/kampta/multiview-shapes/tree/a79eb4b492be8c2c279e2c69b13d5a19dff1621b
Attention
from _paritybench_helpers import _mock_config import math import torch import torch.nn as nn from torch.nn import Dropout from torch.nn import Softmax from torch.nn import Linear class Attention(nn.Module): def __init__(self, config): super(Attention, self).__init__() self.num_attention_heads = c...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers from torch._inductor.runtime....
LJOVO/TranSalNet
Attention
false
4,728
[ "MIT" ]
0
a2aba83e3b8f54c47b712511bf4f515f236326ed
https://github.com/LJOVO/TranSalNet/tree/a2aba83e3b8f54c47b712511bf4f515f236326ed
SqueezeInitBlock
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers import torch.utils.data impor...
HyperGAN/imgclsmob
SqueezeInitBlock
false
17,682
[ "MIT" ]
9
88b9776a5a927dc9a54e85e31978c4a9ec5ecbf3
https://github.com/HyperGAN/imgclsmob/tree/88b9776a5a927dc9a54e85e31978c4a9ec5ecbf3
Fire
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers import torch.nn as nn assert_...
ArronHZG/ABD-Net
Fire
false
9,590
[ "MIT" ]
0
4f6d15f4d389a55549ea10a2e00d4a5cdecb5753
https://github.com/ArronHZG/ABD-Net/tree/4f6d15f4d389a55549ea10a2e00d4a5cdecb5753
GateLayer
import torch from torch import nn class GateLayer(nn.Module): def __init__(self, input_dim): super(GateLayer, self).__init__() self._norm_layer1 = nn.Linear(input_dim * 2, input_dim) self._norm_layer2 = nn.Linear(input_dim, 1) def forward(self, input1, input2): norm_input = s...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch import nn assert_size_stride = torch._C._dynamo.guards.assert_size_st...
shubaoyu/CRSLab
GateLayer
false
10,818
[ "MIT" ]
0
a05730e8b2c03df278587be34923fa818945d4c4
https://github.com/shubaoyu/CRSLab/tree/a05730e8b2c03df278587be34923fa818945d4c4
AvgPool2d
from torch.nn import Module import torch import torch as th class AvgPool2d(Module): """ This class is the beginning of an exact python port of the torch.nn.AvgPool2d module. Because PySyft cannot hook into layers which are implemented in C++, our special functionalities (such as encrypted computation...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch.nn import Module assert_size_stride = torch._C._dynamo.guards.assert_size_stride empty_strided_cuda = torch._C._dynamo.guards._em...
abogaziah/PySyft
AvgPool2d
false
1,352
[ "Apache-2.0" ]
0
812dc6f350261793c67a928786fc081158f22a76
https://github.com/abogaziah/PySyft/tree/812dc6f350261793c67a928786fc081158f22a76
SelfAttention
# AOT ID: ['0_forward'] from ctypes import c_void_p, c_long, c_int import torch import math import random import os import tempfile from math import inf, nan from torch._inductor.hooks import run_intermediate_hooks from torch._inductor.utils import maybe_profile from torch._inductor.codegen.memory_planning import _alig...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers from torch._inductor.runtime....
jscarlson/zi2zi-pytorch
SelfAttention
false
15,755
[ "Apache-2.0" ]
81
3409165b304ccf1d5a5c2329a9f0f0897b3495dc
https://github.com/jscarlson/zi2zi-pytorch/tree/3409165b304ccf1d5a5c2329a9f0f0897b3495dc
ComputeDeltas
import torch from torch import Tensor import torchaudio.functional as F class ComputeDeltas(torch.nn.Module): """Compute delta coefficients of a tensor, usually a spectrogram. See `torchaudio.functional.compute_deltas` for more details. Args: win_length (int): The window length used for computin...
import torch from torch._inductor.select_algorithm import extern_kernels import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream assert_size_stride = torch._C._dynamo.guards.assert_size_stride empty_strided_cu...
Nayef211/audio
ComputeDeltas
false
11,738
[ "BSD-2-Clause" ]
0
241ab1e8284e589262f510ee9411baf2bc374ded
https://github.com/Nayef211/audio/tree/241ab1e8284e589262f510ee9411baf2bc374ded
BasicModel5_MultiArgs
import torch import torch.nn as nn import torch.nn.functional as F class BasicModel5_MultiArgs(nn.Module): """ Slightly modified example model from the paper https://arxiv.org/pdf/1703.01365.pdf f(x1, x2) = RELU(ReLU(x1 - 1) * x3[0] - ReLU(x2) * x3[1]) """ def __init__(self): ...
import torch import triton import triton.language as tl from torch._inductor.runtime.triton_heuristics import grid from torch._C import _cuda_getCurrentRawStream as get_raw_stream from torch._inductor.runtime import triton_helpers import torch.nn as nn assert_size_stride = torch._C._dynamo.guards.assert_size_stride emp...
ngduduong/captum
BasicModel5_MultiArgs
false
4,071
[ "BSD-3-Clause" ]
0
6fe5f0f23ea975e73e0c0dee79bdc01b4223d283
https://github.com/ngduduong/captum/tree/6fe5f0f23ea975e73e0c0dee79bdc01b4223d283