Benchmarks¶
Automated performance benchmarks for every TorchEBM module. Results are generated by the benchmark suite and rendered here automatically at documentation build time.
Quick Start¶
Coverage¶
-
Losses
Exact SM, Approx SM, Sliced SM, Contrastive Divergence, Equilibrium Matching
-
Samplers
Langevin Dynamics, HMC, Flow ODE
-
Integrators
Leapfrog, Euler-Maruyama, RK4, DOPRI5 (adaptive)
-
Models
Transformer forward, Transformer forward+backward
-
Interpolants
Linear, Cosine, Variance-Preserving
Scale Configurations¶
| Scale | Batch Size | Dimensions | Steps |
|---|---|---|---|
small | 64 | 8 | 50 |
medium | 256 | 32 | 100 |
large | 1024 | 128 | 200 |
Measurement Methodology¶
| Aspect | GPU | CPU |
|---|---|---|
| Timer | torch.cuda.Event | time.perf_counter |
| Warm-up | 10 iterations | 3 iterations |
| Measured | 50 iterations | 20 iterations |
| Memory | cuda.max_memory_allocated | N/A |
| Statistics | median, mean, std, IQR, min, max | same |
| Comparison | geometric mean speedup | same |