Models / resnet-50

ResNet-50

The 50-layer residual network (v1.5) for ImageNet-1k: a 7x7 stem, four stages of bottleneck blocks 3, 4, 6, and 3 deep, and a linear classifier.

25.6M parametersresnetApache-2.0image-classificationvisionconvolutional

NVIDIA H100 80GB HBM3 · median of 10 runs after 3 warm-ups · measured 2026-09-28T18:51:38+00:00

Linnet 0.1.0, PyTorch 2.14.0, JAX 0.11.2, transformers 5.17.0, diffusers 0.40.0, ONNX Runtime 1.30.0, Python 3.12.3, driver 580.126.09

Linnet against the stack it replaces

Each side in its fastest configuration, on the same GPU and checkpoint. A speed-up is how many times the other's speed; an export is measured against the original checkpoint in the same engine.

vs the reference, in PyTorch1.89× fasterlatency
  • Linnet, CUDA graphs0.68 mstransformers, compiled1.29 ms
vs torch.onnx, on ONNX Runtime0.87× slowerlatency
  • Linnet, ONNX Runtime f321.28 mstorch.onnx export1.11 ms
vs torch.onnx, behind Triton0.79× slowerlatency
  • Triton, Linnet's ONNX3.33 msTriton, torch.onnx export2.62 ms

Each row also carries its distance from reference: the largest absolute difference between its output and transformers (eager)'s on the same input. bf16 outputs differ by rounding (about 0.1 on logits near 16), so a small number is expected; it is there so that a fast wrong answer cannot look like a win.

Latency

ms, lower is better; the best bar is red.

PyTorchJAXONNX Runtime and TensorRTTriton Inference Server0123mstransformers2.94 mstransformers, compiled1.29 msLinnet, generated PyTorch2.13 msLinnet, inductor1.29 msLinnet, CUDA graphs0.68 msLinnet, XLA (StableHLO)0.93 msLinnet, XLA (generated JAX)1.17 mstorch.onnx export1.11 msLinnet, ONNX Runtime f321.28 msLinnet, ONNX Runtime f161.00 msLinnet, ONNX Runtime bf161.66 msLinnet, TensorRT f320.53 msLinnet, TensorRT f160.41 msLinnet, TensorRT bf161.00 msTriton, torch.onnx export2.62 msTriton, Linnet's ONNX3.33 msTriton, Linnet Python backend3.04 ms

Throughput

/s, higher is better; the best bar is red.

PyTorchJAXONNX Runtime and TensorRTTriton Inference Server01000020000/stransformers7,141/stransformers, compiled11,054/sLinnet, generated PyTorch7,066/sLinnet, inductor11,138/sLinnet, CUDA graphs11,583/sLinnet, XLA (StableHLO)15,014/sLinnet, XLA (generated JAX)13,563/storch.onnx export5,416/sLinnet, ONNX Runtime f324,510/sLinnet, ONNX Runtime f167,354/sLinnet, ONNX Runtime bf163,698/sLinnet, TensorRT f3214,519/sLinnet, TensorRT f1625,153/sLinnet, TensorRT bf166,078/sTriton, torch.onnx export1,354/sTriton, Linnet's ONNX1,308/sTriton, Linnet Python backend1,258/s

Load time

s, lower is better; the best bar is red.

PyTorchJAXONNX Runtime and TensorRTTriton Inference Server051015stransformers7.20 stransformers, compiled4.09 sLinnet, generated PyTorch1.22 sLinnet, inductor1.39 sLinnet, CUDA graphs1.44 sLinnet, XLA (StableHLO)0.64 sLinnet, XLA (generated JAX)0.86 storch.onnx export15.5 sLinnet, ONNX Runtime f320.29 sLinnet, ONNX Runtime f160.30 sLinnet, ONNX Runtime bf160.28 sLinnet, TensorRT f320.29 sLinnet, TensorRT f160.30 sLinnet, TensorRT bf160.29 sTriton, torch.onnx export5.07 sTriton, Linnet's ONNX13.1 sTriton, Linnet Python backend6.02 s

Peak GPU memory

What the driver reports the process holding at its peak, in GiB; lower is better; the best bar is red.

PyTorchJAXONNX Runtime and TensorRTTriton Inference Server012GiBtransformers1.06 GiBtransformers, compiled1.07 GiBLinnet, generated PyTorch1.01 GiBLinnet, inductor1.01 GiBLinnet, CUDA graphs1.04 GiBLinnet, XLA (StableHLO)0.50 GiBLinnet, XLA (generated JAX)0.49 GiBtorch.onnx export2.08 GiBLinnet, ONNX Runtime f321.81 GiBLinnet, ONNX Runtime f161.39 GiBLinnet, ONNX Runtime bf161.92 GiBLinnet, TensorRT f322.75 GiBLinnet, TensorRT f162.51 GiBLinnet, TensorRT bf162.83 GiBTriton, torch.onnx export2.53 GiBTriton, Linnet's ONNX2.12 GiBTriton, Linnet Python backend2.53 GiB

Every number

MethodLatencyThroughputLoad timePeak GPU memoryAgainst the stack it replacesDistance from referenceNotes
PyTorch
transformers2.94 ms7,141/s7.20 s1.06 GiB0 (the reference)
transformers, compiled1.29 ms11,054/s4.09 s1.07 GiB0.0625
Linnet, generated PyTorch2.13 ms7,066/s1.22 s1.01 GiB0.61× transformers, compiled0
Linnet, inductor1.29 ms11,138/s1.39 s1.01 GiB1.00× transformers, compiled0.0625
Linnet, CUDA graphs0.68 ms11,583/s1.44 s1.04 GiB1.89× transformers, compiled0.0625
JAX
Linnet, XLA (StableHLO)0.93 ms15,014/s0.64 s0.50 GiB0.0625bf16, like the torch rows; peak memory is JAX's allocator peak; the driver shows its pool, which grows in whole regions
Linnet, XLA (generated JAX)1.17 ms13,563/s0.86 s0.49 GiB0.0625bf16, like the torch rows; peak memory is JAX's allocator peak; the driver shows its pool, which grows in whole regions
ONNX Runtime and TensorRT
torch.onnx export1.11 ms5,416/s15.5 s2.08 GiB0.269the reference model's own ONNX export, f32 like Linnet's;
Linnet, ONNX Runtime f321.28 ms4,510/s0.29 s1.81 GiB0.87× torch.onnx export0.269f32; ONNX Runtime's CUDA execution provider; first calls build the sessions
Linnet, ONNX Runtime f161.00 ms7,354/s0.30 s1.39 GiB0.254f16; ONNX Runtime's CUDA execution provider; first calls build the sessions
Linnet, ONNX Runtime bf161.66 ms3,698/s0.28 s1.92 GiB0.0625bf16; ONNX Runtime's CUDA execution provider; first calls build the sessions
Linnet, TensorRT f320.53 ms14,519/s0.29 s2.75 GiB0.266f32; ONNX Runtime's TensorRT execution provider; first calls build the sessions
Linnet, TensorRT f160.41 ms25,153/s0.30 s2.51 GiB0.258f16; ONNX Runtime's TensorRT execution provider; first calls build the sessions
Linnet, TensorRT bf161.00 ms6,078/s0.29 s2.83 GiB0.0938bf16; ONNX Runtime's TensorRT execution provider; first calls build the sessions
Triton Inference Server
Triton, torch.onnx export2.62 ms1,354/s5.07 s2.53 GiB0.269over HTTP; f32; throughput with 4 requests of batch 32 in flight
Triton, Linnet's ONNX3.33 ms1,308/s13.1 s2.12 GiB0.79× Triton, torch.onnx export0.269over HTTP; f32; throughput with 4 requests of batch 32 in flight
Triton, Linnet Python backend3.04 ms1,258/s6.02 s2.53 GiB0.0625over HTTP; bf16, CUDA graphs; throughput with 4 requests of batch 32 in flight