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
ContinuousCritic
# 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...
pjordan/rlcc
ContinuousCritic
false
7,481
[ "Apache-2.0" ]
1
e84b8b5c14680dbad2efae22756fb40606b2384a
https://github.com/pjordan/rlcc/tree/e84b8b5c14680dbad2efae22756fb40606b2384a
LocalFeatureEncoder
import torch import torch.nn as nn from abc import ABCMeta from torch.utils import model_zoo class BaseModule(nn.Module, metaclass=ABCMeta): @classmethod def load(cls, config, state_dict=None): model = cls.from_cfg(config) if model is not None and state_dict is not None: model.loa...
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 from abc import ABCMeta from torch.utils import model_zoo ...
Pooya448/leap
LocalFeatureEncoder
false
14,242
[ "BSD-3-Clause" ]
55
b0562baaaad1d4c0bcd514e020185c32a86faf23
https://github.com/Pooya448/leap/tree/b0562baaaad1d4c0bcd514e020185c32a86faf23
Classify
# 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.nn as nn assert_size_stride = torch._C._dynamo.guards.assert_size_s...
PoCInnovation/Koic
Classify
false
8,660
[ "MIT" ]
13
eca53b53b7242c1e83213ef9408366ca0a346358
https://github.com/PoCInnovation/Koic/tree/eca53b53b7242c1e83213ef9408366ca0a346358
ConvAE
import math import torch import torch.nn as nn import torch.nn.functional as F class Conv2dSamePad(nn.Module): """ Implement Tensorflow's 'SAME' padding mode in Conv2d. When an odd number, say `m`, of pixels are need to pad, Tensorflow will pad one more column at right or one more row at bottom. But P...
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 math import torch.nn a...
qilinli/DSC-Net
ConvAE
false
4,154
[ "MIT" ]
0
c0e7a3cae3e07c34b2989234f568c7007cf0fc55
https://github.com/qilinli/DSC-Net/tree/c0e7a3cae3e07c34b2989234f568c7007cf0fc55
Concat2d
import torch import torch.nn as nn import torch.nn.functional as F class Concat2d(nn.Module): def __init__(self): super(Concat2d, self).__init__() def forward(self, x_down, x_enc): if x_down.shape[-1] > x_enc.shape[-1]: p = (x_down.shape[-1] - x_enc.shape[-1]) // 2 if...
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...
rinkwitz/Thesis_Semantic_Image_Segmentation_on_Satellite_Imagery_using_UNets
Concat2d
false
7,552
[ "MIT" ]
1
75d3a4a536f6ef81fe0efd4f5fbba32b627a7472
https://github.com/rinkwitz/Thesis_Semantic_Image_Segmentation_on_Satellite_Imagery_using_UNets/tree/75d3a4a536f6ef81fe0efd4f5fbba32b627a7472
BasicModel_ConvNet_MaxPool3d
import torch import torch.nn as nn class BasicModel_ConvNet_MaxPool3d(nn.Module): """Same as above, but with the MaxPool1d replaced with a MaxPool3d. This is useful because the MaxPool modules behave differently to other modules from the perspective of the DeepLift Attributions """ def __init...
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....
Europium248/captum
BasicModel_ConvNet_MaxPool3d
false
441
[ "BSD-3-Clause" ]
0
ac02fae2651b8d68a44bcb9d03b91cbb3959f2fc
https://github.com/Europium248/captum/tree/ac02fae2651b8d68a44bcb9d03b91cbb3959f2fc
MixtureSynthesizers
import torch import torch.nn as nn class MixtureSynthesizers(nn.Module): def __init__(self, in_dims, sentence_length): super(MixtureSynthesizers, self).__init__() self.attention = nn.Parameter(torch.empty(1, sentence_length, sentence_length), requires_grad=True) nn.init.xavier...
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....
leaderj1001/Synthesizer-Rethinking-Self-Attention-Transformer-Models
MixtureSynthesizers
false
15,877
[ "MIT" ]
58
3ee5829438a8f9c063ae485e77c9ce7649d24139
https://github.com/leaderj1001/Synthesizer-Rethinking-Self-Attention-Transformer-Models/tree/3ee5829438a8f9c063ae485e77c9ce7649d24139
PredictionHead
import torch import torch.nn as nn import torch.nn.functional as F import torch.utils.data class PredictionHead(nn.Module): """ Simple classification prediction-head block to plug ontop of the 4D output of a CNN. Args: num_classes: the number of different classes that can be predicted. ...
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....
SheffieldAI/pykale
PredictionHead
false
14,398
[ "MIT" ]
324
be7670941fb06835883c80477b26702d407017db
https://github.com/SheffieldAI/pykale/tree/be7670941fb06835883c80477b26702d407017db
GlobalMaxPool1d
# 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 import nn assert_size_stride = torch._C._dynamo.guards.assert_size_stride empt...
liaoweiduo/few-shot
GlobalMaxPool1d
false
12,701
[ "MIT" ]
0
24d54fa3b472194b8cdab0ec6017bc5f649380a0
https://github.com/liaoweiduo/few-shot/tree/24d54fa3b472194b8cdab0ec6017bc5f649380a0
NodeAdaptiveEncoder
import torch import torch.utils.data import torch.nn as nn import torch.nn.functional as F class NodeAdaptiveEncoder(nn.Module): def __init__(self, num_features, dropout=0.5): super(NodeAdaptiveEncoder, self).__init__() self.fc = nn.Parameter(torch.zeros(size=(num_features, 1))) nn.init.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 import torch.utils.data import torch.nn as nn assert_size_stride = torch._C._dyn...
Brickser/cogdl
NodeAdaptiveEncoder
false
2,259
[ "MIT" ]
0
3952dd11075634cc0f3b669996cfc780635ce026
https://github.com/Brickser/cogdl/tree/3952dd11075634cc0f3b669996cfc780635ce026
Conv_Block_gn
import torch import torch.nn as nn from torch.autograd.variable import * class Conv_Block_gn(nn.Module): def __init__(self, in_channels, out_channels, kernel_size, groups, stride=1 ): super(Conv_Block_gn, self).__init__() self.conv = nn.Conv2d(in_channels, out_channels, kernel_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.triton_helpers import libdevice import torch.nn as ...
MRLoghmani/Separate_to_Adapt
Conv_Block_gn
false
5,580
[ "MIT" ]
1
09c734448aa22b3879186f59952d9fd596d4a1f8
https://github.com/MRLoghmani/Separate_to_Adapt/tree/09c734448aa22b3879186f59952d9fd596d4a1f8
EncoderImagePrecomp
# 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 numpy as np ...
BruceW91/CVSE
EncoderImagePrecomp
false
13,424
[ "MIT" ]
152
20fa1ff50d1dcb4a7b3799071fa78038e52db804
https://github.com/BruceW91/CVSE/tree/20fa1ff50d1dcb4a7b3799071fa78038e52db804
NTimesTanh
import torch import torch.nn as nn class NTimesTanh(nn.Module): def __init__(self, N): super(NTimesTanh, self).__init__() self.N = N self.tanh = nn.Tanh() def forward(self, x): return self.tanh(x) * self.N def get_inputs(): return [torch.rand([4, 4, 4, 4])] def get_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 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
LayerNorm32
# 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 assert_size_stride = torch._C._dynamo.guards.assert_size_...
AranKomat/Diff-DALLE
LayerNorm32
false
13,289
[ "MIT" ]
53
9418e98e97b599c5c65f16ee168fedf76a29095f
https://github.com/AranKomat/Diff-DALLE/tree/9418e98e97b599c5c65f16ee168fedf76a29095f
Pad_Pool
# 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...
Hullimulli/EEGEyeNet
Pad_Pool
false
560
[ "MIT" ]
0
677a791b39800f44dc254553b16ee2f92e62c423
https://github.com/Hullimulli/EEGEyeNet/tree/677a791b39800f44dc254553b16ee2f92e62c423
AddNorm
import torch from torch import nn class AddNorm(nn.Module): def __init__(self, normalized_shape, dropout, **kwargs): super(AddNorm, self).__init__(**kwargs) self.dropout = nn.Dropout(dropout) self.ln = nn.LayerNorm(normalized_shape) def forward(self, X, Y): return self.ln(sel...
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 assert_size_stride = torch._C._dynamo.guards.assert_size_s...
lucmertins/CapDeepLearningBook
AddNorm
false
12,760
[ "MIT" ]
0
e5959b552c8716e7fc65a21ae9c13c58509544c1
https://github.com/lucmertins/CapDeepLearningBook/tree/e5959b552c8716e7fc65a21ae9c13c58509544c1
Actor
import torch import numpy as np import torch.nn.functional as F import torch.nn as nn def hidden_init(layer): fan_in = layer.weight.data.size()[0] lim = 1.0 / np.sqrt(fan_in) return -lim, lim class Actor(nn.Module): """Actor (Policy) Model.""" def __init__(self, state_size, action_size, seed, f...
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
MultiHead
import math import torch from torch import nn from torch.nn import functional as F class Attention(nn.Module): def __init__(self, d_key, drop_ratio, causal): super(Attention, self).__init__() self.scale = math.sqrt(d_key) self.dropout = nn.Dropout(drop_ratio) self.causal = causal ...
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....
Adelashl6/mask_transformers
MultiHead
false
4,810
[ "MIT" ]
1
2a2e4d1b40ae3ed546cb850d041af246806b63e7
https://github.com/Adelashl6/mask_transformers/tree/2a2e4d1b40ae3ed546cb850d041af246806b63e7
_Residual_Block
import torch import torch.nn as nn class _Residual_Block(nn.Module): def __init__(self): super(_Residual_Block, self).__init__() self.conv1 = nn.Conv2d(in_channels=64, out_channels=64, kernel_size =3, stride=1, padding=1, bias=False) self.in1 = nn.InstanceNorm2d(64, affine=Tru...
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....
liruilong940607/SRResnet
_Residual_Block
false
7,118
[ "MIT" ]
1
928b1c076bfa051dffd5165ea966af5dfd9c372d
https://github.com/liruilong940607/SRResnet/tree/928b1c076bfa051dffd5165ea966af5dfd9c372d
FCUDown
# 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 ...
xuewengeophysics/Conformer
FCUDown
false
13,123
[ "Apache-2.0" ]
0
e769a1ac9ab110dae2a356a4de1e06ccd0e95041
https://github.com/xuewengeophysics/Conformer/tree/e769a1ac9ab110dae2a356a4de1e06ccd0e95041
CenteredLayer
# 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 import nn assert_size_stride = torch._C._dynamo.guards.assert_size_stride empt...
JamesWang007/Dive-into-DL-PyTorch
CenteredLayer
false
5,366
[ "Apache-2.0" ]
1
267b54168322ab37da44e83008fba4f24b70fa9f
https://github.com/JamesWang007/Dive-into-DL-PyTorch/tree/267b54168322ab37da44e83008fba4f24b70fa9f
GraphConv
# 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 ...
JiaxuanYou/graph-pooling
GraphConv
false
17,476
[ "MIT" ]
5
e6237f03a72ac55d8a10192ca36fa596973461f5
https://github.com/JiaxuanYou/graph-pooling/tree/e6237f03a72ac55d8a10192ca36fa596973461f5
DiceLoss
# 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 import nn import torch.hub assert_size_stride = torch._C._dynamo.guards.assert...
selimsef/xview2_solution
DiceLoss
false
16,378
[ "Apache-2.0" ]
57
5d0caba9c7a9c2707565a189f1a091c86d26b546
https://github.com/selimsef/xview2_solution/tree/5d0caba9c7a9c2707565a189f1a091c86d26b546
BertOutAttention
from _paritybench_helpers import _mock_config import math import torch import torch.nn as nn import torch.utils.data class BertOutAttention(nn.Module): def __init__(self, config, ctx_dim=None): super().__init__() if config.hidden_size % config.num_attention_heads != 0: raise ValueErro...
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....
ashutoshbaghel/tgifqa-lxmert
BertOutAttention
false
1,510
[ "MIT" ]
0
7969f478d20fbfbba1c0eaaf0b96891654bfcc26
https://github.com/ashutoshbaghel/tgifqa-lxmert/tree/7969f478d20fbfbba1c0eaaf0b96891654bfcc26
SqueezeInitBlock
import torch import torch.utils.data import torch.nn as nn class SqueezeInitBlock(nn.Module): """ SqueezeNet specific initial block. Parameters: ---------- in_channels : int Number of input channels. out_channels : int Number of output channels. kernel_size : int or tuple/...
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
FixupBasicBlock
import torch import torch as th import torch.utils.data import torch.nn as nn def _get_activation(activation): valid = ['relu', 'leaky_relu', 'lrelu', 'tanh', 'sigmoid'] assert activation in valid, 'activation should be one of {}'.format(valid) if activation == 'relu': return nn.ReLU(inplace=True)...
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 as th import tor...
sutkarsh/ttools
FixupBasicBlock
false
10,936
[ "MIT" ]
0
a2e5fbf308566c0c54ab9d6ad1d9f8bc63f8fe99
https://github.com/sutkarsh/ttools/tree/a2e5fbf308566c0c54ab9d6ad1d9f8bc63f8fe99
Relation
# 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...
ChenZhannnnn/chenzhan
Relation
false
13,481
[ "Apache-2.0" ]
45
b26a9512bbd1efe86c35c91a625da40b6f94dfc7
https://github.com/ChenZhannnnn/chenzhan/tree/b26a9512bbd1efe86c35c91a625da40b6f94dfc7
BilinearAttention
# 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....
CookiePPP/mellotron
BilinearAttention
false
9,064
[ "BSD-3-Clause" ]
0
488425981c19cd0eddddea13d1348da4bfef8d26
https://github.com/CookiePPP/mellotron/tree/488425981c19cd0eddddea13d1348da4bfef8d26
InvConvNear
import torch from torch.nn import functional as F from torch import nn import torch.utils.data import torch.optim class InvConvNear(nn.Module): def __init__(self, channels, n_split=4, no_jacobian=False, **kwargs): super().__init__() assert n_split % 2 == 0 self.channels = 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 import nn import torch.utils.data import torch.optim assert_size_stri...
Oktai15/NeMo
InvConvNear
false
5,683
[ "Apache-2.0" ]
1
5b6dd3850129898be47cf0d65587897ec45a5b59
https://github.com/Oktai15/NeMo/tree/5b6dd3850129898be47cf0d65587897ec45a5b59
ConvTemporalGraphical
# 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.nn as nn import torch._utils import torch.utils.data import torch.u...
fsImageries/video-to-pose3D
ConvTemporalGraphical
false
10,185
[ "MIT" ]
0
098c87ce19dc3331da03e6eac0b9744684eb66f6
https://github.com/fsImageries/video-to-pose3D/tree/098c87ce19dc3331da03e6eac0b9744684eb66f6
SinusoidRelativePositionalEmbedding
# 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, math as tl_math import torc...
yzhangcs/parser
SinusoidRelativePositionalEmbedding
false
16,791
[ "MIT" ]
439
3abebde1c9fe0bf2e99adce845aaf2a04b194f8a
https://github.com/yzhangcs/parser/tree/3abebde1c9fe0bf2e99adce845aaf2a04b194f8a
Mnist_CNN
# 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 ...
rgommers/tutorials
Mnist_CNN
false
16,333
[ "BSD-3-Clause" ]
6,424
9341570d4d8ed2c77371eac3b8520f7038d731ee
https://github.com/rgommers/tutorials/tree/9341570d4d8ed2c77371eac3b8520f7038d731ee
BiDAFAttention
import torch import torch.nn as nn import torch.nn.functional as F def masked_softmax(logits, mask, dim=-1, log_softmax=False): """Take the softmax of `logits` over given dimension, and set entries to 0 wherever `mask` is 0. Args: logits (torch.Tensor): Inputs to the softmax function. mas...
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....
HakobJak/ml-mipt
BiDAFAttention
false
13,746
[ "MIT" ]
440
ab0cbd5d553e9da309bda54d35b4e93a8eb99696
https://github.com/HakobJak/ml-mipt/tree/ab0cbd5d553e9da309bda54d35b4e93a8eb99696
TransformerSet
# 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....
Asichurter/MalFusionFSL
TransformerSet
false
16,992
[ "MIT" ]
4
713bf64cc07a3489f42941fd2299837075575ac0
https://github.com/Asichurter/MalFusionFSL/tree/713bf64cc07a3489f42941fd2299837075575ac0
Conv
# 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 ...
gorinars/VQ-VAE-Speech
Conv
false
6,755
[ "MIT" ]
1
60398f03eb129195bce402a423ace8cca8995f3c
https://github.com/gorinars/VQ-VAE-Speech/tree/60398f03eb129195bce402a423ace8cca8995f3c
GlobalLayerNorm
import torch import torch.nn as nn from itertools import product as product class GlobalLayerNorm(nn.Module): def __init__(self, channel_size): super(GlobalLayerNorm, self).__init__() self.gamma = nn.Parameter(torch.Tensor(1, channel_size, 1)) self.beta = nn.Parameter(torch.Tensor(1, chan...
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 itertools import product as product assert_size_stri...
slapshin/TalkNet_ASD
GlobalLayerNorm
false
4,356
[ "MIT" ]
0
343fac5c8d2bef2b98244e3acf20ac322711a4c7
https://github.com/slapshin/TalkNet_ASD/tree/343fac5c8d2bef2b98244e3acf20ac322711a4c7
IA_gate
# 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 ...
huanglf714/COMatchNet
IA_gate
false
6,821
[ "Apache-2.0" ]
1
79023f5be65d354eb9bdac026d7e0d73110bc4aa
https://github.com/huanglf714/COMatchNet/tree/79023f5be65d354eb9bdac026d7e0d73110bc4aa
Attention
import math import torch import torch.nn as nn import torch.nn.functional as F class Attention(nn.Module): def __init__(self, embed_dim, hidden_dim=None, out_dim=None, n_head=1, score_function='dot_product', dropout=0): """ Attention Mechanism :param embed_dim: :param hidden_dim: ...
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....
RaleLee/conv-emotion
Attention
false
11,802
[ "MIT" ]
0
1b07223cbdfd52eb31e913e982d18ff1ed3daf08
https://github.com/RaleLee/conv-emotion/tree/1b07223cbdfd52eb31e913e982d18ff1ed3daf08
GreedyHashLoss
# 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 math as tl_math assert_size_stride = t...
TuBui/deep_image_comparator
GreedyHashLoss
false
1,154
[ "MIT" ]
0
2dea7738d794b91a960ee9f41461a4e3ffcd5e44
https://github.com/TuBui/deep_image_comparator/tree/2dea7738d794b91a960ee9f41461a4e3ffcd5e44
PSNR
import torch import torch.utils.data from torch.nn.modules.loss import _Loss def normalize_reverse(x, centralize=False, normalize=False, val_range=255.0): if normalize: x = x * val_range if centralize: x = x + val_range / 2 return x class PSNR(_Loss): def __init__(self, centralize=F...
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.utils.data from...
YDDDDG/3D2Unet
PSNR
false
6,006
[ "MIT" ]
1
daca056958fb2ae319dc18a350e04b3cefe0d99f
https://github.com/YDDDDG/3D2Unet/tree/daca056958fb2ae319dc18a350e04b3cefe0d99f
EncoderImagePrecomp
import torch import numpy as np import torch.nn as nn import torch.nn.init from collections import OrderedDict def l2norm(X): """L2-normalize columns of X """ norm = torch.pow(X, 2).sum(dim=1, keepdim=True).sqrt() X = torch.div(X, norm) return X class EncoderImagePrecomp(nn.Module): def __i...
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 numpy as np ...
akurniawan/jina-hub
EncoderImagePrecomp
false
1,390
[ "Apache-2.0" ]
0
d89bc5e8f527f1212c3228a15775e222983c0087
https://github.com/akurniawan/jina-hub/tree/d89bc5e8f527f1212c3228a15775e222983c0087
DNN
from _paritybench_helpers import _mock_config import torch import torch.nn as nn import torch.nn.functional as F import torch.onnx class DNN(nn.Module): def __init__(self, config): super(DNN, self).__init__() self.fc1 = nn.Linear(784, int(config['hidden_layer1'])) self.dropout = nn.Dropou...
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....
AmberLJC/Fluid
DNN
false
8,769
[ "Apache-2.0" ]
12
85dee374eb2a1c96fecea83d5484ad83d1739e95
https://github.com/AmberLJC/Fluid/tree/85dee374eb2a1c96fecea83d5484ad83d1739e95
ToRGB
from torch.autograd import Function import torch from torch import nn from torch.nn import functional as F def make_kernel(k): k = torch.tensor(k, dtype=torch.float32) if k.ndim == 1: k = k[None, :] * k[:, None] k /= k.sum() return k def upfirdn2d_native(input, kernel, up_x, up_y, down_x, do...
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 from torch import nn from torch.nn import fu...
G-arj/StyleSwin
ToRGB
false
13,706
[ "MIT" ]
398
0c592b3334159613ebe4a33bd6c4ea042dac42d4
https://github.com/G-arj/StyleSwin/tree/0c592b3334159613ebe4a33bd6c4ea042dac42d4
CNN
# 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 ...
clapmyhands/cz4042
CNN
false
6,482
[ "MIT" ]
1
8869bacfb5a49566ae9fcce464187035093ed22d
https://github.com/clapmyhands/cz4042/tree/8869bacfb5a49566ae9fcce464187035093ed22d
AgentConvBlock
import torch import torch.nn as nn class AgentConvBlock(nn.Module): def __init__(self, nin, nout, ksize=3): super(AgentConvBlock, self).__init__() self.conv1 = nn.Conv2d(nin, nout, ksize, padding=1) self.lrelu1 = nn.LeakyReLU(0.2) self.conv2 = nn.Conv2d(nout, nout, ksize, 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 import torch.nn as nn assert_size_stride = torch._C._dynamo.guards.assert_size_s...
JoOkuma/DifferentiableSketching
AgentConvBlock
false
668
[ "BSD-3-Clause" ]
0
6672508bd362d90e9bfc07966cb7907879d01385
https://github.com/JoOkuma/DifferentiableSketching/tree/6672508bd362d90e9bfc07966cb7907879d01385
CNN
# 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 import nn assert_s...
AxelBohm/cleverhans
CNN
false
4,899
[ "MIT" ]
1
35f44d686fa24a8d3a30218dc9ad2617859afbf0
https://github.com/AxelBohm/cleverhans/tree/35f44d686fa24a8d3a30218dc9ad2617859afbf0
MeanStd
# 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...
GiangHLe/pytorch_GAN_zoo
MeanStd
false
11,474
[ "BSD-3-Clause" ]
0
7a3db2a88032f357b3f262abd6204b560caa9f2c
https://github.com/GiangHLe/pytorch_GAN_zoo/tree/7a3db2a88032f357b3f262abd6204b560caa9f2c
DumbFeat
from _paritybench_helpers import _mock_config import torch import torch.nn as nn import torch.optim import torch.nn.parallel class DumbFeat(nn.Module): def __init__(self, opt): super(DumbFeat, self).__init__() dropout = opt['dropout'] if 'dropout' in opt else 0.0 self.dropout = torch.nn.D...
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.optim import torch.nn.parallel assert_size_stride = torch._C._dynamo.guards.assert_size_stride empty_stri...
Basasuya/FewShotWithoutForgetting
DumbFeat
false
3,496
[ "MIT" ]
0
eecc70e416ed82999124ddfca1b145f6dbcd74a6
https://github.com/Basasuya/FewShotWithoutForgetting/tree/eecc70e416ed82999124ddfca1b145f6dbcd74a6
Readout
# 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 torch.utils.data assert_size_stride = torch._C._dynamo.guards.assert_size_stride empty_strided_cuda = tor...
LichenYang-Jeffrey/GAT-for-COVID-19
Readout
false
5,520
[ "MIT" ]
1
91cc6048f14856f3ef9dfebf2db45e2a36975159
https://github.com/LichenYang-Jeffrey/GAT-for-COVID-19/tree/91cc6048f14856f3ef9dfebf2db45e2a36975159
Autoencoder
import torch import torch.nn as nn import torch.nn.functional as F import torch.utils.data class Autoencoder(nn.Module): def __init__(self): super(Autoencoder, self).__init__() self.conv1 = nn.Conv2d(3, 6, padding=2, kernel_size=5) self.maxpool1 = nn.MaxPool2d(4, stride=1, return_indices=...
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 ...
aoxolotl/slr
Autoencoder
false
6,259
[ "MIT" ]
1
20a4a9036f2dc3a61745072f89b0f5bb1cc51e1b
https://github.com/aoxolotl/slr/tree/20a4a9036f2dc3a61745072f89b0f5bb1cc51e1b
ConvMeanPool
import torch import torch.nn.functional as F import torch.nn as nn def l2normalize(v, esp=1e-08): return v / (v.norm() + esp) def sn_weight(weight, u, height, n_power_iterations): weight.requires_grad_(False) for _ in range(n_power_iterations): v = l2normalize(torch.mv(weight.view(height, -1).t(...
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.functional as F import torch.nn as nn assert_size_stride = torch...
tsirif/cortex
ConvMeanPool
false
16,627
[ "BSD-3-Clause" ]
109
2837b220f9fb73279df3815bb18b274106412c08
https://github.com/tsirif/cortex/tree/2837b220f9fb73279df3815bb18b274106412c08
conv_head_pooling
# 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.nn as nn assert_size_stride = torch._C._dynamo.guards.assert_size_s...
Equationliu/GA-Attack
conv_head_pooling
false
17,263
[ "MIT" ]
8
b0280674a211f6451774ec6b1d4cee2fc19a4de6
https://github.com/Equationliu/GA-Attack/tree/b0280674a211f6451774ec6b1d4cee2fc19a4de6
Attention
# 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....
IvanFei/video_captioning_rl
Attention
false
8,815
[ "MIT" ]
41
85ffa1abc056bd0ecfd35d1b52aed81d2f04afef
https://github.com/IvanFei/video_captioning_rl/tree/85ffa1abc056bd0ecfd35d1b52aed81d2f04afef
MultiHeadAttention
# 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....
azahed98/mellotron
MultiHeadAttention
false
1,534
[ "BSD-3-Clause" ]
0
02998743de820e379e0c7ff44506088d6e65c693
https://github.com/azahed98/mellotron/tree/02998743de820e379e0c7ff44506088d6e65c693
CenterIntersection
import torch import torch.nn as nn import torch.nn.functional as F class CenterIntersection(nn.Module): def __init__(self, dim): super(CenterIntersection, self).__init__() self.dim = dim self.layer1 = nn.Linear(self.dim, self.dim) self.layer2 = nn.Linear(self.dim, self.dim) ...
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....
amayuelas/NNKGReasoning
CenterIntersection
false
6,184
[ "MIT" ]
1
0e3623b344fd4e3088ece897f898ddbb1f80888d
https://github.com/amayuelas/NNKGReasoning/tree/0e3623b344fd4e3088ece897f898ddbb1f80888d
Mean
import torch import torch.nn as nn import torch.nn.parallel import torch.optim import torch.utils.data from torch.optim.lr_scheduler import * import torch.optim.lr_scheduler import torch.quantization import torch.onnx import torch.testing class Mean(nn.Module): def __init__(self, *args, **kwargs): super(...
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.nn.parallel import torch.optim import torch.utils.data...
Donfa1con/distiller
Mean
false
11,526
[ "Apache-2.0" ]
0
645ee41bfebc463523b228ff087e41619607d8b2
https://github.com/Donfa1con/distiller/tree/645ee41bfebc463523b228ff087e41619607d8b2
VdLinear
# 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...
Neronjust2017/Bayesian-neural-networks
VdLinear
false
17,763
[ "MIT" ]
4
9d7f781f5c2dfa8fadf26300b4b5b64366c939cd
https://github.com/Neronjust2017/Bayesian-neural-networks/tree/9d7f781f5c2dfa8fadf26300b4b5b64366c939cd
GlobalMaxPool1d
import torch from torch import nn class GlobalMaxPool1d(nn.Module): """Performs global max pooling over the entire length of a batched 1D tensor # Arguments input: Input tensor """ def forward(self, input): return nn.functional.max_pool1d(input, kernel_size=input.size()[2:] ...
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 import nn assert_size_stride = torch._C._dynamo.guards.assert_size_stride empt...
aiswaryasankar/Few_shot_exp
GlobalMaxPool1d
false
1,382
[ "MIT" ]
0
21c5a5d93dc69715b037a0fd2dca1b6f7d9de773
https://github.com/aiswaryasankar/Few_shot_exp/tree/21c5a5d93dc69715b037a0fd2dca1b6f7d9de773
PyTorchMLP
# 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_...
danvran/ASM
PyTorchMLP
false
9,955
[ "MIT" ]
0
e678fa507f847ec2ff947ec4ca123858ffe46d4d
https://github.com/danvran/ASM/tree/e678fa507f847ec2ff947ec4ca123858ffe46d4d
ParamSum
import torch import torch.utils.data import torch from torch import nn def resize(x1, x2, largest=True): if largest: if x1.size()[2:] > x2.size()[2:]: x2 = nn.Upsample(size=x1.size()[2:], mode='bilinear')(x2) elif x1.size()[2:] < x2.size()[2:]: x1 = nn.Upsample(size=x2.size...
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 import torch from torch import nn assert_size_stride = torch._C._dynamo.guards.assert_size_stride empty_strided_cuda...
DominickZhang/NAS-FCOS
ParamSum
false
13,586
[ "BSD-2-Clause" ]
187
1f7281478430eaed028e2cc2dfa8be226c63939b
https://github.com/DominickZhang/NAS-FCOS/tree/1f7281478430eaed028e2cc2dfa8be226c63939b
RandomShiftsAug
import torch import torch.nn as nn import torch.nn.functional as F class RandomShiftsAug(nn.Module): def __init__(self, pad): super().__init__() self.pad = pad def forward(self, x): x = x.float() n, _c, h, w = x.size() assert h == w padding = tuple([self.pad] ...
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._inductor.runtime.triton_helpers import libdevice import torch.nn as nn assert_size_stride = torch._C._d...
MishaLaskin/url_benchmark
RandomShiftsAug
false
5,614
[ "MIT" ]
1
a81aed0a0aec3a7dad83d930e54d480f97cf535d
https://github.com/MishaLaskin/url_benchmark/tree/a81aed0a0aec3a7dad83d930e54d480f97cf535d
LayerNormChan
# 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 assert_size_stride = torch._C._dynamo.guards.assert_size_s...
lucidrains/nuwa-pytorch
LayerNormChan
false
15,968
[ "MIT" ]
310
bf1f3dc1126ba0a24a280bd7412a8082e5013b46
https://github.com/lucidrains/nuwa-pytorch/tree/bf1f3dc1126ba0a24a280bd7412a8082e5013b46
MAB
# 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....
ernoult/set_transformer
MAB
false
12,359
[ "MIT" ]
0
4b380106e1f43b7eb6315624c57d4d1d38737b78
https://github.com/ernoult/set_transformer/tree/4b380106e1f43b7eb6315624c57d4d1d38737b78
SMAPELoss
# 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 math as tl_math import torch.nn as nn ...
LongerVision/oidn
SMAPELoss
false
5,556
[ "Apache-2.0" ]
1
2f9e59f8b747b217f78c5c274f4f2bff347a03a7
https://github.com/LongerVision/oidn/tree/2f9e59f8b747b217f78c5c274f4f2bff347a03a7
FeatureCorrelation
# 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 assert_size_stride = torch._C._dynamo.guards.assert_size_s...
tommy90191/Find_Tiny_but_Important_Image_Changes
FeatureCorrelation
false
4,447
[ "MIT" ]
0
429d679606f96f32db4cddf167a9cfb963d3df26
https://github.com/tommy90191/Find_Tiny_but_Important_Image_Changes/tree/429d679606f96f32db4cddf167a9cfb963d3df26
MSELoss
# 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...
KAGRA-TW-ML/deepclean-prod
MSELoss
false
11,594
[ "MIT" ]
0
9fb834cb4027fd3b377bc0e763c237235c98eabd
https://github.com/KAGRA-TW-ML/deepclean-prod/tree/9fb834cb4027fd3b377bc0e763c237235c98eabd
MobileNetV3Classifier
import torch import torch.utils.data import torch.nn as nn import torch.nn.functional as F def conv1x1(in_channels, out_channels, stride=1, groups=1, bias=False): """ Convolution 1x1 layer. Parameters: ---------- in_channels : int Number of input channels. out_channels : int N...
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
MobileNetV3Classifier
false
17,678
[ "MIT" ]
9
88b9776a5a927dc9a54e85e31978c4a9ec5ecbf3
https://github.com/HyperGAN/imgclsmob/tree/88b9776a5a927dc9a54e85e31978c4a9ec5ecbf3
DiceCE_Loss
import torch from torch import nn from torch.nn import functional as F from torch import sigmoid class DiceCE_Loss(nn.Module): """ Taken from https://www.kaggle.com/bigironsphere/loss-function-library-keras-pytorch """ def __init__(self, weight=None, size_average=True): super(DiceCE_Loss, sel...
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 from torch ...
JoaoCarv/holistic_seg
DiceCE_Loss
false
677
[ "MIT" ]
0
ea4787e7e9a36dc5caf198d2be1bd1e71c06d440
https://github.com/JoaoCarv/holistic_seg/tree/ea4787e7e9a36dc5caf198d2be1bd1e71c06d440
VertexDirectEmbedder
# 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 import triton_helpers from torch._inductor.runtime.triton_helpers import libdevice import torch.utils.data from...
AbirKhan96/facebook-detectron2
VertexDirectEmbedder
false
16,860
[ "Apache-2.0" ]
5
6a3bf813353d74bbeb8674e3566e7bbb33eb5c87
https://github.com/AbirKhan96/facebook-detectron2/tree/6a3bf813353d74bbeb8674e3566e7bbb33eb5c87
GEGLU
import torch import torch.nn as nn import torch.nn.functional as F class GEGLU(nn.Module): def forward(self, x): x, gate = x.chunk(2, dim=-1) return F.gelu(gate) * x def get_inputs(): return [torch.rand([4, 4, 4, 4])] def get_init_inputs(): return [[], {}]
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_...
DannielSilva/MMBERT
GEGLU
false
17,199
[ "MIT" ]
4
2c9069b59b66b8f3fec6de2e68ec42b489a3a437
https://github.com/DannielSilva/MMBERT/tree/2c9069b59b66b8f3fec6de2e68ec42b489a3a437
ConstantODE
import torch class ConstantODE(torch.nn.Module): def __init__(self, device): super(ConstantODE, self).__init__() self.a = torch.nn.Parameter(torch.tensor(0.2)) self.b = torch.nn.Parameter(torch.tensor(3.0)) def forward(self, t, y): return self.a + (y - (self.a * t + self.b)) ...
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 assert_size_stride = torch._C._dynamo.guards.assert_size_stride empty_strided_cuda = torch._C._dynamo.guards._empty_strided_cuda @triton.j...
arnabgho/torchdiffeq
ConstantODE
false
3,201
[ "MIT" ]
0
d4f73440d0e714b87ea133610e61eefbd673e5f5
https://github.com/arnabgho/torchdiffeq/tree/d4f73440d0e714b87ea133610e61eefbd673e5f5
Exp
import torch class Exp(torch.nn.Module): def forward(self, x): return (-0.5 * x ** 2).exp() def get_inputs(): return [torch.rand([4, 4, 4, 4])] def get_init_inputs(): return [[], {}]
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 assert_size_stride = torch._C._dynamo.guards.assert_size_stride empty_str...
Praneethsv/prob_mbrl
Exp
false
14,230
[ "MIT" ]
108
7b1adee6bff742b6f90e9b96ea243f12c9153b9b
https://github.com/Praneethsv/prob_mbrl/tree/7b1adee6bff742b6f90e9b96ea243f12c9153b9b
AvgPool2d
# 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...
DoggyLiu0116/MamboNet
AvgPool2d
false
5,084
[ "MIT" ]
1
3b708091422491f660c4bd5eb12b06ce3b8a5f79
https://github.com/DoggyLiu0116/MamboNet/tree/3b708091422491f660c4bd5eb12b06ce3b8a5f79
Network
# 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_...
MarcoPerdomo/Self-Automated-Driving_Car
Network
false
11,690
[ "MIT" ]
0
943bf53a8b0dd26f8370b943d879e7dbaadb2201
https://github.com/MarcoPerdomo/Self-Automated-Driving_Car/tree/943bf53a8b0dd26f8370b943d879e7dbaadb2201
InstanceNormFC
import torch from torch import nn class InstanceNormFC(nn.Module): def __init__(self, _unused=0, affine=True): super().__init__() self.norm = nn.InstanceNorm1d(1, affine=affine) def forward(self, x): return self.norm(x.unsqueeze(1)).squeeze(1) def get_inputs(): return [torch.ra...
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 assert_size_stride = torch._C._dynamo.guards.assert_size_s...
ankitkv/pylego
InstanceNormFC
false
18,333
[ "MIT" ]
4
38d4a8fe8497d748b22c58313cbfd187efb8326e
https://github.com/ankitkv/pylego/tree/38d4a8fe8497d748b22c58313cbfd187efb8326e
Generator
import torch import torch.optim.lr_scheduler import torch.nn as nn import torch.optim import torch.onnx.operators def masked_softmax(vector: 'torch.Tensor', mask: 'torch.Tensor', dim: 'int' =-1, memory_efficient: 'bool'=False, mask_fill_value: 'float'=-1e+32 ) ->torch.Tensor: """ ``torch.nn.functional...
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....
LogIntelligence/LogADEmpirical
Generator
false
8,478
[ "MIT" ]
11
48458aee65c1c84466b04dd4092fae79a7f341fd
https://github.com/LogIntelligence/LogADEmpirical/tree/48458aee65c1c84466b04dd4092fae79a7f341fd
Conv2dWithConstraint
# 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...
sylvchev/braindecode
Conv2dWithConstraint
false
16,514
[ "BSD-3-Clause" ]
260
c37ace8fcb90eee0d447c97d1c0a06ce58e8f6ad
https://github.com/sylvchev/braindecode/tree/c37ace8fcb90eee0d447c97d1c0a06ce58e8f6ad
Decoder
import math import torch from torch import nn def overlap_and_add(signal, frame_step): outer_dimensions = signal.size()[:-2] frames, frame_length = signal.size()[-2:] subframe_length = math.gcd(frame_length, frame_step) subframe_step = frame_step // subframe_length subframes_per_frame = frame_leng...
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 math from torch import nn assert_size_stride = torch._C._dynamo.guards.as...
roger-tseng/demucs
Decoder
false
12,947
[ "MIT" ]
0
4a54a3c523a86345df294798994b60c8194e0a43
https://github.com/roger-tseng/demucs/tree/4a54a3c523a86345df294798994b60c8194e0a43
MarginLoss
# 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.nn import Module from torch.nn import MarginRankingLoss assert_size_stride = t...
MacOS/torchkge
MarginLoss
false
13,997
[ "BSD-3-Clause" ]
248
89ed724368f3a5279c0f79c6ba1f948ed2a5696f
https://github.com/MacOS/torchkge/tree/89ed724368f3a5279c0f79c6ba1f948ed2a5696f
BilinearAttention
# 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....
AstraliteHeart/cookietts
BilinearAttention
false
7,759
[ "BSD-3-Clause" ]
25
c871f5f7b5790656d5b57bcd9e63946a2da52f0f
https://github.com/AstraliteHeart/cookietts/tree/c871f5f7b5790656d5b57bcd9e63946a2da52f0f
D_UpBlock
import torch import torch.utils.data from torchvision.transforms import * class ConvBlock(torch.nn.Module): def __init__(self, input_size, output_size, kernel_size=3, stride=1, padding=1, bias=True, activation='prelu', norm=None): super(ConvBlock, self).__init__() self.conv = torch.nn.Con...
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.data from torchvision.transforms import * assert_size_stride ...
RyanMoussouni/iSeeBetter
D_UpBlock
false
14,394
[ "MIT" ]
327
af193ae0852f8e477fcd6875dce874eb5092a24a
https://github.com/RyanMoussouni/iSeeBetter/tree/af193ae0852f8e477fcd6875dce874eb5092a24a
DepthLogLoss
# 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 math as tl_math import torch.nn as nn ...
pystokes/depth_estimation
DepthLogLoss
false
4,140
[ "MIT" ]
0
b5b1955bcb5b3f1a1f1c8ddde45431cf38514f90
https://github.com/pystokes/depth_estimation/tree/b5b1955bcb5b3f1a1f1c8ddde45431cf38514f90
Conv2dBlock
import torch from torch import nn import torch.nn.functional as F class AdaptiveInstanceNorm2d(nn.Module): def __init__(self, num_features, eps=1e-05, momentum=0.1): super(AdaptiveInstanceNorm2d, self).__init__() self.num_features = num_features self.eps = eps self.momentum = mome...
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...
PredatorK9/GANwriting
Conv2dBlock
false
9,420
[ "MIT" ]
0
246d7e87152c98f0c6af999d619dc51190fad8ae
https://github.com/PredatorK9/GANwriting/tree/246d7e87152c98f0c6af999d619dc51190fad8ae
PositionwiseFeedForward
import math import torch import torch.nn as nn import torch.cuda import torch.distributed def get_activation_fn(activation): """Return an activation function Module according to its name.""" if activation == 'gelu': fn = GELU() elif activation == 'relu': fn = nn.ReLU() elif activation ...
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....
SivilTaram/dialogue-utterance-rewriter-pytorch
PositionwiseFeedForward
false
2,927
[ "MIT" ]
0
92c2254958b7a1ee9199836f7f2236575270983f
https://github.com/SivilTaram/dialogue-utterance-rewriter-pytorch/tree/92c2254958b7a1ee9199836f7f2236575270983f
T5LayerNorm
import torch import torch.nn as nn import torch.utils.checkpoint class T5LayerNorm(nn.Module): def __init__(self, hidden_size, eps=1e-06): """ Construct a layernorm module in the T5 style No bias and no subtraction of mean. """ super().__init__() self.weight = nn.Parameter...
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.checkpoint assert_size_stride = torch....
Elvisambition/bert_seq2seq
T5LayerNorm
false
5,167
[ "Apache-2.0" ]
1
643ac537c16872f0d13200de06001d8201a54fbb
https://github.com/Elvisambition/bert_seq2seq/tree/643ac537c16872f0d13200de06001d8201a54fbb
Model
# 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 import nn assert_s...
Event0511/curling-reid
Model
false
17,561
[ "Apache-2.0" ]
3
1494d0faeed951e495573c694362f001df5bf6fd
https://github.com/Event0511/curling-reid/tree/1494d0faeed951e495573c694362f001df5bf6fd
PcamPool
import torch from torch import nn class PcamPool(nn.Module): def __init__(self): super(PcamPool, self).__init__() def forward(self, feat_map, logit_map): assert logit_map is not None prob_map = torch.sigmoid(logit_map) weight_map = prob_map / prob_map.sum(dim=2, keepdim=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 from torch import nn assert_size_stride = torch._C._dynamo.guards.assert_size_stride empty_strided_cuda = torch._C._dynamo.guards._empty_str...
Tarandro/Chexpert
PcamPool
false
11,925
[ "Apache-2.0" ]
0
6bc51f899a479f8dbad8a64c92f35ed4632377b3
https://github.com/Tarandro/Chexpert/tree/6bc51f899a479f8dbad8a64c92f35ed4632377b3
GeM
# 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 import triton_helpers from torch._inductor.runtime.triton_helpers import libdevice import torch.nn.functional a...
Fkaneko/kaggle_g2net_gravitational_wave_detection-
GeM
false
478
[ "Apache-2.0" ]
0
8bb32cc675e6b56171da8a3754fffeda41e934bb
https://github.com/Fkaneko/kaggle_g2net_gravitational_wave_detection-/tree/8bb32cc675e6b56171da8a3754fffeda41e934bb
ActorDeep
import torch import torch.nn as nn import torch.nn.functional as F class ActorDeep(nn.Module): def __init__(self, state_dim, action_dim, max_action): super(ActorDeep, self).__init__() self.l1 = nn.Linear(state_dim, 300) self.l2 = nn.Linear(300, 300) self.l3 = nn.Linear(300, 300) ...
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....
KuangenZhang/StructuredRL
ActorDeep
false
5,465
[ "MIT" ]
1
9b05e5034ff0e045aabf83786efb0859f08e989a
https://github.com/KuangenZhang/StructuredRL/tree/9b05e5034ff0e045aabf83786efb0859f08e989a
GaussianFocalLoss
import functools import torch import torch.nn.functional as F import torch.nn as nn def reduce_loss(loss, reduction): """Reduce loss as specified. Args: loss (Tensor): Elementwise loss tensor. reduction (str): Options are "none", "mean" and "sum". Return: Tensor: Reduced loss ten...
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 functools impor...
Huuush/deepfashion2-det
GaussianFocalLoss
false
11,487
[ "Apache-2.0" ]
0
46af0ada8d6f534de2de6a9c069580cd1bf609ec
https://github.com/Huuush/deepfashion2-det/tree/46af0ada8d6f534de2de6a9c069580cd1bf609ec
TensorPermute
# 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_...
SheffieldAI/pykale
TensorPermute
false
14,397
[ "MIT" ]
324
be7670941fb06835883c80477b26702d407017db
https://github.com/SheffieldAI/pykale/tree/be7670941fb06835883c80477b26702d407017db
TripletLoss
import torch import torch.nn as nn import torch.nn.functional as F import torchvision.transforms.functional as F import torch.utils.data def hard_examples_mining(dist_mat, identity_mat, return_idxes=False): """Select hard positives and hard negatives according to `In defense of the Triplet Loss for Person Re-...
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....
neka-nat/Transfer-Learning-Library
TripletLoss
false
16,158
[ "MIT" ]
1,474
a3b27b0d7562fa90a02e914140b37ab438469e6c
https://github.com/neka-nat/Transfer-Learning-Library/tree/a3b27b0d7562fa90a02e914140b37ab438469e6c
AdaptiveFeatureNorm
import torch import torch.nn as nn import torch.utils.data class AdaptiveFeatureNorm(nn.Module): """ The `Stepwise Adaptive Feature Norm loss (ICCV 2019) <https://arxiv.org/pdf/1811.07456v2.pdf>`_ Instead of using restrictive scalar R to match the corresponding feature norm, Stepwise Adaptive Feature Nor...
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...
neka-nat/Transfer-Learning-Library
AdaptiveFeatureNorm
false
16,136
[ "MIT" ]
1,474
a3b27b0d7562fa90a02e914140b37ab438469e6c
https://github.com/neka-nat/Transfer-Learning-Library/tree/a3b27b0d7562fa90a02e914140b37ab438469e6c
RC
import torch import torch.nn as nn import torch.nn.functional as F class RC(nn.Module): """ A wrapper class for ReflectionPad2d, Conv2d and an optional relu """ def __init__(self, in_dim, out_dim, kernel_size=3, padding=1, activation_function=True): super().__init__() self.pad...
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....
benningtonlee7/AdaIn_Style_Transfer_From_Scratch_In_Pytorch
RC
false
6,332
[ "MIT" ]
1
50dfe4bdcbcdd0f4e647f9ee45de2a3f81eb6722
https://github.com/benningtonlee7/AdaIn_Style_Transfer_From_Scratch_In_Pytorch/tree/50dfe4bdcbcdd0f4e647f9ee45de2a3f81eb6722
SimpleSoftmaxModel
import torch import torch.jit import torch.nn.functional as F import torch.onnx import torch.nn class SimpleSoftmaxModel(torch.nn.Module): def __init__(self, dimension): super(SimpleSoftmaxModel, self).__init__() self.dimension = dimension def forward(self, tensor): return F.softmax(...
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.jit impor...
YaronBenAtar/glow
SimpleSoftmaxModel
false
14,683
[ "Apache-2.0" ]
2,838
a13706a4239fa7eaf059c670dc573e3eb0768f86
https://github.com/YaronBenAtar/glow/tree/a13706a4239fa7eaf059c670dc573e3eb0768f86
BoxOffsetIntersection
# 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_...
amayuelas/NNKGReasoning
BoxOffsetIntersection
false
6,181
[ "MIT" ]
1
0e3623b344fd4e3088ece897f898ddbb1f80888d
https://github.com/amayuelas/NNKGReasoning/tree/0e3623b344fd4e3088ece897f898ddbb1f80888d
ResBlock3d
# 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...
ldlasso2/hologan-pytorch
ResBlock3d
false
15,880
[ "BSD-3-Clause" ]
61
baec67d3673cc68e51434516d19465f3d6dd0a1b
https://github.com/ldlasso2/hologan-pytorch/tree/baec67d3673cc68e51434516d19465f3d6dd0a1b
Edg_Capture
# 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 assert_size_stride = torch._C._dynamo.guards.assert_size_s...
TaoWangzj/PCFAN
Edg_Capture
false
17,991
[ "MIT" ]
7
f6ddc8fd2e72a45431891acf0b25135499c84485
https://github.com/TaoWangzj/PCFAN/tree/f6ddc8fd2e72a45431891acf0b25135499c84485
MLP
import torch import torch.nn as nn import torch.utils.data class MLP(nn.Module): def __init__(self, input_size, output_size, hidden_size=500, weight_decay=0.0): super(MLP, self).__init__() self.i2h = nn.Linear(in_features=input_size, out_features=hidden_size) self.Dropout = nn.Dro...
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 ...
gchrupala/platalea
MLP
false
6,728
[ "Apache-2.0" ]
1
65833307bb6c5ad6cbdd6b17ad8ca59cf51fcd81
https://github.com/gchrupala/platalea/tree/65833307bb6c5ad6cbdd6b17ad8ca59cf51fcd81
InstanceNorm
# 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.nn import Module from torch import nn import torch.utils.data import...
Hadryan/nn
InstanceNorm
false
9,366
[ "MIT" ]
0
b10e3dea2c7e1f6569bfdf8e1a48f8d48b5a645d
https://github.com/Hadryan/nn/tree/b10e3dea2c7e1f6569bfdf8e1a48f8d48b5a645d