Models / roberta-base

RoBERTa Base

Meta's more thoroughly trained BERT: the same post-norm encoder, dynamic masking, no next-sentence-prediction, and a byte-level BPE vocabulary of 50265.

124.1M parametersbertMITfill-masktext-encoderencoder-only

NVIDIA H100 80GB HBM3 · median of 10 runs after 3 warm-ups · measured 2026-09-28T18:17:48+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 PyTorch2.14× fasterlatency
  • Linnet, CUDA graphs0.73 mstransformers, compiled1.57 ms
vs KerasHub, in JAX5.32× fasterlatency
  • Linnet, XLA (generated JAX)0.93 msKerasHub4.95 ms
vs torch.onnx, on ONNX Runtime1.60× fasterlatency
  • Linnet, ONNX Runtime f321.53 mstorch.onnx export2.44 ms
vs torch.onnx, behind Triton1.12× fasterlatency
  • Triton, Linnet's ONNX3.32 msTriton, torch.onnx export3.73 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 Server024mstransformers3.52 mstransformers, compiled1.57 msLinnet, generated PyTorch1.92 msLinnet, inductor1.38 msLinnet, CUDA graphs0.73 msKerasHub4.95 msLinnet, XLA (StableHLO)1.18 msLinnet, XLA (generated JAX)0.93 mstorch.onnx export2.44 msLinnet, ONNX Runtime f321.53 msLinnet, ONNX Runtime f161.23 msLinnet, ONNX Runtime bf161.23 msLinnet, TensorRT f320.75 msLinnet, TensorRT f160.53 msLinnet, TensorRT bf160.56 msTriton, torch.onnx export3.73 msTriton, Linnet's ONNX3.32 msTriton, Linnet Python backend2.68 ms

Throughput

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

PyTorchJAXONNX Runtime and TensorRTTriton Inference Server05000100001500020000/stransformers10,857/stransformers, compiled14,513/sLinnet, generated PyTorch13,836/sLinnet, inductor17,223/sLinnet, CUDA graphs18,181/sKerasHub5,082/sLinnet, XLA (StableHLO)12,433/sLinnet, XLA (generated JAX)11,985/storch.onnx export4,955/sLinnet, ONNX Runtime f325,276/sLinnet, ONNX Runtime f169,664/sLinnet, ONNX Runtime bf169,497/sLinnet, TensorRT f329,050/sLinnet, TensorRT f1619,752/sLinnet, TensorRT bf1618,619/sTriton, torch.onnx export566/sTriton, Linnet's ONNX502/sTriton, Linnet Python backend540/s

Load time

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

PyTorchJAXONNX Runtime and TensorRTTriton Inference Server051015stransformers15.6 stransformers, compiled1.55 sLinnet, generated PyTorch1.14 sLinnet, inductor1.11 sLinnet, CUDA graphs1.14 sKerasHub5.99 sLinnet, XLA (StableHLO)0.54 sLinnet, XLA (generated JAX)0.57 storch.onnx export18.6 sLinnet, ONNX Runtime f320.28 sLinnet, ONNX Runtime f160.29 sLinnet, ONNX Runtime bf160.37 sLinnet, TensorRT f320.27 sLinnet, TensorRT f160.27 sLinnet, TensorRT bf160.27 sTriton, torch.onnx export10.2 sTriton, Linnet's ONNX17.0 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 Server01234GiBtransformers1.16 GiBtransformers, compiled1.14 GiBLinnet, generated PyTorch1.11 GiBLinnet, inductor1.06 GiBLinnet, CUDA graphs1.15 GiBKerasHub0.55 GiBLinnet, XLA (StableHLO)0.77 GiBLinnet, XLA (generated JAX)0.75 GiBtorch.onnx export2.81 GiBLinnet, ONNX Runtime f322.64 GiBLinnet, ONNX Runtime f161.76 GiBLinnet, ONNX Runtime bf161.76 GiBLinnet, TensorRT f323.33 GiBLinnet, TensorRT f163.06 GiBLinnet, TensorRT bf163.05 GiBTriton, torch.onnx export3.50 GiBTriton, Linnet's ONNX3.87 GiBTriton, Linnet Python backend2.87 GiB

Every number

MethodLatencyThroughputLoad timePeak GPU memoryAgainst the stack it replacesDistance from referenceNotes
PyTorch
transformers3.52 ms10,857/s15.6 s1.16 GiB0 (the reference)unpadded batches of exactly 128 tokens (this card takes no padding mask)
transformers, compiled1.57 ms14,513/s1.55 s1.14 GiB0.125unpadded batches of exactly 128 tokens (this card takes no padding mask)
Linnet, generated PyTorch1.92 ms13,836/s1.14 s1.11 GiB0.82× transformers, compiled0.156unpadded batches of exactly 128 tokens; bf16 on cuda
Linnet, inductor1.38 ms17,223/s1.11 s1.06 GiB1.14× transformers, compiled0.125unpadded batches of exactly 128 tokens; bf16 on cuda
Linnet, CUDA graphs0.73 ms18,181/s1.14 s1.15 GiB2.14× transformers, compiled0.125unpadded batches of exactly 128 tokens; bf16 on cuda
JAX
KerasHub4.95 ms5,082/s5.99 s0.55 GiB0.117bf16, under jax.jit; unpadded batches of exactly 128 tokens; peak memory is JAX's allocator peak; the driver shows its pool, which grows in whole regions
Linnet, XLA (StableHLO)1.18 ms12,433/s0.54 s0.77 GiB4.20× KerasHub0.156unpadded batches of exactly 128 tokens; bf16 on cuda; peak memory is JAX's allocator peak; the driver shows its pool, which grows in whole regions
Linnet, XLA (generated JAX)0.93 ms11,985/s0.57 s0.75 GiB5.32× KerasHub0.219unpadded batches of exactly 128 tokens; bf16 on cuda; peak memory is JAX's allocator peak; the driver shows its pool, which grows in whole regions
ONNX Runtime and TensorRT
torch.onnx export2.44 ms4,955/s18.6 s2.81 GiB0.0883the reference model's own ONNX export, f32 like Linnet's; unpadded batches of exactly 128 tokens
Linnet, ONNX Runtime f321.53 ms5,276/s0.28 s2.64 GiB1.60× torch.onnx export0.0883f32; ONNX Runtime's CUDA execution provider; first calls build the sessions; unpadded batches of exactly the sequence length
Linnet, ONNX Runtime f161.23 ms9,664/s0.29 s1.76 GiB0.0879f16; ONNX Runtime's CUDA execution provider; first calls build the sessions; unpadded batches of exactly the sequence length
Linnet, ONNX Runtime bf161.23 ms9,497/s0.37 s1.76 GiB0.125bf16; ONNX Runtime's CUDA execution provider; first calls build the sessions; unpadded batches of exactly the sequence length
Linnet, TensorRT f320.75 ms9,050/s0.27 s3.33 GiB0.0876f32; ONNX Runtime's TensorRT execution provider; first calls build the sessions; unpadded batches of exactly the sequence length
Linnet, TensorRT f160.53 ms19,752/s0.27 s3.06 GiB0.0977f16; ONNX Runtime's TensorRT execution provider; first calls build the sessions; unpadded batches of exactly the sequence length
Linnet, TensorRT bf160.56 ms18,619/s0.27 s3.05 GiB0.125bf16; ONNX Runtime's TensorRT execution provider; first calls build the sessions; unpadded batches of exactly the sequence length
Triton Inference Server
Triton, torch.onnx export3.73 ms566/s10.2 s3.50 GiB0.0883over HTTP; f32; throughput with 4 requests of batch 64 in flight
Triton, Linnet's ONNX3.32 ms502/s17.0 s3.87 GiB1.12× Triton, torch.onnx export0.0883over HTTP; f32; throughput with 4 requests of batch 64 in flight
Triton, Linnet Python backend2.68 ms540/s6.02 s2.87 GiB0.125over HTTP; bf16, CUDA graphs; throughput with 4 requests of batch 64 in flight