PyTorch eager
PyTorch · python · MIT
Kernel source · 33 lines ↓holds 1 record
Use it
Vendorable · source mirrored · MITView source →
No package. Vendor the mirrored source: 33 lines, MIT.
78_ConvTranspose3d_Max_Max_Sum.py
curl "https://kernelindex.com/api/v1/implementations/kernelbench-l2-78-convtranspose3d-max-max-sum-torch?include=source"interfacepython · torch_eager
symbolModel.forward
Compatibility
measured onNVIDIA H100
declared hardwaredeclared only
architectures—
dtypes
Benchmark evidence
2 measurements across 1 GPU, fastest first.
Operation / workload
Hardware
Latency
Rank
Observed
Reported · How evidence levels are derived →
Source and license
sourceavailable
revision digestsha256:f5abc73304db7cee36687937d1c483dc13b5342c4815c79de9216a76d0cfead1
license declaredMIT
license concludedMIT
imported2026-08-26
Kernel source
78_ConvTranspose3d_Max_Max_Sum.py33 lines
import torch
import torch.nn as nn
class Model(nn.Module):
"""
Model that performs a 3D transposed convolution, followed by two max pooling layers and a sum operation.
"""
def __init__(self, in_channels, out_channels, kernel_size, stride, padding):
super(Model, self).__init__()
self.conv_transpose = nn.ConvTranspose3d(in_channels, out_channels, kernel_size, stride=stride, padding=padding)
self.max_pool1 = nn.MaxPool3d(kernel_size=2)
self.max_pool2 = nn.MaxPool3d(kernel_size=3)
def forward(self, x):
x = self.conv_transpose(x)
x = self.max_pool1(x)
x = self.max_pool2(x)
x = torch.sum(x, dim=1, keepdim=True)
return x
batch_size = 16
in_channels = 32
out_channels = 64
depth, height, width = 32, 32, 32
kernel_size = 5
stride = 2
padding = 2
def get_inputs():
return [torch.rand(batch_size, in_channels, depth, height, width)]
def get_init_inputs():
return [in_channels, out_channels, kernel_size, stride, padding]scrolls · 33 lines total
Source code from KernelBench, © 2023 Anne Ouyang, Simon Guo, Azalia Mirhoseini (Scaling Intelligence Lab, Stanford University), MIT License · MIT
Best evidence level for this revision: reported
JSON