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 |
|---|---|---|---|---|---|---|---|---|---|---|
Reorg | # 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... | Zhang-Jack/adversarial_yolo2 | Reorg | false | 18,177 | [
"MIT"
] | 8 | 91c2a4793047f656482cebf0309984db823e8030 | https://github.com/Zhang-Jack/adversarial_yolo2/tree/91c2a4793047f656482cebf0309984db823e8030 |
MatrixTree | # 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 math as tl_math
import torch.nn as nn
import torch.cuda
import torch.distributed
assert_s... | ChenRocks/Distill-BERT-Textgen-ONMT | MatrixTree | false | 17,150 | [
"MIT"
] | 7 | d83dd1a95af7513cbfae4a2768f6effc2f3a589f | https://github.com/ChenRocks/Distill-BERT-Textgen-ONMT/tree/d83dd1a95af7513cbfae4a2768f6effc2f3a589f |
PolicyNetwork | import torch
import torch.nn.functional as F
import torch.nn as nn
from torch.distributions import Normal
def mish(x):
"""
Mish: A Self Regularized Non-Monotonic Neural Activation Function
https://arxiv.org/abs/1908.08681v1
implemented for PyTorch / FastAI by lessw2020
https://gith... | 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.... | Crawford-fang/ROS_pytorch_RL | PolicyNetwork | false | 17,168 | [
"Apache-2.0"
] | 10 | 2d3476f15d51aa1f5b5ae9edc5d7f4c776e5de9f | https://github.com/Crawford-fang/ROS_pytorch_RL/tree/2d3476f15d51aa1f5b5ae9edc5d7f4c776e5de9f |
Blockdown | # 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... | SeanChenxy/GAN_RS | Blockdown | false | 8,746 | [
"BSD-3-Clause"
] | 17 | a1786b946caf7bd24c83cea4c7a9bb74445cc381 | https://github.com/SeanChenxy/GAN_RS/tree/a1786b946caf7bd24c83cea4c7a9bb74445cc381 |
MaxPool2d | import torch
import numpy as np
import torch.nn as nn
from numbers import Number
def keep_variance_fn(x):
return x + 0.001
def normcdf(value, mu=0.0, stddev=1.0):
sinv = 1.0 / stddev if isinstance(stddev, Number) else stddev.reciprocal()
return 0.5 * (1.0 + torch.erf((value - mu) * sinv / np.sqrt(2.0)))... | 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
import torch.nn as nn
from numbers import N... | THAKAORI/SalsaNext | MaxPool2d | false | 11,909 | [
"MIT"
] | 0 | 855cd7e9ebb83ee62538ba4753a011ada7bbfb6c | https://github.com/THAKAORI/SalsaNext/tree/855cd7e9ebb83ee62538ba4753a011ada7bbfb6c |
Self_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.... | qiyuqianxai/debvc | Self_Attention | false | 10,798 | [
"MIT"
] | 0 | 1d919019a3191d1c6a7da9b8f16e47bca6b3aef9 | https://github.com/qiyuqianxai/debvc/tree/1d919019a3191d1c6a7da9b8f16e47bca6b3aef9 |
NormConv2d | import torch
from torch import nn
from torch.nn.utils import weight_norm
class NormConv2d(nn.Module):
"""
Convolutional layer with l2 weight normalization and learned scaling parameters
"""
def __init__(self, in_channels, out_channels, kernel_size, stride=1,
padding=0):
super().__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.triton_helpers import libdevice
from torch import n... | CompVis/interactive-image2video-synthesis | NormConv2d | false | 7,934 | [
"MIT"
] | 20 | 05ea449d3a2704b6d79a5f08683035220d615576 | https://github.com/CompVis/interactive-image2video-synthesis/tree/05ea449d3a2704b6d79a5f08683035220d615576 |
CrossEntropyLoss | # 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
... | Equationliu/GA-Attack | CrossEntropyLoss | false | 17,270 | [
"MIT"
] | 8 | b0280674a211f6451774ec6b1d4cee2fc19a4de6 | https://github.com/Equationliu/GA-Attack/tree/b0280674a211f6451774ec6b1d4cee2fc19a4de6 |
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
import torch.utils.data
assert_size_stride = torch._C._dynamo.guard... | JonasHell/torch-em | DiceLoss | false | 8,393 | [
"MIT"
] | 13 | 2e008e0cd2f0ea6681581374fce4f9f47b986d55 | https://github.com/JonasHell/torch-em/tree/2e008e0cd2f0ea6681581374fce4f9f47b986d55 |
Head | # 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... | Hcnaeg/DI-engine | Head | false | 2,386 | [
"Apache-2.0"
] | 0 | aba0c629f87649854091e9e59d948f83962e3e1e | https://github.com/Hcnaeg/DI-engine/tree/aba0c629f87649854091e9e59d948f83962e3e1e |
MLP | # AOT ID: ['0_forward']
from ctypes import c_void_p, c_long, c_int
import torch
import math
import random
import os
import tempfile
from math import inf, nan
from torch._inductor.hooks import run_intermediate_hooks
from torch._inductor.utils import maybe_profile
from torch._inductor.codegen.memory_planning import _alig... | import torch
from torch._inductor.select_algorithm import extern_kernels
import triton
import triton.language as tl
from torch._inductor.runtime.triton_heuristics import grid
from torch._C import _cuda_getCurrentRawStream as get_raw_stream
from torch import nn
assert_size_stride = torch._C._dynamo.guards.assert_size_st... | EmanuelNk/semantic-segmentation | MLP | false | 2,198 | [
"MIT"
] | 0 | 20ff16da49691fb407724909d9c7e84b47e2fee0 | https://github.com/EmanuelNk/semantic-segmentation/tree/20ff16da49691fb407724909d9c7e84b47e2fee0 |
NormalizationLayer | # 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.utils.data
assert_size_stride = torch._C._dynamo.guards.assert_siz... | hmtrii/tirg | NormalizationLayer | false | 10,161 | [
"Apache-2.0"
] | 0 | e404020795bb46fb01b6bd82a2618f9370174012 | https://github.com/hmtrii/tirg/tree/e404020795bb46fb01b6bd82a2618f9370174012 |
MSEloss_mod | import torch
import torch.nn as nn
class MSEloss_mod(nn.Module):
def __init__(self):
super(MSEloss_mod, self).__init__()
def forward(self, y_pred, y_gt):
muX = y_pred[:, :, 0]
muY = y_pred[:, :, 1]
x = y_gt[:, :, 0].permute(1, 0)
y = y_gt[:, :, 1].permute(1, 0)
... | 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... | DemainWang/TP2Net | MSEloss_mod | false | 11,337 | [
"MIT"
] | 0 | ebdd509ac674c107de59062382a9f9d59f86b492 | https://github.com/DemainWang/TP2Net/tree/ebdd509ac674c107de59062382a9f9d59f86b492 |
PatchMerging | import torch
import torchvision.transforms.functional as F
import torch.nn.functional as F
from torch import nn
class PatchMerging(nn.Module):
""" Patch Merging Layer
Args:
dim (int): Number of input channels.
norm_layer (nn.Module, optional): Normalization layer. Default: nn.LayerNorm
"... | 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... | XiaoJake/MTTR | PatchMerging | false | 14,610 | [
"Apache-2.0"
] | 516 | c383c5b151e3c97aeb45cd2fb4bf08719016498b | https://github.com/XiaoJake/MTTR/tree/c383c5b151e3c97aeb45cd2fb4bf08719016498b |
FeatureNet | # 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_... | KuangenZhang/StructuredRL | FeatureNet | false | 5,468 | [
"MIT"
] | 1 | 9b05e5034ff0e045aabf83786efb0859f08e989a | https://github.com/KuangenZhang/StructuredRL/tree/9b05e5034ff0e045aabf83786efb0859f08e989a |
GLU | # 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... | PaParaZz1/DI-engine | GLU | false | 11,847 | [
"Apache-2.0"
] | 0 | b38144117c1ebc6eb860d8637ec8866dfbcdf2de | https://github.com/PaParaZz1/DI-engine/tree/b38144117c1ebc6eb860d8637ec8866dfbcdf2de |
Discriminator | import torch
import numpy as np
from torch import nn
from torch.nn import functional as F
class Discriminator(nn.Module):
def __init__(self, img_shape, hidden_dim=1024):
super().__init__()
in_dim = int(np.prod(img_shape))
self.fc1 = nn.Linear(in_dim, hidden_dim)
self.fc2 = nn.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
import numpy as np
from torch import nn
assert_size_stride = torch._C._dynamo.gu... | Benjamin-Etheredge/lightning-bolts | Discriminator | false | 169 | [
"Apache-2.0"
] | 0 | 1971d6a924729940b98793aa7751bdf769350aca | https://github.com/Benjamin-Etheredge/lightning-bolts/tree/1971d6a924729940b98793aa7751bdf769350aca |
GlobalAvgPool1d | import torch
import torch.nn as nn
from abc import abstractmethod
from torch.nn import functional
class AvgPool(nn.Module):
"""
AvgPool Module.
"""
def __init__(self):
super().__init__()
@abstractmethod
def forward(self, input_tensor):
pass
class GlobalAvgPool1d(AvgPool):
... | 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 abc import abstractmethod
assert_size_stride = torch._C._dynamo.guards.assert_size_stride
empty_strided_cuda = to... | Yakings/AIPerf | GlobalAvgPool1d | false | 14,617 | [
"MIT"
] | 52 | 6e5c50a3b769ab4b1075aaab9841b5554f40bceb | https://github.com/Yakings/AIPerf/tree/6e5c50a3b769ab4b1075aaab9841b5554f40bceb |
QuickGELU | # 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... | Beximus/ResearchPortfolioCode | QuickGELU | false | 16,987 | [
"MIT"
] | 6 | db8343be6bbac361c3f6d01bbb82e458ff40f44e | https://github.com/Beximus/ResearchPortfolioCode/tree/db8343be6bbac361c3f6d01bbb82e458ff40f44e |
PatchApplier | # 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... | PJ-Steeman/2020_Masterproef | PatchApplier | false | 5,711 | [
"MIT"
] | 1 | 5bd77b4039a897d328fafe9a0b70dc8e593e2899 | https://github.com/PJ-Steeman/2020_Masterproef/tree/5bd77b4039a897d328fafe9a0b70dc8e593e2899 |
LinearNet | # 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_... | wslerry/regresstorch | LinearNet | false | 4,553 | [
"MIT"
] | 0 | b2e3507d8ed794e5d1d75ebfe910f74bbcb9a06b | https://github.com/wslerry/regresstorch/tree/b2e3507d8ed794e5d1d75ebfe910f74bbcb9a06b |
ImageGradients | import torch
import torch as th
import torch.utils.data
class ImageGradients(th.nn.Module):
"""
Args:
c_in(int): number of channels expected in the images.
use_sobel(bool): if True, uses a (smoother) Sobel filter instead of simple
finite differences.
"""
def __init__(self, c_in, use_sobel=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 as th
import torch.utils.data
assert_size_stride = torch._C._dynamo... | IlyaBizyaev/ttools | ImageGradients | false | 8,300 | [
"MIT"
] | 11 | b1435b19f397ce1baff9daed3cb287e52a029fdb | https://github.com/IlyaBizyaev/ttools/tree/b1435b19f397ce1baff9daed3cb287e52a029fdb |
MultiHeadAttention | import math
import torch
import torch.nn as nn
def dot_scaled_attention(query: 'torch.Tensor', key: 'torch.Tensor', value:
'torch.Tensor'):
""" Dot scaled attention
Implement dot-product scaled attention which takes query, key, value and gives attention scores.
Arguments:
query -- Query tensor
in shap... | 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.... | Giseung-Park/BlockSeq | MultiHeadAttention | false | 5,234 | [
"MIT"
] | 1 | 73dd55e6e500c765396fb7bcb514c9cbe7d799ac | https://github.com/Giseung-Park/BlockSeq/tree/73dd55e6e500c765396fb7bcb514c9cbe7d799ac |
KL_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.functi... | junyuchen245/TransMorph_Transformer_for_Medical_Image_Registration | KL_loss | false | 15,739 | [
"MIT"
] | 82 | dfa24a47a564a000aa9b4eea95a6e83a24568359 | https://github.com/junyuchen245/TransMorph_Transformer_for_Medical_Image_Registration/tree/dfa24a47a564a000aa9b4eea95a6e83a24568359 |
TwoLayerCNN | # 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_... | imvladikon/string-embed | TwoLayerCNN | false | 3,669 | [
"MIT"
] | 0 | 49e5ab0ada37b497dac51974aff16eeac65627a0 | https://github.com/imvladikon/string-embed/tree/49e5ab0ada37b497dac51974aff16eeac65627a0 |
BertLayerNorm | import torch
import torch.nn as nn
class BertLayerNorm(nn.Module):
def __init__(self, hidden_size, eps=1e-12):
"""Construct a layernorm module in the TF style (epsilon inside the square root).
"""
super(BertLayerNorm, self).__init__()
self.weight = nn.Parameter(torch.ones(hidden_s... | 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_... | AterhiM/BERT-E2E-ABSA | BertLayerNorm | false | 11,215 | [
"Apache-2.0"
] | 0 | 9266a851fd1d7164eb0fc422d3f5eb02e474080b | https://github.com/AterhiM/BERT-E2E-ABSA/tree/9266a851fd1d7164eb0fc422d3f5eb02e474080b |
FlawDetectorCriterion | # 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... | charlesCXK/PixelSSL | FlawDetectorCriterion | false | 1,658 | [
"Apache-2.0"
] | 0 | 2e85e12c1db5b24206bfbbf2d7f6348ae82b2105 | https://github.com/charlesCXK/PixelSSL/tree/2e85e12c1db5b24206bfbbf2d7f6348ae82b2105 |
SigmoidBCELoss | import torch
import torch.nn as nn
class SigmoidBCELoss(nn.BCEWithLogitsLoss):
def __init__(self, **kwargs):
super(SigmoidBCELoss, self).__init__(**kwargs)
def forward(self, input, target):
input = input.squeeze(1)
target = target.float()
return super(SigmoidBCELoss, self).fo... | 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... | azxj/BRRNet | SigmoidBCELoss | false | 6,306 | [
"MIT"
] | 1 | 274068efd5453f2c1fb07bfaad448d048b9c793b | https://github.com/azxj/BRRNet/tree/274068efd5453f2c1fb07bfaad448d048b9c793b |
ImpalaBlock | import torch
import torch.nn as nn
class ResidualBlock(nn.Module):
def __init__(self, in_channels):
super(ResidualBlock, self).__init__()
self.conv1 = nn.Conv2d(in_channels=in_channels, out_channels=
in_channels, kernel_size=3, stride=1, padding=1)
self.conv2 = nn.Conv2d(in_ch... | 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_... | abhay97ps/visual-control-ppo-procgen | ImpalaBlock | false | 1,362 | [
"MIT"
] | 0 | 765fe1ddb289d384abddc4df8eb865379c8da76a | https://github.com/abhay97ps/visual-control-ppo-procgen/tree/765fe1ddb289d384abddc4df8eb865379c8da76a |
ExternalAttention | import torch
from torch import nn
from torch.nn import init
class ExternalAttention(nn.Module):
def __init__(self, d_model, S=64):
super().__init__()
self.mk = nn.Linear(d_model, S, bias=False)
self.mv = nn.Linear(S, d_model, bias=False)
self.softmax = nn.Softmax(dim=1)
se... | 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.... | rushirajsherlocked/External-Attention-pytorch | ExternalAttention | false | 4,215 | [
"MIT"
] | 0 | 7d6814b2d90909adf81c62f3f8a89e30a59d6481 | https://github.com/rushirajsherlocked/External-Attention-pytorch/tree/7d6814b2d90909adf81c62f3f8a89e30a59d6481 |
SAB | import math
import torch
import torch.nn as nn
import torch.nn.functional as F
class MAB(nn.Module):
def __init__(self, dim_Q, dim_K, dim_V, num_heads, ln=False):
super(MAB, self).__init__()
self.dim_V = dim_V
self.num_heads = num_heads
self.fc_q = nn.Linear(dim_Q, dim_V)
... | 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 | SAB | false | 12,358 | [
"MIT"
] | 0 | 4b380106e1f43b7eb6315624c57d4d1d38737b78 | https://github.com/ernoult/set_transformer/tree/4b380106e1f43b7eb6315624c57d4d1d38737b78 |
FeatureEncoder | # 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_... | qbhan/pathembed | FeatureEncoder | false | 7,509 | [
"MIT"
] | 1 | c21823529840593bf606e10696f5879e5adb51b2 | https://github.com/qbhan/pathembed/tree/c21823529840593bf606e10696f5879e5adb51b2 |
Classifier_MLP | import torch
import torch.nn as nn
import torch.nn.functional as F
class Classifier_MLP(nn.Module):
def __init__(self, in_dim, hidden_dim, out_dim):
super(Classifier_MLP, self).__init__()
self.h1 = nn.Linear(in_dim, hidden_dim)
self.h2 = nn.Linear(hidden_dim, hidden_dim)
self.out ... | 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.... | CORE-Robotics-Lab/Personalized_Neural_Trees | Classifier_MLP | false | 17,037 | [
"MIT"
] | 3 | 3e8dd12fe4fc850be65c96c847eb143ef3bcdc2e | https://github.com/CORE-Robotics-Lab/Personalized_Neural_Trees/tree/3e8dd12fe4fc850be65c96c847eb143ef3bcdc2e |
_CMT_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.triton_helpers import libdevice
import torch.nn as nn
assert_size_stride = torch._C._dynamo.guards.assert_size_... | Jiangtong-Li/ZHSIR | _CMT_loss | false | 17,497 | [
"Apache-2.0"
] | 8 | fd2c0a7e79f22cbf565ccd5e13342f1b317ac9b7 | https://github.com/Jiangtong-Li/ZHSIR/tree/fd2c0a7e79f22cbf565ccd5e13342f1b317ac9b7 |
DCT | # 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 ... | adamkrekorian/CI-UNet | DCT | false | 1,372 | [
"MIT"
] | 0 | fab0f8806540f5d79911bd81ba54dff135f9814f | https://github.com/adamkrekorian/CI-UNet/tree/fab0f8806540f5d79911bd81ba54dff135f9814f |
_ASPPModule | # 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.... | huanglf714/COMatchNet | _ASPPModule | false | 6,832 | [
"Apache-2.0"
] | 1 | 79023f5be65d354eb9bdac026d7e0d73110bc4aa | https://github.com/huanglf714/COMatchNet/tree/79023f5be65d354eb9bdac026d7e0d73110bc4aa |
FullSelfAttn | # 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.... | ilyak93/SinGanF2 | FullSelfAttn | false | 12,534 | [
"MIT"
] | 0 | fa6b135ef4699626ce450afd02ed3b269e4ca16d | https://github.com/ilyak93/SinGanF2/tree/fa6b135ef4699626ce450afd02ed3b269e4ca16d |
NeuralNetMultiplePositionalArgumentsMultiOutputsWithDependency | # 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.... | almiliMSFT/onnxruntime | NeuralNetMultiplePositionalArgumentsMultiOutputsWithDependency | false | 14,820 | [
"MIT"
] | 6,036 | c002dc86a364852859ca9642698fcfc5edf22c9d | https://github.com/almiliMSFT/onnxruntime/tree/c002dc86a364852859ca9642698fcfc5edf22c9d |
QuantConv1d | # AOT ID: ['0_forward']
from ctypes import c_void_p, c_long, c_int
import torch
import math
import random
import os
import tempfile
from math import inf, nan
from torch._inductor.hooks import run_intermediate_hooks
from torch._inductor.utils import maybe_profile
from torch._inductor.codegen.memory_planning import _alig... | import torch
from torch._inductor.select_algorithm import extern_kernels
import triton
import triton.language as tl
from torch._inductor.runtime.triton_heuristics import grid
from torch._C import _cuda_getCurrentRawStream as get_raw_stream
from torch import nn
assert_size_stride = torch._C._dynamo.guards.assert_size_st... | TeaPoly/wenet | QuantConv1d | false | 2,875 | [
"Apache-2.0"
] | 0 | 5681887e338e4c8b2c75ffc283140e11a9d56a6d | https://github.com/TeaPoly/wenet/tree/5681887e338e4c8b2c75ffc283140e11a9d56a6d |
WordPredictor | # 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.... | vincentLiangBerkeley/translate | WordPredictor | false | 4,511 | [
"BSD-3-Clause"
] | 0 | 734ae1ad9dfb778935e4825b5ce2687e2df559ea | https://github.com/vincentLiangBerkeley/translate/tree/734ae1ad9dfb778935e4825b5ce2687e2df559ea |
minibatch_std_concat_layer | import copy
import torch
import torch.utils.data
from torch.utils import data as data
import torch.nn as nn
from torch.nn import init as init
from torchvision.models import vgg as vgg
from torch import autograd as autograd
class minibatch_std_concat_layer(nn.Module):
def __init__(self, averaging='all'):
... | 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.utils.data
from torch.utils import data as data
import torch.nn as... | achrefjarray/ESRGANplus-master | minibatch_std_concat_layer | false | 1,367 | [
"Apache-2.0"
] | 0 | ba470ec5c565a6dc8b48575b1e185ef6b796aec6 | https://github.com/achrefjarray/ESRGANplus-master/tree/ba470ec5c565a6dc8b48575b1e185ef6b796aec6 |
CoAttention | import torch
import torch.nn as nn
import torch.nn.functional as F
class CoAttention(nn.Module):
"""
CoAttention encoder
in Dynamic Coattention Networks For Question Answering (https://arxiv.org/abs/1611.01604)
check the Figure 2 in paper
* Args:
embed_dim: the number of input embedd... | 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.... | GMDennis/claf | CoAttention | false | 8,240 | [
"MIT"
] | 10 | d1e064e593127e5d654f000f5506c5ae1caab5ce | https://github.com/GMDennis/claf/tree/d1e064e593127e5d654f000f5506c5ae1caab5ce |
SimpleXorModule | # 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.jit
import torch.onnx
import torch.nn
assert_size_stride = torch._C._dynamo.guards.assert_size_stride
empty_strided_cuda = torc... | andreas-hommel/glow | SimpleXorModule | false | 3,365 | [
"Apache-2.0"
] | 0 | 2bbbf8188a2a941e85677c83f2146bbd076a262e | https://github.com/andreas-hommel/glow/tree/2bbbf8188a2a941e85677c83f2146bbd076a262e |
FeedForwardLayer | # 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... | yongho94/Transformers_NMT | FeedForwardLayer | false | 11,021 | [
"MIT"
] | 0 | 14fb08a6b1391da4d49f199dc16d7beb37620c98 | https://github.com/yongho94/Transformers_NMT/tree/14fb08a6b1391da4d49f199dc16d7beb37620c98 |
Critic | import torch
import torch.nn as nn
import torch.nn.functional as F
class Critic(nn.Module):
def __init__(self, state_dim, action_dim):
super(Critic, self).__init__()
self.l1 = nn.Linear(state_dim, 400)
self.l2 = nn.Linear(400 + action_dim, 300)
self.l3 = nn.Linear(300, 1)
def... | 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_... | dmund95/bcq | Critic | false | 6,594 | [
"MIT"
] | 1 | b1ae39ad7789443f02273aaa1a433c55c6836a5f | https://github.com/dmund95/bcq/tree/b1ae39ad7789443f02273aaa1a433c55c6836a5f |
MaskedLinearSeqDup | # 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.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 |
Clamp | # AOT ID: ['0_inference']
from ctypes import c_void_p, c_long, c_int
import torch
import math
import random
import os
import tempfile
from math import inf, nan
from torch._inductor.hooks import run_intermediate_hooks
from torch._inductor.utils import maybe_profile
from torch._inductor.codegen.memory_planning import _al... | import torch
import triton
import triton.language as tl
from torch._inductor.runtime.triton_heuristics import grid
from torch._C import _cuda_getCurrentRawStream as get_raw_stream
from torch._inductor.runtime import triton_helpers
import torch.nn as nn
import torch.distributed
import torch.distributions
assert_size_str... | Zed-Wu/ManiSkill-Learn | Clamp | false | 3,099 | [
"Apache-2.0"
] | 0 | 8056fe327752cd0863f8730672fe62bd85a0ec12 | https://github.com/Zed-Wu/ManiSkill-Learn/tree/8056fe327752cd0863f8730672fe62bd85a0ec12 |
_DynamicGates | # 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... | DavidChoi76/neuralhydrology | _DynamicGates | false | 15,626 | [
"BSD-3-Clause"
] | 144 | a4c284b92934ee973c8b3fedf8a60df60c8feae1 | https://github.com/DavidChoi76/neuralhydrology/tree/a4c284b92934ee973c8b3fedf8a60df60c8feae1 |
BertAttention | from _paritybench_helpers import _mock_config
import math
import torch
from torch import nn
import torch.utils.data
class BertSelfAttention(nn.Module):
def __init__(self, config):
super(BertSelfAttention, self).__init__()
if config.hidden_size % config.num_attention_heads != 0:
raise ... | 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.... | rahul-art/DeepSpeedExamples | BertAttention | false | 12,931 | [
"MIT"
] | 0 | f6b901516a336f91ee2a2dd735b9d20ab2c87d85 | https://github.com/rahul-art/DeepSpeedExamples/tree/f6b901516a336f91ee2a2dd735b9d20ab2c87d85 |
EqualLinear | # AOT ID: ['0_forward']
from ctypes import c_void_p, c_long, c_int
import torch
import math
import random
import os
import tempfile
from math import inf, nan
from torch._inductor.hooks import run_intermediate_hooks
from torch._inductor.utils import maybe_profile
from torch._inductor.codegen.memory_planning import _alig... | import torch
from torch._inductor.select_algorithm import extern_kernels
import triton
import triton.language as tl
from torch._inductor.runtime.triton_heuristics import grid
from torch._C import _cuda_getCurrentRawStream as get_raw_stream
from torch import nn
assert_size_stride = torch._C._dynamo.guards.assert_size_st... | yoona-ai/stylegan2-pytorch | EqualLinear | false | 16,761 | [
"MIT"
] | 2,954 | eceb8aacb669f19b79cc74c7160a85252b1086d6 | https://github.com/yoona-ai/stylegan2-pytorch/tree/eceb8aacb669f19b79cc74c7160a85252b1086d6 |
Classifier | # 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.... | ChengJiacheng/Applied-Deep-Learning-with-PyTorch | Classifier | false | 8,901 | [
"MIT"
] | 0 | 260d3ad3929705f615c758dd72f9539f390461bf | https://github.com/ChengJiacheng/Applied-Deep-Learning-with-PyTorch/tree/260d3ad3929705f615c758dd72f9539f390461bf |
PixLoss | # 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... | akanametov/SuperResolution | PixLoss | false | 6,135 | [
"MIT"
] | 1 | 45313d1309ddb5cdef821aaf5ac7b5ad574b5287 | https://github.com/akanametov/SuperResolution/tree/45313d1309ddb5cdef821aaf5ac7b5ad574b5287 |
HardMGUCellPT | import math
import torch
from torch import Tensor
import torch.nn as nn
import torch.nn.functional as F
from typing import Optional
import torch.nn.parallel
import torch.optim
import torch.utils.data
import torch.utils.data.distributed
def truncated_normal(t, mean=0.0, std=0.01):
torch.nn.init.normal_(t, mean=mea... | 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... | pan185/UnarySim | HardMGUCellPT | false | 7,463 | [
"MIT"
] | 1 | c03386efdbb8151f3c33f34b44d1d6a6fc960434 | https://github.com/pan185/UnarySim/tree/c03386efdbb8151f3c33f34b44d1d6a6fc960434 |
hsigmoid | # 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.onnx
import torch
import torch.nn as nn
assert_size_stride = torch._C._dynam... | LukasKratochvila/pytorch-ssd | hsigmoid | false | 2,583 | [
"MIT"
] | 0 | de6ed2be6ce0b03634d4cbf41622cfe5c87d077c | https://github.com/LukasKratochvila/pytorch-ssd/tree/de6ed2be6ce0b03634d4cbf41622cfe5c87d077c |
Snake | # AOT ID: ['0_forward']
from ctypes import c_void_p, c_long, c_int
import torch
import math
import random
import os
import tempfile
from math import inf, nan
from torch._inductor.hooks import run_intermediate_hooks
from torch._inductor.utils import maybe_profile
from torch._inductor.codegen.memory_planning import _alig... | import torch
import triton
import triton.language as tl
from torch._inductor.runtime.triton_heuristics import grid
from torch._C import _cuda_getCurrentRawStream as get_raw_stream
from torch._inductor.runtime.triton_helpers import math as tl_math
import torch.nn as nn
assert_size_stride = torch._C._dynamo.guards.assert... | ComputationalRadiationPhysics/NeuralSolvers | Snake | false | 13,518 | [
"MIT"
] | 59 | cc62b5a91d9eb70ffafdcca6d1fbba16d3bf588d | https://github.com/ComputationalRadiationPhysics/NeuralSolvers/tree/cc62b5a91d9eb70ffafdcca6d1fbba16d3bf588d |
ExtResNetBlock | # AOT ID: ['0_forward']
from ctypes import c_void_p, c_long, c_int
import torch
import math
import random
import os
import tempfile
from math import inf, nan
from torch._inductor.hooks import run_intermediate_hooks
from torch._inductor.utils import maybe_profile
from torch._inductor.codegen.memory_planning import _alig... | import torch
from torch._inductor.select_algorithm import extern_kernels
import triton
import triton.language as tl
from torch._inductor.runtime.triton_heuristics import grid
from torch._C import _cuda_getCurrentRawStream as get_raw_stream
from torch._inductor.runtime.triton_helpers import libdevice
from torch import n... | charmsoya/pytorch-3dunet | ExtResNetBlock | false | 9,887 | [
"MIT"
] | 0 | 07a8dabf988ac3df110a3c10db6ed5fb769498d9 | https://github.com/charmsoya/pytorch-3dunet/tree/07a8dabf988ac3df110a3c10db6ed5fb769498d9 |
SparsityLoss | # 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... | kingsj0405/Explorable-Super-Resolution | SparsityLoss | false | 15,833 | [
"Apache-2.0"
] | 54 | 6582477ec1e2b0c6f4bd781552ac880fabdb4496 | https://github.com/kingsj0405/Explorable-Super-Resolution/tree/6582477ec1e2b0c6f4bd781552ac880fabdb4496 |
NormedConv2d | import torch
from torch import nn
class NormedConv2d(nn.Conv2d):
"""Normalized Conv2d 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 of divisor to
keep ... | 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... | LiuXiaoxuanPKU/mmdetection | NormedConv2d | false | 11,649 | [
"Apache-2.0"
] | 0 | 05b46eccbe5c4953d5a406f545fe529ce4e146d3 | https://github.com/LiuXiaoxuanPKU/mmdetection/tree/05b46eccbe5c4953d5a406f545fe529ce4e146d3 |
Discriminator | import torch
import torch.nn as nn
class Discriminator(nn.Module):
def __init__(self):
super(Discriminator, self).__init__()
self.linear1 = nn.Linear(784, 512)
self.lrelu2 = nn.LeakyReLU(0.2)
self.linear2 = nn.Linear(512, 256)
self.lrelu3 = nn.LeakyReLU(0.2)
self.l... | 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... | davide-belli/deep-learning-labs | Discriminator | false | 1,800 | [
"MIT"
] | 0 | 1acd37a527711dccdc00c1935724cc5de7c10955 | https://github.com/davide-belli/deep-learning-labs/tree/1acd37a527711dccdc00c1935724cc5de7c10955 |
MSELoss | import torch
import torch.nn as nn
import torch.nn.parallel
import torch.optim
import torch.utils.data
import torch.nn.functional as F
class MSELoss(nn.Module):
def __init__(self, ratio=1, size_average=None, reduce=None, reduction=
'mean'):
super(MSELoss, self).__init__()
self.ratio = rat... | 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... | Karenou/mmfashion | MSELoss | false | 9,471 | [
"Apache-2.0"
] | 0 | dfc334232d1700cde18d144f983dd5b0a7f9852a | https://github.com/Karenou/mmfashion/tree/dfc334232d1700cde18d144f983dd5b0a7f9852a |
handpose_model | import torch
from collections import OrderedDict
import torch.nn as nn
def make_layers(block, no_relu_layers):
layers = []
for layer_name, v in block.items():
if 'pool' in layer_name:
layer = nn.MaxPool2d(kernel_size=v[0], stride=v[1], padding=v[2])
layers.append((layer_name, l... | 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 collections import Order... | alanlee-chn/handpose-est | handpose_model | false | 6,201 | [
"MIT"
] | 1 | 241a6beb45e045e65a328aade22ce536f4dcd893 | https://github.com/alanlee-chn/handpose-est/tree/241a6beb45e045e65a328aade22ce536f4dcd893 |
CecaModule | import math
import torch
import torch.nn as nn
from torch.nn import functional as F
import torch.nn.parallel
class CecaModule(nn.Module):
"""Constructs a circular ECA module.
ECA module where the conv uses circular padding rather than zero padding.
Unlike the spatial dimension, the channels do not have 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
import math
import torch.nn as nn
import torch.nn.parallel
assert_size_stride = ... | Fanzhongjie/ARFE | CecaModule | false | 459 | [
"Apache-2.0"
] | 0 | 4b96b8c5bc0895d3d30acec2a490f81a860fe860 | https://github.com/Fanzhongjie/ARFE/tree/4b96b8c5bc0895d3d30acec2a490f81a860fe860 |
PreActBlockNoBN | # 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_... | Spijkervet/Greedy_InfoMax | PreActBlockNoBN | false | 5,846 | [
"MIT"
] | 1 | d1784da7995e029d07691ee0977fea49383fb0f8 | https://github.com/Spijkervet/Greedy_InfoMax/tree/d1784da7995e029d07691ee0977fea49383fb0f8 |
L1DepthLoss | # 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... | wanyao1992/structural-probes | L1DepthLoss | false | 16,693 | [
"Apache-2.0"
] | 357 | 3071c93b23601d834628d79a74e46e8ab5e5a66b | https://github.com/wanyao1992/structural-probes/tree/3071c93b23601d834628d79a74e46e8ab5e5a66b |
TokenEmbedding | import torch
import torch.nn as nn
import torch.fft
class TokenEmbedding(nn.Module):
def __init__(self, c_in, d_model):
super(TokenEmbedding, self).__init__()
padding = 1 if torch.__version__ >= '1.5.0' else 2
self.tokenConv = nn.Conv1d(in_channels=c_in, out_channels=d_model,
... | 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.fft
assert_size_stride = torch._C._dynamo.gua... | jianzhnie/TsFormer | TokenEmbedding | false | 3,727 | [
"Apache-2.0"
] | 0 | 47e362f02445ba00d5ab8db206667767e72faca7 | https://github.com/jianzhnie/TsFormer/tree/47e362f02445ba00d5ab8db206667767e72faca7 |
PositionalWiseFeedForward | import math
import torch
import torch.nn as nn
class GELU(nn.Module):
"""
This is a smoother version of the RELU.
Original paper: https://arxiv.org/abs/1606.08415
"""
def forward(self, x):
return 0.5 * x * (1 + torch.tanh(math.sqrt(2 / math.pi) * (x +
0.044715 * torch.pow(x, ... | import torch
from torch._inductor.select_algorithm import extern_kernels
import triton
import triton.language as tl
from torch._inductor.runtime.triton_heuristics import grid
from torch._C import _cuda_getCurrentRawStream as get_raw_stream
from torch._inductor.runtime import triton_helpers
from torch._inductor.runtime.... | JiaweiSheng/FAAN | PositionalWiseFeedForward | false | 8,354 | [
"MIT"
] | 41 | b439b829506c4e2e9044a6b2ab7f3d844f445a95 | https://github.com/JiaweiSheng/FAAN/tree/b439b829506c4e2e9044a6b2ab7f3d844f445a95 |
FusedLeakyReLU | # 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 import nn
assert_size_stride = torch._C._dynamo.guards.assert_size_stride
empty_strided_cuda = torch._C._dynamo.guards._empty_str... | delldu/StyleGAN2 | FusedLeakyReLU | false | 6,547 | [
"MIT",
"BSD-2-Clause",
"Apache-2.0"
] | 1 | 4bcba4673d3dc32ac3a67f6b5d5e24b490cdfbb3 | https://github.com/delldu/StyleGAN2/tree/4bcba4673d3dc32ac3a67f6b5d5e24b490cdfbb3 |
Critic | # 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 ... | Kelym/TD3 | Critic | false | 9,194 | [
"MIT"
] | 0 | ea565c9d6f74aeb47b096538274cbd5ffc657de5 | https://github.com/Kelym/TD3/tree/ea565c9d6f74aeb47b096538274cbd5ffc657de5 |
Discriminator | import torch
import torch.nn as nn
class Discriminator(nn.Module):
"""
The discriminator
.. math::
\\begin{equation}
\\mathcal{D}\\left(\\mathbf{h}_{i}^{(r)}, \\mathbf{s}^{(r)}\\right)=\\sigma\\left(\\mathbf{h}_{i}^{(r) T} \\mathbf{M}^{(r)} \\mathbf{s}^{(r)}\\right)
\\end{equation}
... | 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... | Xinstein3033/OpenHGNN | Discriminator | false | 1,246 | [
"Apache-2.0"
] | 0 | a9ca499834523419ecdaaa09e4b42f640486f262 | https://github.com/Xinstein3033/OpenHGNN/tree/a9ca499834523419ecdaaa09e4b42f640486f262 |
AdaIN | import math
import torch
import torch.nn as nn
from numpy import prod
def getLayerNormalizationFactor(x):
"""
Get He's constant for the given layer
https://www.cv-foundation.org/openaccess/content_iccv_2015/papers/He_Delving_Deep_into_ICCV_2015_paper.pdf
"""
size = x.weight.size()
fan_in = pro... | 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.... | GiangHLe/pytorch_GAN_zoo | AdaIN | false | 11,477 | [
"BSD-3-Clause"
] | 0 | 7a3db2a88032f357b3f262abd6204b560caa9f2c | https://github.com/GiangHLe/pytorch_GAN_zoo/tree/7a3db2a88032f357b3f262abd6204b560caa9f2c |
CQAttention | # 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.... | IsaacChanghau/VSLNet | CQAttention | false | 13,885 | [
"MIT"
] | 62 | 3793c625f2e251a5f19a0d59f0c83b12e386f808 | https://github.com/IsaacChanghau/VSLNet/tree/3793c625f2e251a5f19a0d59f0c83b12e386f808 |
GMM_Module | # 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
import torch.utils.data
assert_size_stride = t... | wemozj/Image-Compression-based-GMM-and-Attention-Module | GMM_Module | false | 4,525 | [
"Apache-2.0"
] | 0 | 93f804dbcea8ffc1621456f3d104d0342c75373b | https://github.com/wemozj/Image-Compression-based-GMM-and-Attention-Module/tree/93f804dbcea8ffc1621456f3d104d0342c75373b |
UPChannelRPN | # 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.functional as F
import torch.nn as nn
assert_size_stride = torch... | IRASatUC/pysot | UPChannelRPN | false | 2,599 | [
"Apache-2.0"
] | 0 | 2bbc5c0938b56899e5caead84983e3311f1d1911 | https://github.com/IRASatUC/pysot/tree/2bbc5c0938b56899e5caead84983e3311f1d1911 |
FocalLoss | import torch
import torch.nn as nn
import torch.optim
class FocalLoss(torch.nn.Module):
"""Sigmoid focal cross entropy loss.
Focal loss down-weights well classified examples and focusses on the hard
examples. See https://arxiv.org/pdf/1708.02002.pdf for the loss definition.
"""
def __init__(self, gamma... | 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... | neuralsyn/self-supervised-relational-reasoning | FocalLoss | false | 16,155 | [
"MIT"
] | 130 | 6ecfafcf4a36c2eacef7ddd5bd1b23c28fbb14c8 | https://github.com/neuralsyn/self-supervised-relational-reasoning/tree/6ecfafcf4a36c2eacef7ddd5bd1b23c28fbb14c8 |
FlowEntropy | # 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
... | NeelayS/ezflow | FlowEntropy | false | 14,098 | [
"MIT"
] | 94 | b93a48c4adf5021f7eacbfc43220c7efa5ae55cd | https://github.com/NeelayS/ezflow/tree/b93a48c4adf5021f7eacbfc43220c7efa5ae55cd |
DenseConvBlock | # 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... | Lornatang/SRDenseNet-PyTorch | DenseConvBlock | false | 17,633 | [
"Apache-2.0"
] | 4 | d7876bda4c48195a3652aed4e207f7509ac23e4b | https://github.com/Lornatang/SRDenseNet-PyTorch/tree/d7876bda4c48195a3652aed4e207f7509ac23e4b |
CharbonnierLoss | # 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 functools
from torch.... | Jason-Khan/mmediting | CharbonnierLoss | false | 617 | [
"Apache-2.0"
] | 0 | d187f95a675dff3eb975a575bd9278d643b5b645 | https://github.com/Jason-Khan/mmediting/tree/d187f95a675dff3eb975a575bd9278d643b5b645 |
KLDLossWithStandardGaussian | # 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
... | atmacvit/meronymnet | KLDLossWithStandardGaussian | false | 6,267 | [
"MIT"
] | 1 | 47e1a7caadc0f770439bb26a93b885f790f62804 | https://github.com/atmacvit/meronymnet/tree/47e1a7caadc0f770439bb26a93b885f790f62804 |
AdaptiveCatAvgMaxPool2d | import torch
import torch.nn as nn
import torch.nn.functional as F
import torch.nn.parallel
import torch._utils
import torch.optim
def adaptive_catavgmax_pool2d(x, output_size=1):
x_avg = F.adaptive_avg_pool2d(x, output_size)
x_max = F.adaptive_max_pool2d(x, output_size)
return torch.cat((x_avg, x_max), 1... | 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.functional as F
import torch.nn.parallel
import tor... | Alicegaz/torchok | AdaptiveCatAvgMaxPool2d | false | 16,923 | [
"Apache-2.0"
] | 8 | 7b8f95df466a25b1ad8ee93bed1a3c7516440cf4 | https://github.com/Alicegaz/torchok/tree/7b8f95df466a25b1ad8ee93bed1a3c7516440cf4 |
SimpleSinModule | import torch
import torch.jit
import torch.onnx
import torch.nn
class SimpleSinModule(torch.nn.Module):
def __init__(self):
super(SimpleSinModule, self).__init__()
def forward(self, a):
return torch.sin(a + a)
def get_inputs():
return [torch.rand([4, 4, 4, 4])]
def get_init_inputs():... | 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... | andreas-hommel/glow | SimpleSinModule | false | 3,358 | [
"Apache-2.0"
] | 0 | 2bbbf8188a2a941e85677c83f2146bbd076a262e | https://github.com/andreas-hommel/glow/tree/2bbbf8188a2a941e85677c83f2146bbd076a262e |
SingleBlock | # 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.... | Ruiver/CTCNet | SingleBlock | false | 17,954 | [
"Apache-2.0"
] | 6 | 539e55ec9fed06028379d35dfd5cd4074755ffd8 | https://github.com/Ruiver/CTCNet/tree/539e55ec9fed06028379d35dfd5cd4074755ffd8 |
Chebyshev_GL | # 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.nn import Module
import math
from torch.nn.modules import Module
from... | Brain03Yao/M2TGCN | Chebyshev_GL | false | 17,005 | [
"MIT"
] | 6 | 72c65687fa52c618740cd6d1db7366116f68398c | https://github.com/Brain03Yao/M2TGCN/tree/72c65687fa52c618740cd6d1db7366116f68398c |
CReLU | # 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... | And1210/FER_SSL | CReLU | false | 1,935 | [
"MIT"
] | 0 | 6cad839261667dce30a8b9db9638ef7334953063 | https://github.com/And1210/FER_SSL/tree/6cad839261667dce30a8b9db9638ef7334953063 |
DPRNNCell | # 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 math
import ... | romovpa/opacus | DPRNNCell | false | 10,857 | [
"Apache-2.0"
] | 0 | 9cda8072e52049a06afba7ab524276bb6613a727 | https://github.com/romovpa/opacus/tree/9cda8072e52049a06afba7ab524276bb6613a727 |
BertPooler | from _paritybench_helpers import _mock_config
import torch
import torch.nn as nn
class BertPooler(nn.Module):
def __init__(self, config):
super(BertPooler, self).__init__()
self.dense = nn.Linear(config.hidden_size, config.hidden_size)
self.activation = nn.Tanh()
def forward(self, hi... | 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 ... | Aksh97/VGCN-BERT | BertPooler | false | 14,809 | [
"MIT"
] | 106 | 62b5ae5a3c53f4bff555027d87a57d3a994a32bb | https://github.com/Aksh97/VGCN-BERT/tree/62b5ae5a3c53f4bff555027d87a57d3a994a32bb |
CNNCifaro | from _paritybench_helpers import _mock_config
import torch
import torch.nn as nn
import torch.nn.functional as F
class CNNCifaro(nn.Module):
def __init__(self, args):
super(CNNCifaro, self).__init__()
self.conv1 = nn.Conv2d(3, 32, 3)
self.pool = nn.MaxPool2d(2, 2)
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 import triton_helpers
import torch.nn as nn
assert_... | NaiboWang/Federated-Learning-PyTorch | CNNCifaro | false | 5,685 | [
"MIT"
] | 1 | 6f811ebbb783b9d279e5462789ff242968e17bc0 | https://github.com/NaiboWang/Federated-Learning-PyTorch/tree/6f811ebbb783b9d279e5462789ff242968e17bc0 |
InverseDepthSmoothnessLoss | import torch
import torch.nn as nn
class InverseDepthSmoothnessLoss(nn.Module):
"""Criterion that computes image-aware inverse depth smoothness loss.
.. math::
\\text{loss} = \\left | \\partial_x d_{ij} \\right | e^{-\\left \\|
\\partial_x I_{ij} \\right \\|} + \\left |
\\partial_y 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
from torch._inductor.runtime.triton_helpers import math as tl_math
import torch.nn as nn
assert_size_stride = torch._C._dynamo.guards.assert... | MareenaKunjachan/kornia | InverseDepthSmoothnessLoss | false | 2,666 | [
"Apache-2.0"
] | 0 | 0a3cbb02850ac78059e0615da93144b5a64d3330 | https://github.com/MareenaKunjachan/kornia/tree/0a3cbb02850ac78059e0615da93144b5a64d3330 |
Vflip | # AOT ID: ['0_inference']
from ctypes import c_void_p, c_long, c_int
import torch
import math
import random
import os
import tempfile
from math import inf, nan
from torch._inductor.hooks import run_intermediate_hooks
from torch._inductor.utils import maybe_profile
from torch._inductor.codegen.memory_planning import _al... | import torch
import triton
import triton.language as tl
from torch._inductor.runtime.triton_heuristics import grid
from torch._C import _cuda_getCurrentRawStream as get_raw_stream
import torch.nn as nn
assert_size_stride = torch._C._dynamo.guards.assert_size_stride
empty_strided_cuda = torch._C._dynamo.guards._empty_st... | JoanFM/kornia | Vflip | false | 11,559 | [
"ECL-2.0",
"Apache-2.0"
] | 0 | 808898887cde69074ca3e3df9b24dea9682aad90 | https://github.com/JoanFM/kornia/tree/808898887cde69074ca3e3df9b24dea9682aad90 |
LinearConvNet | import torch
import torch.nn as nn
class LinearConvNet(nn.Module):
def __init__(self):
super(LinearConvNet, self).__init__()
self.conv1 = nn.Conv2d(1, 5, 3, 1)
self.conv2 = nn.Conv2d(1, 3, 2, 1, bias=False)
def forward(self, x):
conv1_out = self.conv1(x)
conv2_out = s... | import torch
from torch._inductor.select_algorithm import extern_kernels
import triton
import triton.language as tl
from torch._inductor.runtime.triton_heuristics import grid
from torch._C import _cuda_getCurrentRawStream as get_raw_stream
import torch.nn as nn
assert_size_stride = torch._C._dynamo.guards.assert_size_s... | amyami187/nngeometry | LinearConvNet | false | 14,842 | [
"MIT"
] | 103 | cb516da3f7a019e148f48ff3ef3bed0cdae0d184 | https://github.com/amyami187/nngeometry/tree/cb516da3f7a019e148f48ff3ef3bed0cdae0d184 |
Linear_1L | # 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 ... | Neronjust2017/Bayesian-neural-networks | Linear_1L | false | 17,765 | [
"MIT"
] | 4 | 9d7f781f5c2dfa8fadf26300b4b5b64366c939cd | https://github.com/Neronjust2017/Bayesian-neural-networks/tree/9d7f781f5c2dfa8fadf26300b4b5b64366c939cd |
Decoder | # AOT ID: ['0_forward']
from ctypes import c_void_p, c_long, c_int
import torch
import math
import random
import os
import tempfile
from math import inf, nan
from torch._inductor.hooks import run_intermediate_hooks
from torch._inductor.utils import maybe_profile
from torch._inductor.codegen.memory_planning import _alig... | import torch
from torch._inductor.select_algorithm import extern_kernels
import triton
import triton.language as tl
from torch._inductor.runtime.triton_heuristics import grid
from torch._C import _cuda_getCurrentRawStream as get_raw_stream
from torch._inductor.runtime import triton_helpers
from torch._inductor.runtime.... | YoshikiMas/YoshikiMas-speech-enhancement-with-pytorch-lightning | Decoder | false | 18,154 | [
"MIT"
] | 5 | 8fcb78cbf64cb61dd9d2dd9e1118a1aa1992dd65 | https://github.com/YoshikiMas/YoshikiMas-speech-enhancement-with-pytorch-lightning/tree/8fcb78cbf64cb61dd9d2dd9e1118a1aa1992dd65 |
ConvBnRelu | import torch
import torch.nn as nn
import torch.nn.parallel
import torch.optim
import torch.utils.data
import torch.utils.data.distributed
class ConvBnRelu(nn.Module):
"""
A block of convolution, relu, batchnorm
"""
def __init__(self, in_channels, out_channels, kernel_size=1, stride=1,
pa... | 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.... | SkywalkerAtlas/HRGAN | ConvBnRelu | false | 5,835 | [
"MIT"
] | 1 | bf6d58c1f3c6e042c7ea70319a25e3420531d552 | https://github.com/SkywalkerAtlas/HRGAN/tree/bf6d58c1f3c6e042c7ea70319a25e3420531d552 |
Module | from torch.nn import Module
import torch
import torch.cuda
import torch.backends.cudnn
import torch.backends.mkl
class Module(torch.nn.Module):
def __init__(self):
super(Module, self).__init__()
self.conv = torch.nn.Conv2d(1, 10, 5, 1)
def forward(self, x):
y = self.conv(x)
r... | import torch
from torch._inductor.select_algorithm import extern_kernels
import triton
import triton.language as tl
from torch._inductor.runtime.triton_heuristics import grid
from torch._C import _cuda_getCurrentRawStream as get_raw_stream
import torch.cuda
import torch.backends.cudnn
import torch.backends.mkl
assert_s... | JudeDavis1/intel-extension-for-pytorch | Module | false | 2,587 | [
"Apache-2.0"
] | 0 | 364e34cb4917a709f5108c07d4005bf82f3d5067 | https://github.com/JudeDavis1/intel-extension-for-pytorch/tree/364e34cb4917a709f5108c07d4005bf82f3d5067 |
Biaffine | # AOT ID: ['0_forward']
from ctypes import c_void_p, c_long, c_int
import torch
import math
import random
import os
import tempfile
from math import inf, nan
from torch._inductor.hooks import run_intermediate_hooks
from torch._inductor.utils import maybe_profile
from torch._inductor.codegen.memory_planning import _alig... | import torch
from torch._inductor.select_algorithm import extern_kernels
import triton
import triton.language as tl
from torch._inductor.runtime.triton_heuristics import grid
from torch._C import _cuda_getCurrentRawStream as get_raw_stream
import torch.utils.data.dataloader
import torch.nn as nn
import torch.nn
assert_... | Dadmatech/DadmaTools | Biaffine | false | 7,973 | [
"Apache-2.0"
] | 25 | c1b7add5c33544f69c1ba1c5250a5ea07caf9aa2 | https://github.com/Dadmatech/DadmaTools/tree/c1b7add5c33544f69c1ba1c5250a5ea07caf9aa2 |
ConvNet | # 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.... | citelab/fastsync | ConvNet | false | 1,721 | [
"Apache-2.0"
] | 0 | 8e2166f87fc53479b57fef536a971c3a2e6e4309 | https://github.com/citelab/fastsync/tree/8e2166f87fc53479b57fef536a971c3a2e6e4309 |
ReverseMaskConv | # 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.... | delldu/ImagePatch | ReverseMaskConv | false | 6,554 | [
"MIT"
] | 1 | aaeadba9fe9f40e9bf900468f100a06bafc8231f | https://github.com/delldu/ImagePatch/tree/aaeadba9fe9f40e9bf900468f100a06bafc8231f |
EdgeLoss | import torch
import torch.nn as nn
import torch.nn.functional as F
def cross_entropy(logits, labels):
return torch.mean((1 - labels) * logits + torch.log(1 + torch.exp(-logits))
)
class EdgeLoss(nn.Module):
def __init__(self):
super().__init__()
laplace = torch.FloatTensor([[-1, -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.triton_helpers import libdevice, math as tl_math
im... | Mhaiyang/TCSVT2021_DCENet | EdgeLoss | false | 17,722 | [
"BSD-3-Clause"
] | 4 | aae8c7643402c15847836c0ce4934b743e11fd8a | https://github.com/Mhaiyang/TCSVT2021_DCENet/tree/aae8c7643402c15847836c0ce4934b743e11fd8a |
L2Norm | # 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_... | CharlesPikachu/mcibi | L2Norm | false | 7,890 | [
"MIT"
] | 41 | 6ce453504741c2eed1d290306055258a377a4094 | https://github.com/CharlesPikachu/mcibi/tree/6ce453504741c2eed1d290306055258a377a4094 |
rec_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.... | Luma-1994/lama | rec_attention | false | 14,405 | [
"MIT"
] | 137 | 60d802e2e4cce789f03eea11b038212ba5f7fd1b | https://github.com/Luma-1994/lama/tree/60d802e2e4cce789f03eea11b038212ba5f7fd1b |
_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 ... | xxchenxx/fastmoe | _FakeMegatronMLP | false | 13,131 | [
"Apache-2.0"
] | 0 | f60dd0e1f9f0447e56ff265c9ede304b88d0556b | https://github.com/xxchenxx/fastmoe/tree/f60dd0e1f9f0447e56ff265c9ede304b88d0556b |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.