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
LabelPropagation
# 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 from torch._inductor.runtime import triton_helpers import torch.nn as nn assert_...
EdisonLeeeee/GraphGallery
LabelPropagation
false
13,658
[ "MIT" ]
300
4eec9c5136bda14809bd22584b26cc346cdb633b
https://github.com/EdisonLeeeee/GraphGallery/tree/4eec9c5136bda14809bd22584b26cc346cdb633b
Backbone
import torch class Backbone(torch.nn.Module): def __init__(self, input_size=4, hidden_size=10, latent_size=2): super().__init__() self.input_size = input_size self.hidden_size = hidden_size self.latent_size = latent_size self.dense1 = torch.nn.Linear(self.input_size, self....
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...
dmoebius-dm/prototorch_models
Backbone
false
3,435
[ "MIT" ]
0
71602bf38a09148eab13d98c9f89589b345ac570
https://github.com/dmoebius-dm/prototorch_models/tree/71602bf38a09148eab13d98c9f89589b345ac570
PositionalEncoding
import math import torch class PositionalEncoding(torch.nn.Module): """ Positional encoding for Transformer Parameters ---------- hidden_size : `int`, required Hidden size of positional encoding. Must match hidden size of input tokens. dropout : `float`, required Dropo...
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 math assert_size_stride = torch._C._dynamo.guards.assert_size_stride empty_strided_cuda = torch._C._dynamo.guards._empty_strided_cuda...
Nemexur/nonauto-lm
PositionalEncoding
false
17,750
[ "Apache-2.0" ]
3
6f237e4fc2b3b679cd92126ea5facd58d3cf6e75
https://github.com/Nemexur/nonauto-lm/tree/6f237e4fc2b3b679cd92126ea5facd58d3cf6e75
ExtendedModel
# 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_...
sauyon/BentoML
ExtendedModel
false
4,282
[ "Apache-2.0" ]
0
ff702f1fc1ee7cc4cf7aab2e67d1e27512858fe4
https://github.com/sauyon/BentoML/tree/ff702f1fc1ee7cc4cf7aab2e67d1e27512858fe4
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....
PaulPan00/donkey_wrapper
Actor
false
17,831
[ "MIT" ]
6
a03cf0f42f65625fbce792b06c98acd153c5d6c8
https://github.com/PaulPan00/donkey_wrapper/tree/a03cf0f42f65625fbce792b06c98acd153c5d6c8
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 import torch.nn as nn assert_size_stride = torch._C._dynamo.guards.assert_size_stride emp...
salem-devloper/COVID-Lung-Segment
DiceLoss
false
4,243
[ "MIT" ]
0
6896f6b0c56dac6d32e005afd4a94d59b1917b44
https://github.com/salem-devloper/COVID-Lung-Segment/tree/6896f6b0c56dac6d32e005afd4a94d59b1917b44
ShiftedConv
# 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 math import torch.nn as nn from numpy import prod assert_size_stride = to...
leo19941227/CPC_audio
ShiftedConv
false
12,704
[ "MIT" ]
0
2d0051915f4b4a5f773e4510cd5535e1fcb433d8
https://github.com/leo19941227/CPC_audio/tree/2d0051915f4b4a5f773e4510cd5535e1fcb433d8
ResidualBlockNoBN
import torch from torch import nn class ResidualBlockNoBN(nn.Module): """ ResNet without Batch Normalisation """ def __init__(self, in_channels, out_channels, stride=1): super(ResidualBlockNoBN, self).__init__() self.conv1 = nn.Conv2d(in_channels=in_channels, out_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 from torch import nn assert_s...
LasseWolter/laughter-detection
ResidualBlockNoBN
false
9,266
[ "MIT" ]
0
f0a37f8e991fc57e8bbc846695fc4dea84d60af5
https://github.com/LasseWolter/laughter-detection/tree/f0a37f8e991fc57e8bbc846695fc4dea84d60af5
FFN
import torch import torch.nn as nn from collections import OrderedDict class FFN(nn.Module): def __init__(self, layer_arch, input_size, output_size, bias=True): super(FFN, self).__init__() self.layer_arch = layer_arch self.input_size = input_size self.output_size = output_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 import torch.nn as nn from co...
charlesxin97/ToolFinder_binder
FFN
false
1,663
[ "Apache-2.0" ]
0
49467d5519adcd6d881e57d460c97c37b6a45add
https://github.com/charlesxin97/ToolFinder_binder/tree/49467d5519adcd6d881e57d460c97c37b6a45add
AttnBertPooler
from _paritybench_helpers import _mock_config import math import torch from torch import nn class AttnBertPooler(nn.Module): def __init__(self, config): super(AttnBertPooler, self).__init__() self.dense = nn.Linear(config.hidden_size * 2, config.hidden_size * 2) self.activation = nn.Tanh(...
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...
AnonymousAuthor2013/PostRec
AttnBertPooler
false
1,845
[ "MIT" ]
0
a1461f716d177e28b96ca29d1398f96b5717c1e1
https://github.com/AnonymousAuthor2013/PostRec/tree/a1461f716d177e28b96ca29d1398f96b5717c1e1
AdjDecoder
# 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...
BigkoalaZhu/SCORES
AdjDecoder
false
7,784
[ "MIT" ]
16
8332733c375ee85c02bd34c2adce6a3213aad3c4
https://github.com/BigkoalaZhu/SCORES/tree/8332733c375ee85c02bd34c2adce6a3213aad3c4
Relation
import torch import torch.utils.data import torch.nn as nn from torch.nn import functional as F class Relation(nn.Module): def __init__(self, C, H, out_size): super(Relation, self).__init__() self.out_size = out_size self.M = torch.nn.Parameter(torch.randn(H, H, out_size)) self.W ...
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
ActorCritic
# 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 numpy as np import tor...
GuanShiTing/DL_RL_Zoo
ActorCritic
false
5,308
[ "Apache-2.0" ]
1
520cd92c1a28f64006d51444a0940cc645b95c6d
https://github.com/GuanShiTing/DL_RL_Zoo/tree/520cd92c1a28f64006d51444a0940cc645b95c6d
AvgConsensus
# 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...
Alexis-Fab/mmaction2
AvgConsensus
false
11,202
[ "Apache-2.0" ]
0
6f76bb465a7164f907318cf58f77fc3d613f8f0f
https://github.com/Alexis-Fab/mmaction2/tree/6f76bb465a7164f907318cf58f77fc3d613f8f0f
Quantizer
# 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...
Siraj-Qazi/BNN-PYNQ
Quantizer
false
2,837
[ "BSD-3-Clause" ]
0
b942fe92b3c62b0b877b0a9d5c13e7eb3a234685
https://github.com/Siraj-Qazi/BNN-PYNQ/tree/b942fe92b3c62b0b877b0a9d5c13e7eb3a234685
Pool
import torch import torch.nn as nn import torch.nn.functional as F import torch.fx class Pool(nn.Module): def __init__(self): super(Pool, self).__init__() def forward(self, x): return F.adaptive_avg_pool2d(x, (5, 5)) def get_inputs(): return [torch.rand([4, 4, 4, 4])] def get_init_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 torch.nn as nn import torch.fx assert_size_stride = torch._C._dynamo.guards.assert_size_stride empty_strided_cuda = torch._C._dynamo....
NVIDIA/Torch-TensorRT
Pool
false
14,078
[ "BSD-3-Clause" ]
430
1a22204fecec690bc3c2a318dab4f57b98c57f05
https://github.com/NVIDIA/Torch-TensorRT/tree/1a22204fecec690bc3c2a318dab4f57b98c57f05
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....
CS-savvy/Transformer-for-Parkinsons-disease
MultiHeadAttention
false
2,091
[ "MIT" ]
0
42ef54071092f4aab74c8b9ec82c52e944806a5b
https://github.com/CS-savvy/Transformer-for-Parkinsons-disease/tree/42ef54071092f4aab74c8b9ec82c52e944806a5b
Entropy_loss
# 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 ...
DAIZHENWEI/FastGCN_pytorch
Entropy_loss
false
342
[ "MIT" ]
0
87efe350d5acbe517a0642e9862ac9676b55c053
https://github.com/DAIZHENWEI/FastGCN_pytorch/tree/87efe350d5acbe517a0642e9862ac9676b55c053
ClassPredictor
import torch from torch import nn class ClassPredictor(nn.Module): def __init__(self, nz_feat, max_object_classes): super(ClassPredictor, self).__init__() self.predictor = nn.Linear(nz_feat, max_object_classes) def forward(self, feats): class_logits = self.predictor(feats) 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....
JasonQSY/Associative3D
ClassPredictor
false
8,337
[ "MIT" ]
25
c50818b593ec48c38ed7ee3e109c23531089da32
https://github.com/JasonQSY/Associative3D/tree/c50818b593ec48c38ed7ee3e109c23531089da32
SinActv
import torch import torch.nn as nn class SinActv(nn.Module): """The sin activation function. """ def __init__(self): """Initializer method. """ super().__init__() def forward(self, input_): return torch.sin(input_) def get_inputs(): return [torch.rand([4, 4, 4, ...
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 assert_size_stride = torch._C._dynamo.guards.assert...
aksj98/neurodiffeq
SinActv
false
1,392
[ "MIT" ]
0
f0ee8ee1e78f2aeee97a4e1fc887ebe0b50749c8
https://github.com/aksj98/neurodiffeq/tree/f0ee8ee1e78f2aeee97a4e1fc887ebe0b50749c8
Attention
import torch from torch import nn from torch.nn import functional as F import torch.nn.init class Attention(nn.Module): """ Applies an attention mechanism on the output features from the decoder. """ def __init__(self, dim): super(Attention, self).__init__() self.dim = dim sel...
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....
KunpengLi1994/VSRN
Attention
false
13,995
[ "Apache-2.0" ]
238
777ae74326fdb6abe69dbd3911d0e545322520d1
https://github.com/KunpengLi1994/VSRN/tree/777ae74326fdb6abe69dbd3911d0e545322520d1
ComplexConv2d
import torch import torch.nn as nn import torch.utils.data import torch.onnx.operators import torch.optim import torch.optim.lr_scheduler class ComplexConv2d(nn.Module): def __init__(self, in_channel, out_channel, kernel_size, stride=1, padding=0, dilation=1, groups=1, bias=True, **kwargs): super...
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 import torch.onnx.operators import...
IIP-Sogang/Audio-Visual-Speech-Recognition
ComplexConv2d
false
17,452
[ "MIT" ]
9
bd03be91135acbc6162b83092d462b7fe71dd007
https://github.com/IIP-Sogang/Audio-Visual-Speech-Recognition/tree/bd03be91135acbc6162b83092d462b7fe71dd007
DenseSAGEConv
# 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....
GrumpyZhou/pytorch_geometric
DenseSAGEConv
false
5,255
[ "MIT" ]
1
88c54e72d3e26ad48e9ccd99e5696c7f19269d94
https://github.com/GrumpyZhou/pytorch_geometric/tree/88c54e72d3e26ad48e9ccd99e5696c7f19269d94
BertSelfOutput
# 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.utils....
adymaharana/VLCStoryGan
BertSelfOutput
false
18,269
[ "MIT" ]
10
74112404689e8144c2ed2d375e1e5a1cde09debb
https://github.com/adymaharana/VLCStoryGan/tree/74112404689e8144c2ed2d375e1e5a1cde09debb
TimeEncode
# 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 math as tl_math import numpy ...
IDSC-io/vre-tgn
TimeEncode
false
9,143
[ "Apache-2.0" ]
0
46e8327e3befe67003874fa70b384a511523f8f7
https://github.com/IDSC-io/vre-tgn/tree/46e8327e3befe67003874fa70b384a511523f8f7
Q
# 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...
AndersonYong/URetinex-Net-Retinex-based-Deep-Unfolding-Network-for-Low-light-Image-Enhancem
Q
false
8,928
[ "MIT" ]
0
9d837b8df9c761defb1eca390b3a60aa4a6fbb1a
https://github.com/AndersonYong/URetinex-Net-Retinex-based-Deep-Unfolding-Network-for-Low-light-Image-Enhancem/tree/9d837b8df9c761defb1eca390b3a60aa4a6fbb1a
SimpleTanhModel
# 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.jit import torch.onnx import torch.nn assert_size_stride = torch._...
opti-mix/glow
SimpleTanhModel
false
7,420
[ "Apache-2.0" ]
1
4ba074df5da9822986a23a6679ab592c22660f6d
https://github.com/opti-mix/glow/tree/4ba074df5da9822986a23a6679ab592c22660f6d
WeightedCrossEntropyLoss
import torch import torch.nn as nn import torch.nn.functional as F class WeightedCrossEntropyLoss(nn.Module): """ Transform input to fit the fomation of PyTorch offical cross entropy loss with anchor-wise weighting. """ def __init__(self): super(WeightedCrossEntropyLoss, self).__init__() ...
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 ...
Chuxwa/OpenPCDet
WeightedCrossEntropyLoss
false
5,010
[ "Apache-2.0" ]
1
be064eafee68cb23f4bbe7decf2286ef13a94ebb
https://github.com/Chuxwa/OpenPCDet/tree/be064eafee68cb23f4bbe7decf2286ef13a94ebb
FC_Q
import torch import torch.nn as nn import torch.nn.functional as F import torch.utils.data class FC_Q(nn.Module): def __init__(self, state_dim, num_actions): super(FC_Q, self).__init__() self.q1 = nn.Linear(state_dim, 256) self.q2 = nn.Linear(256, 256) self.q3 = nn.Linear(256, num...
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....
Altriaex/d4rl_evaluations
FC_Q
false
8,974
[ "Apache-2.0" ]
0
ceb34c04e98af9332c6338a1414c0c2aa5fea68b
https://github.com/Altriaex/d4rl_evaluations/tree/ceb34c04e98af9332c6338a1414c0c2aa5fea68b
RRDB
import torch import torch.nn as nn class ResidualDenseBlock_5C(nn.Module): def __init__(self, nf=64, gc=32, bias=True): super(ResidualDenseBlock_5C, self).__init__() self.conv1 = nn.Conv2d(nf, gc, 3, 1, 1, bias=bias) self.conv2 = nn.Conv2d(nf + gc, gc, 3, 1, 1, bias=bias) self.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.nn as nn assert_size_stride = torch._C._dynamo.guards.assert_size_s...
Geeta-Landmark/Super-Resolution-Image
RRDB
false
11,472
[ "Apache-2.0" ]
0
fb5d71ec9a4673409ecd28189e97056943ca308b
https://github.com/Geeta-Landmark/Super-Resolution-Image/tree/fb5d71ec9a4673409ecd28189e97056943ca308b
Fp32LayerNorm
# 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 import torch.utils.data import torch.onnx.operators impor...
CUMLSec/stateformer
Fp32LayerNorm
false
7,899
[ "MIT" ]
41
87cb3c906c43fcff42b2ca820eb6e7fd918d0a1c
https://github.com/CUMLSec/stateformer/tree/87cb3c906c43fcff42b2ca820eb6e7fd918d0a1c
GeLU
import torch from torch import nn import torch.jit import torch.nn.functional import torch.nn from torch.nn.functional import gelu class GeLU(nn.Module): def forward(self, x): return gelu(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 from torch import nn import torch.jit import torch.nn.functional import torch.n...
Gitsamshi/nnUNet-1
GeLU
false
8,150
[ "Apache-2.0" ]
28
5341684211e6d91dab6ad76a7595a95addff23be
https://github.com/Gitsamshi/nnUNet-1/tree/5341684211e6d91dab6ad76a7595a95addff23be
period_L2
import torch import numpy as np import torch.nn as nn def reduction_mean(loss): return loss.mean() def reduction_none(loss): return loss def reduction_sum(loss): return loss.sum() class period_L2(nn.Module): def __init__(self, reduction='sum'): """ periodic Squared Error ...
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...
flytocc/RAPiD
period_L2
false
15,358
[ "MIT" ]
142
92e6a44b8a0107def055e93c971d78fd548562f8
https://github.com/flytocc/RAPiD/tree/92e6a44b8a0107def055e93c971d78fd548562f8
MaskedLinearSeqDup
import torch import torch.cuda from torch.nn.functional import * class MaskedLinear(torch.nn.Linear): def forward(self, x, mask): out = super().forward(x) if mask.is_floating_point(): out = out * mask else: out = out * mask.type_as(out) return out class M...
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.cuda from torch.nn.functional import * assert_size_stride = torch._...
bratao/DeepSpeed
MaskedLinearSeqDup
false
6,361
[ "MIT" ]
1
c50d8955e942e5e26cf81835d59ec3f20ef8540d
https://github.com/bratao/DeepSpeed/tree/c50d8955e942e5e26cf81835d59ec3f20ef8540d
Conv2dLayer
import torch import torch.nn as nn from torch.nn import Parameter def l2normalize(v, eps=1e-12): return v / (v.norm() + eps) class LayerNorm(nn.Module): def __init__(self, num_features, eps=1e-08, affine=True): super(LayerNorm, self).__init__() self.num_features = num_features self....
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 ...
LenKerr/Semantic-Colorization-GAN
Conv2dLayer
false
5,513
[ "MIT" ]
1
2ce52406ca6fc92e69692b451b1c9ae66ba3b76f
https://github.com/LenKerr/Semantic-Colorization-GAN/tree/2ce52406ca6fc92e69692b451b1c9ae66ba3b76f
FocalLoss
import torch from torch import nn import torch.nn.functional as F class FocalLoss(nn.Module): """ Implementation of the binary focal loss proposed in: https://arxiv.org/abs/1708.02002 """ def __init__(self, alpha: 'float'=1.0, gamma: 'float'=2.0, reduce: 'str'='mean') ->None: """ ...
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 ...
ChristophReich1996/3D_Baggage_Segmentation
FocalLoss
false
5,002
[ "MIT" ]
1
00392cb0fde22d3180b6baf81e404d0fcf4e2ebf
https://github.com/ChristophReich1996/3D_Baggage_Segmentation/tree/00392cb0fde22d3180b6baf81e404d0fcf4e2ebf
BothContextGate
# 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 ...
AndrewM1998/MultimodalNMT
BothContextGate
false
7,717
[ "MIT" ]
40
b66d3a40ac9bc5c11ae124f51d1a9abf7cd6a04b
https://github.com/AndrewM1998/MultimodalNMT/tree/b66d3a40ac9bc5c11ae124f51d1a9abf7cd6a04b
VectorQuantizer
# 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...
mateoIdemia/PyTorch-VAE
VectorQuantizer
false
12,766
[ "Apache-2.0" ]
0
b485924182e62843aae1955fcaf0886ac8492295
https://github.com/mateoIdemia/PyTorch-VAE/tree/b485924182e62843aae1955fcaf0886ac8492295
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....
ChoiIseungil/vilbert-multi-task
Attention
false
5,001
[ "MIT" ]
1
37d14b9aed9c48117a820e05157c7ccd3dd20d5b
https://github.com/ChoiIseungil/vilbert-multi-task/tree/37d14b9aed9c48117a820e05157c7ccd3dd20d5b
Myloss
import torch import torch.nn as nn class Myloss(nn.Module): def __init__(self, epsilon=1e-08): super(Myloss, self).__init__() self.epsilon = epsilon return def forward(self, input_, label, weight): entropy = -label * torch.log(input_ + self.epsilon) - (1 - label )...
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 ...
MoriZSJ/GVB
Myloss
false
2,656
[ "MIT" ]
0
9b954660ef377ead81c8e631c4a0f4a17075b2ea
https://github.com/MoriZSJ/GVB/tree/9b954660ef377ead81c8e631c4a0f4a17075b2ea
SELECT_fusion_block
# 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.parallel impo...
RongchangLi/DEN
SELECT_fusion_block
false
17,883
[ "MIT" ]
4
f8b744f96a3a68cf0784080ffd561a5279715727
https://github.com/RongchangLi/DEN/tree/f8b744f96a3a68cf0784080ffd561a5279715727
BasicConvBlock
import torch from torch import nn import torch.nn.functional as F class BasicConvBlock(nn.Module): def __init__(self, in_channels, out_channels): super(BasicConvBlock, self).__init__() self.conv1 = nn.Conv2d(in_channels, out_channels, kernel_size=3, padding=1) self.conv2 = 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.triton_helpers import libdevice from torch import n...
royerloic/aydin
BasicConvBlock
false
16,345
[ "BSD-3-Clause" ]
78
f9c61a24030891d008c318b250da5faec69fcd7d
https://github.com/royerloic/aydin/tree/f9c61a24030891d008c318b250da5faec69fcd7d
GramMatrix
# 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...
Jay2020-01/TextureGAN--Flask
GramMatrix
false
17,471
[ "MIT" ]
5
cddea505b0d66b58d58fb24435f8bae42fd5a852
https://github.com/Jay2020-01/TextureGAN--Flask/tree/cddea505b0d66b58d58fb24435f8bae42fd5a852
HardMish
# 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...
cooked-sashimi/Yet-Another-YOLOv4-Pytorch
HardMish
false
15,074
[ "MIT" ]
133
c884ef8849987a75b0e17eba1b739c22d3782e90
https://github.com/cooked-sashimi/Yet-Another-YOLOv4-Pytorch/tree/c884ef8849987a75b0e17eba1b739c22d3782e90
GradLoss
import torch import torch.nn as nn class GradLoss(nn.Module): def __init__(self): super(GradLoss, self).__init__() def forward(self, grad_fake, grad_real): return torch.sum(torch.mean(torch.abs(grad_real - grad_fake))) def get_inputs(): return [torch.rand([4, 4, 4, 4]), torch.rand([4, ...
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 ...
Khoronus/MonoDepth-FPN-PyTorch
GradLoss
false
721
[ "MIT" ]
0
6e41e297723d1490c537e04afff905c61d6f0ff8
https://github.com/Khoronus/MonoDepth-FPN-PyTorch/tree/6e41e297723d1490c537e04afff905c61d6f0ff8
AE_3D_small_v2
# 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 ...
gitter-badger/HEPAutoencoders
AE_3D_small_v2
false
12,433
[ "Apache-2.0" ]
0
43010cd66fa4335a04b30b87926148e1c8d92de9
https://github.com/gitter-badger/HEPAutoencoders/tree/43010cd66fa4335a04b30b87926148e1c8d92de9
Attention
import torch import torch.nn.functional as F from torch import nn class Attention(nn.Module): """Attention Layer merging Encoder and Decoder Attributes: hidden_size (int): The number of features in the hidden state h Reference: * https://github.com/bentrevett/pytorch-seq2seq ...
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....
appleparan/mise.py
Attention
false
6,233
[ "MIT" ]
1
a77ea51be37a739928600c66d168d69b78bc0c4b
https://github.com/appleparan/mise.py/tree/a77ea51be37a739928600c66d168d69b78bc0c4b
QConv2d
# 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 Tensor import torch.nn as nn import torch.autograd as A from t...
i207M/pytorch-cifar
QConv2d
false
10,229
[ "MIT" ]
0
df4417b6d0a25515ac82b5aa6151ae2135b2cd5c
https://github.com/i207M/pytorch-cifar/tree/df4417b6d0a25515ac82b5aa6151ae2135b2cd5c
ConvBlockFixup
# 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...
OmarNajdi/dl-for-har
ConvBlockFixup
false
934
[ "MIT" ]
0
5e1b7c29caf2b41fcba106cd901c45d8f2d18429
https://github.com/OmarNajdi/dl-for-har/tree/5e1b7c29caf2b41fcba106cd901c45d8f2d18429
Encoder
import torch from torch import nn import torch.hub import torch.nn.functional as F class Encoder(nn.Module): """Estimation of the nonnegative mixture weight by a 1-D conv layer. """ def __init__(self, L, N, audio_channels): super(Encoder, self).__init__() self.L, self.N = L, N sel...
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...
JavierCane/demucs
Encoder
false
5,392
[ "MIT" ]
1
01d14844a71be7b5d86adf06a8501a951157c3fe
https://github.com/JavierCane/demucs/tree/01d14844a71be7b5d86adf06a8501a951157c3fe
GatedConv2d
# 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.data assert_size_stride = torch._C._dyn...
AWehenkel/UMNN
GatedConv2d
false
13,259
[ "BSD-3-Clause" ]
69
f93cb36040783dd60e14e0eda927899d3919825c
https://github.com/AWehenkel/UMNN/tree/f93cb36040783dd60e14e0eda927899d3919825c
_FakeMegatronMLP
# 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 ...
liuhatry/fastmoe
_FakeMegatronMLP
false
3,989
[ "Apache-2.0" ]
0
a676bf1eae874c208a0e669bf0f79e6fb3b43623
https://github.com/liuhatry/fastmoe/tree/a676bf1eae874c208a0e669bf0f79e6fb3b43623
SPoC_pooling
# 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...
SIJIEJI/2020-ai-meets-beauty_ntubeauty
SPoC_pooling
false
5,793
[ "MIT" ]
1
fede564fb3e3029f3fadfe107484c5c7e39c29c5
https://github.com/SIJIEJI/2020-ai-meets-beauty_ntubeauty/tree/fede564fb3e3029f3fadfe107484c5c7e39c29c5
SIMSE
import torch import torch.nn as nn class SIMSE(nn.Module): def __init__(self): super(SIMSE, self).__init__() def forward(self, pred, real): diffs = torch.add(real, -pred) n = torch.numel(diffs.data) simse = torch.sum(diffs).pow(2) / n ** 2 return simse def get_input...
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...
Columbine21/TFR-Net
SIMSE
false
17,126
[ "MIT" ]
7
1da01577542e7f477fdf7323ec0696aebc632357
https://github.com/Columbine21/TFR-Net/tree/1da01577542e7f477fdf7323ec0696aebc632357
Bottleneck
import torch import torch.nn as nn import torch.nn.functional as F class Bottleneck(nn.Module): expansion = 4 def __init__(self, inplanes, planes, stride=1): super(Bottleneck, self).__init__() self.conv1 = nn.Conv2d(inplanes, planes, kernel_size=1, bias=False) self.norm1 = nn.GroupNor...
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....
andyqmongo/InstAParam
Bottleneck
false
18,336
[ "MIT" ]
3
00494d5367ec32b4ce90d01778cba9d4f1166833
https://github.com/andyqmongo/InstAParam/tree/00494d5367ec32b4ce90d01778cba9d4f1166833
CEL
# 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...
Farzanehkaji/https-github.com-lartpang-MINet
CEL
false
11,414
[ "MIT" ]
0
db7f5e64be4d28df2bfc68409b56c3f97d6388f1
https://github.com/Farzanehkaji/https-github.com-lartpang-MINet/tree/db7f5e64be4d28df2bfc68409b56c3f97d6388f1
SReLU
# 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 import torch.nn as nn assert_size_stride = torch._C._dynamo.guards.assert_size_stride emp...
bpicnbnk/ISONet
SReLU
false
1,572
[ "MIT" ]
0
993150fa215dbc92460142ade59a3a5ec4a0efd9
https://github.com/bpicnbnk/ISONet/tree/993150fa215dbc92460142ade59a3a5ec4a0efd9
MultiHead
# 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....
CFF-Dream/pytorch_geometric
MultiHead
false
2,045
[ "MIT" ]
0
7c19ad74957409ee9e07314ce81524b3113b9c84
https://github.com/CFF-Dream/pytorch_geometric/tree/7c19ad74957409ee9e07314ce81524b3113b9c84
SEBlock
# 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_...
Sharingsky/resrep
SEBlock
false
9,520
[ "MIT" ]
0
a173d1bc256b75b2c902024929e406863ce48b9b
https://github.com/Sharingsky/resrep/tree/a173d1bc256b75b2c902024929e406863ce48b9b
ResNet
import torch import torch.nn as nn import torch.nn.functional as F class ResNet(nn.Module): """Modified ResNet model class""" def __init__(self, block, num_blocks, depth, width=1): super(ResNet, self).__init__() self.iters = int((depth - 4) // 4) self.in_planes = int(width * 64) ...
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_...
Maosef/easy-to-hard
ResNet
false
8,555
[ "MIT" ]
44
711ec0965229444a6c51b1b06a4e2cad3e32d02e
https://github.com/Maosef/easy-to-hard/tree/711ec0965229444a6c51b1b06a4e2cad3e32d02e
AdversarialNetwork
import torch import torch.utils.data import torch import torch.nn as nn class AdversarialNetwork(nn.Module): def __init__(self, in_feature): super(AdversarialNetwork, self).__init__() self.ad_layer1 = nn.Linear(in_feature, 1024) self.ad_layer2 = nn.Linear(1024, 1024) self.ad_layer...
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 import torch.nn as nn assert_size_stride = ...
FigaroK/pytorch-CycleGAN-and-pix2pix
AdversarialNetwork
false
9,072
[ "BSD-3-Clause" ]
0
74407363baf4626782398040e34a342e20915d41
https://github.com/FigaroK/pytorch-CycleGAN-and-pix2pix/tree/74407363baf4626782398040e34a342e20915d41
ConcatELU
import torch import torch.nn as nn import torch.nn.functional as F class ConcatELU(nn.Module): """ Activation function that applies ELU in both direction (inverted and plain). Allows non-linearity while providing strong gradients for any input (important for final convolution) """ def forward(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 import torch.nn as nn assert_size_stride = torch._C._dynamo.guards.assert_size_...
GBATZOLIS/CAFLOW
ConcatELU
false
17,278
[ "MIT" ]
6
ea33f84c424bd8e46999be59cd5d52bd8f0a3a77
https://github.com/GBATZOLIS/CAFLOW/tree/ea33f84c424bd8e46999be59cd5d52bd8f0a3a77
LayerNorm
import torch import torch.autograd import torch.nn as nn class LayerNorm(nn.Module): def __init__(self, input_dim, cond_dim=0, center=True, scale=True, epsilon=None, conditional=False, hidden_units=None, hidden_activation='linear', hidden_initializer='xaiver', **kwargs): super(LayerNorm, ...
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.autograd import torch.nn as nn assert_size_stride = torch._C._dyna...
dumpmemory/W2NER
LayerNorm
false
15,271
[ "MIT" ]
128
fb1b6eb1111eb001b1c965097d995244b840bdda
https://github.com/dumpmemory/W2NER/tree/fb1b6eb1111eb001b1c965097d995244b840bdda
LayerNorm
import torch import torch.nn as nn from torch.nn.parameter import Parameter class LayerNorm(nn.Module): def __init__(self, input_dim, cond_dim=0, center=True, scale=True, epsilon=None, conditional=False, hidden_units=None, hidden_activation='linear', hidden_initializer='xaiver', **kwargs): ...
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 assert_size_stride = torch._C._dynamo.guards.assert_size_stride empty_strided...
cwxcwx0319/Dictionary
LayerNorm
false
15,097
[ "Apache-2.0" ]
82
55fb9a602a212f9c3a69a318fec31da1d07279df
https://github.com/cwxcwx0319/Dictionary/tree/55fb9a602a212f9c3a69a318fec31da1d07279df
MultiHead
import math import torch import torch.nn as nn import torch.nn.functional as F import torch.utils.data.distributed def matmul(x, y): if x.dim() == y.dim(): return x @ y if x.dim() == y.dim() - 1: return (x.unsqueeze(-2) @ y).squeeze(-2) return (x @ y.unsqueeze(-2)).squeeze(-2) class Line...
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....
MichiganCOG/Video-Grounding
MultiHead
false
8,549
[ "MIT" ]
41
3e0ec0b69578a59be583911590354fe77d357cab
https://github.com/MichiganCOG/Video-Grounding/tree/3e0ec0b69578a59be583911590354fe77d357cab
BCELoss2d
# 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...
jayden-chua/image-mask
BCELoss2d
false
3,689
[ "MIT" ]
0
ce2c6a32bf13df582e7b57e506d58518258be292
https://github.com/jayden-chua/image-mask/tree/ce2c6a32bf13df582e7b57e506d58518258be292
LinearThreeDeep
import torch import torch.nn as nn import torch.nn.functional as F class LinearThreeDeep(nn.Module): def __init__(self, inputSize, hiddenSize1, hiddenSize2, hiddenSize3, outputSize): super().__init__() self.inputLinear = nn.Linear(inputSize, hiddenSize1) self.hiddenLinear1 = nn.Li...
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....
dmechea/PyTorch-CartPole
LinearThreeDeep
false
1,853
[ "MIT" ]
0
9f49ac7b2ae59882e5ea66cc8f43f0354a120c49
https://github.com/dmechea/PyTorch-CartPole/tree/9f49ac7b2ae59882e5ea66cc8f43f0354a120c49
Net
import torch import torch.nn as nn import torch.nn.functional as F class Net(nn.Module): def __init__(self): super(Net, self).__init__() self.conv1 = nn.Conv2d(1, 32, 5) self.pool1 = nn.MaxPool2d(2, 2) self.conv2 = nn.Conv2d(32, 32, 3) self.pool2 = nn.MaxPool2d(3, 3) ...
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_...
MonteYang/P1_Facial_Keypoints
Net
false
11,740
[ "MIT" ]
0
1e3e4c9c6b48ec241f6fc7e072b25c7211cebd18
https://github.com/MonteYang/P1_Facial_Keypoints/tree/1e3e4c9c6b48ec241f6fc7e072b25c7211cebd18
DynamicsModel
# 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.nn.functional as F assert_size_stride = torch...
si0wang/transfer_dmc
DynamicsModel
false
12,985
[ "MIT" ]
0
6bda773244e0b709b3c13add2597f5f1cd01bfd7
https://github.com/si0wang/transfer_dmc/tree/6bda773244e0b709b3c13add2597f5f1cd01bfd7
DiceLoss
import collections import torch import warnings from typing import Optional from typing import Union from typing import Callable from typing import Any from typing import Tuple import torch.nn from torch.nn.modules.loss import _Loss from enum import Enum import collections.abc def issequenceiterable(obj: 'Any') ->boo...
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 collections from typing import Optional from typing import Union from typing import Callable from typing import Any from typing impor...
Irme/MONAI
DiceLoss
false
17,438
[ "Apache-2.0" ]
3
dc4bf661831b14f4231cb325cc1b15d38c1e406c
https://github.com/Irme/MONAI/tree/dc4bf661831b14f4231cb325cc1b15d38c1e406c
NormedLinear
import torch import torch.nn.functional as F import torch.nn as nn class NormedLinear(nn.Linear): """Normalized Linear Layer. Args: tempeature (float, optional): Tempeature term. Default to 20. power (int, optional): Power term. Default to 1.0. eps (float, optional): The minimal value...
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 ...
Bin-ze/Food_detection
NormedLinear
false
17,004
[ "Apache-2.0" ]
4
1c1a067f12644f2b0289e49aec4637d580722f70
https://github.com/Bin-ze/Food_detection/tree/1c1a067f12644f2b0289e49aec4637d580722f70
TorchModel
# 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_...
DLPerf/elasticdl
TorchModel
false
8,937
[ "MIT" ]
0
b9c03ea0e81861ae8d349c3d8ffd1f7b588b910b
https://github.com/DLPerf/elasticdl/tree/b9c03ea0e81861ae8d349c3d8ffd1f7b588b910b
Softplus
import torch import numpy as np from torch.utils.data import Dataset as Dataset import torch.nn as nn import torch.utils.data def activation_shifting(activation): def shifted_activation(x): return activation(x) - activation(torch.zeros_like(x)) return shifted_activation def cauchy_softplus(x): ...
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 numpy as np from torch.utils.data import Dataset as Dat...
KelvinKan/CP-Flow
Softplus
false
13,931
[ "MIT" ]
64
d01303cb4ebeb5a0bbfca638ffaf5b7a8ec22fb1
https://github.com/KelvinKan/CP-Flow/tree/d01303cb4ebeb5a0bbfca638ffaf5b7a8ec22fb1
ClassificationNet
import torch import torch.nn.functional as F from torch import nn class ClassificationNet(nn.Module): def __init__(self, num_classes=10, num_digits=2): super(ClassificationNet, self).__init__() self.conv1 = nn.Conv2d(1, 64, 3, padding=1) self.conv2 = nn.Conv2d(64, 64, 3, 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 from torch import nn assert_s...
YIFEI-MA/MultiDigitRecognition
ClassificationNet
false
12,000
[ "MIT" ]
0
f1f9567c31102ccdc7464a35b8a7c533b5d46734
https://github.com/YIFEI-MA/MultiDigitRecognition/tree/f1f9567c31102ccdc7464a35b8a7c533b5d46734
SimpleNet
# 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 ...
aakgun/pytorch-VideoDataset
SimpleNet
false
3,014
[ "MIT" ]
0
619e385f37b99bfabca0b814673825ed902242b2
https://github.com/aakgun/pytorch-VideoDataset/tree/619e385f37b99bfabca0b814673825ed902242b2
SELU
import torch import torch.nn as nn from torch.autograd import Variable import torch.nn.functional as F def where(condition, if_true, if_false): """ Torch equivalent of numpy.where. Parameters ---------- condition : torch.ByteTensor or torch.cuda.ByteTensor or torch.autograd.Variable Condi...
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.autograd import Variable import torch.nn.funct...
dearkafka/inferno
SELU
false
1,829
[ "Apache-2.0" ]
0
e9e3b863fd1fc97cf94d08ac6b4f8df7665f996a
https://github.com/dearkafka/inferno/tree/e9e3b863fd1fc97cf94d08ac6b4f8df7665f996a
Net
# 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 ...
aivaslab/marlgrid
Net
false
3,051
[ "Apache-2.0" ]
0
10b53d27ce224fadeeb5830d6034350a69feb4b4
https://github.com/aivaslab/marlgrid/tree/10b53d27ce224fadeeb5830d6034350a69feb4b4
DeepQNetwork
# 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 as T import torc...
SuperSaiyan-God/Reinforcement-Learning
DeepQNetwork
false
4,435
[ "MIT" ]
0
b43a2997e28ec3bf437c37d060637f6deecf89c6
https://github.com/SuperSaiyan-God/Reinforcement-Learning/tree/b43a2997e28ec3bf437c37d060637f6deecf89c6
Net
# 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....
dqawami/openvino_training_extensions
Net
false
15,223
[ "Apache-2.0" ]
256
dddda1dfd651eaae2d59cecda84275b1b03bd0ad
https://github.com/dqawami/openvino_training_extensions/tree/dddda1dfd651eaae2d59cecda84275b1b03bd0ad
_Classifier
import torch import torch.nn as nn import torch.nn.functional as F import torch.utils.data class _Classifier(nn.Module): def __init__(self, z_c_dim): super(_Classifier, self).__init__() self.fc1 = nn.Linear(z_c_dim, 50) self.fc2 = nn.Linear(50, 10) def forward(self, z_c): h =...
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
_Classifier
false
4,031
[ "MIT" ]
0
465009076a9be78e8ddb9021a0699b32fc695f30
https://github.com/mori97/revae/tree/465009076a9be78e8ddb9021a0699b32fc695f30
down_shifted_conv2d
import torch import torch.nn as nn from torch.nn.utils import weight_norm as wn def down_shift(x, pad=None): xs = [int(y) for y in x.size()] x = x[:, :, :xs[2] - 1, :] pad = nn.ZeroPad2d((0, 0, 1, 0)) if pad is None else pad return pad(x) class down_shifted_conv2d(nn.Module): def __init__(self,...
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 ...
ajayjain/lmconv
down_shifted_conv2d
false
14,782
[ "MIT" ]
69
e00576de5118702c90493e88c6e459b0e45d1290
https://github.com/ajayjain/lmconv/tree/e00576de5118702c90493e88c6e459b0e45d1290
LogisticRegression
# 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 assert_size_stride = torch._C._dynamo.guards.assert_size_stride empty_strided_cuda = torch._C._dynamo.guards._empty_st...
jayelm/pytorch-project-template
LogisticRegression
false
6,924
[ "MIT" ]
1
30306ce07b21c97c6993432764cbbe0a73092a0c
https://github.com/jayelm/pytorch-project-template/tree/30306ce07b21c97c6993432764cbbe0a73092a0c
BasicNN
import torch import numpy as np from torch import nn from torch.autograd import Variable import torch.nn.functional as F class BasicNN(nn.Module): def __init__(self): super(BasicNN, self).__init__() self.net = nn.Linear(28 * 28, 2) def forward(self, x): if type(x) == np.ndarray: ...
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....
gtfierro/clipper
BasicNN
false
10,159
[ "Apache-2.0" ]
0
88d7c238d51d5cf66d118bffca0c17edee84755e
https://github.com/gtfierro/clipper/tree/88d7c238d51d5cf66d118bffca0c17edee84755e
InnerProductDecoder
import torch import torch.fx import torch.utils.data class InnerProductDecoder(torch.nn.Module): """The inner product decoder from the `"Variational Graph Auto-Encoders" <https://arxiv.org/abs/1611.07308>`_ paper .. math:: \\sigma(\\mathbf{Z}\\mathbf{Z}^{\\top}) where :math:`\\mathbf{Z} \\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 torch.fx import torch.utils.data assert_size_stride = torch._C._dynamo.guards.assert_size_stride empty_strided_cuda = torch._C._dynam...
HWSelf/pytorch_geometric
InnerProductDecoder
false
504
[ "MIT" ]
0
c1214de674079b5e39e57c045d0f844b60caf590
https://github.com/HWSelf/pytorch_geometric/tree/c1214de674079b5e39e57c045d0f844b60caf590
FeedForwardLayer
import torch from torch import nn class FeedForwardLayer(nn.Module): def __init__(self, hidden_size): super(FeedForwardLayer, self).__init__() self.linear_1 = nn.Linear(hidden_size, 4 * hidden_size) self.linear_2 = nn.Linear(4 * hidden_size, hidden_size) self.relu = nn.ReLU() ...
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...
yongho94/Transformers_NMT
FeedForwardLayer
false
11,021
[ "MIT" ]
0
14fb08a6b1391da4d49f199dc16d7beb37620c98
https://github.com/yongho94/Transformers_NMT/tree/14fb08a6b1391da4d49f199dc16d7beb37620c98
SimpleLogModule
import torch import torch.jit import torch.onnx import torch.nn class SimpleLogModule(torch.nn.Module): def __init__(self, *dimensions): super(SimpleLogModule, self).__init__() def forward(self, a): b = torch.log(a) return torch.log(b) def get_inputs(): return [torch.rand([4, 4...
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.jit import torch.onnx import torch.nn assert_size_stride = t...
opti-mix/glow
SimpleLogModule
false
7,401
[ "Apache-2.0" ]
1
4ba074df5da9822986a23a6679ab592c22660f6d
https://github.com/opti-mix/glow/tree/4ba074df5da9822986a23a6679ab592c22660f6d
TorchEntityRecognizer
import torch from typing import List from collections import OrderedDict from torch import nn def is_dropout_module(module: 'nn.Module', dropout_modules: 'List[nn.Module]'=[nn.Dropout, nn.Dropout2d, nn.Dropout3d]) ->bool: """Detect if a PyTorch Module is a Dropout layer module (nn.Module): Module to check...
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....
apjanco/projects
TorchEntityRecognizer
false
14,891
[ "MIT" ]
823
2f8850140ba13ab18b9cf622e46e79013d41701f
https://github.com/apjanco/projects/tree/2f8850140ba13ab18b9cf622e46e79013d41701f
Cosh
# 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.onnx import torch.nn as nn assert_size_stride = torch._C._dynamo.g...
mil-tokyo/webdnn
Cosh
false
16,080
[ "MIT" ]
1,967
38a60fd3e1a4e72bc01108189a3aa51e0752aecd
https://github.com/mil-tokyo/webdnn/tree/38a60fd3e1a4e72bc01108189a3aa51e0752aecd
net2
import torch import torch.nn as nn import torch.nn.functional as F class net2(nn.Module): """ """ def __init__(self, n_classes=2): super(net2, self).__init__() if torch.cuda.is_available(): torch.device('cuda') else: torch.device('cpu') self.n_class...
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....
luisesanmartin/dwelling-recognition
net2
false
7,139
[ "MIT" ]
1
b2437b64088a26746947c1c88077c96332e7b9c6
https://github.com/luisesanmartin/dwelling-recognition/tree/b2437b64088a26746947c1c88077c96332e7b9c6
Invertible1x1Conv
import torch from torch.nn import functional as F from torch.autograd import Variable import torch.utils.data class Invertible1x1Conv(torch.nn.Module): """ The layer outputs both the convolution, and the log determinant of its weight matrix. If reverse=True it does convolution with inverse """ ...
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.nn import functional as F from torch.autograd import Variable import ...
ishalyminov/shad_speech
Invertible1x1Conv
false
15,611
[ "MIT" ]
83
e1345d2de929e150b2683190b127a837fbcb34f3
https://github.com/ishalyminov/shad_speech/tree/e1345d2de929e150b2683190b127a837fbcb34f3
ConvolutionModule
import torch from torch import Tensor from torch import nn class Swish(torch.nn.Module): """Construct an Swish object.""" def forward(self, x: 'Tensor') ->Tensor: """Return Swich activation function.""" return x * torch.sigmoid(x) class ConvolutionModule(nn.Module): """ConvolutionModule...
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 T...
desh2608/icefall
ConvolutionModule
false
3,420
[ "Apache-2.0" ]
0
1603744469d167d848e074f2ea98c587153205fa
https://github.com/desh2608/icefall/tree/1603744469d167d848e074f2ea98c587153205fa
injective_pad
# 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...
Schwartz-Zha/My-invertible-resnet
injective_pad
false
1,034
[ "MIT" ]
0
5415975bb0d640f3bf3ef4a7b986563e84109270
https://github.com/Schwartz-Zha/My-invertible-resnet/tree/5415975bb0d640f3bf3ef4a7b986563e84109270
ResBlock
import torch class ResBlock(torch.nn.Module): def __init__(self, num_channel): super(ResBlock, self).__init__() self.conv1 = torch.nn.Conv2d(num_channel, num_channel, kernel_size= 3, stride=1, padding=1) self.conv2 = torch.nn.Conv2d(num_channel, num_channel, 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 assert_size_stride = torch._C._dynamo.guards.assert_size_stride empty_strided_cu...
Gregory-Eales/mban
ResBlock
false
5,233
[ "Apache-2.0" ]
1
d8b35db51c7e601b1db777d9a80343600374250b
https://github.com/Gregory-Eales/mban/tree/d8b35db51c7e601b1db777d9a80343600374250b
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...
AkshayGanesh/yolov5processor
Classify
false
4,813
[ "MIT" ]
1
788accfa93798729c002b2c9b4f943284ff97cad
https://github.com/AkshayGanesh/yolov5processor/tree/788accfa93798729c002b2c9b4f943284ff97cad
Add_ParamI
# 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 import torch.distributions import torch.utils.data assert_size_stride = torch._C._dynamo.guards.assert_size_stride emp...
AlexMeinke/Provable-OOD-Detection
Add_ParamI
false
7,684
[ "MIT" ]
21
9a132aec994ff718c96b81885736ab866df60d87
https://github.com/AlexMeinke/Provable-OOD-Detection/tree/9a132aec994ff718c96b81885736ab866df60d87
Multi_Head_Attention
import torch import torch.nn as nn import torch.nn.functional as F class Scaled_Dot_Product_Attention(nn.Module): """Scaled Dot-Product Attention """ def __init__(self): super(Scaled_Dot_Product_Attention, self).__init__() def forward(self, Q, K, V, scale=None): """ Args: ...
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...
tianjiansmile/Chinese-Text-Classification-Pytorch
Multi_Head_Attention
false
10,887
[ "MIT" ]
0
05cc211b161f61e6bb32ab185dadcffec2f5b5de
https://github.com/tianjiansmile/Chinese-Text-Classification-Pytorch/tree/05cc211b161f61e6bb32ab185dadcffec2f5b5de
StructuralProbe
import torch import torch.nn as nn import torch.utils.data.dataloader class StructuralProbe(nn.Module): """ Computes squared L2 distance after projection by a matrix. For a batch of sentences, computes all n^2 pairs of distances for each sentence in the batch. """ def __init__(self, model_dim, ra...
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.dataloader assert_size_stride = to...
TimO96/NLP2
StructuralProbe
false
1,140
[ "MIT" ]
0
83f65a385457f68397c641f38b53df0110282578
https://github.com/TimO96/NLP2/tree/83f65a385457f68397c641f38b53df0110282578
PixLoss
import torch import torch.nn as nn class PixLoss(nn.Module): """Pixel-wise MSE loss for images""" def __init__(self, alpha=20): super().__init__() self.alpha = alpha def forward(self, fake, real): return self.alpha * torch.mean((fake - real) ** 2) def get_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 import triton_helpers import torch.nn as nn assert_size_stride = torch._C._dynamo.guards.assert_size_stride emp...
akanametov/SuperResolution
PixLoss
false
6,135
[ "MIT" ]
1
45313d1309ddb5cdef821aaf5ac7b5ad574b5287
https://github.com/akanametov/SuperResolution/tree/45313d1309ddb5cdef821aaf5ac7b5ad574b5287
ZeroConv2d
# 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 math as tl_math from torch im...
HugoSenetaire/glow-pytorch
ZeroConv2d
false
567
[ "MIT" ]
0
7f11be87cac9770df63867910c34738dedee6f56
https://github.com/HugoSenetaire/glow-pytorch/tree/7f11be87cac9770df63867910c34738dedee6f56
ResidualNetworkSegment
# 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_...
Arjung27/DeepThinking
ResidualNetworkSegment
false
16,967
[ "MIT" ]
6
13a2ce534bcb0b9379a22fffef52d975d650adb2
https://github.com/Arjung27/DeepThinking/tree/13a2ce534bcb0b9379a22fffef52d975d650adb2