Skip to content

Parity: modern-yolonas vs super-gradients

Generated by examples/parity_check.py. Both implementations receive the same safetensors weights and the same input tensors, in one process on one torch build.

  • torch: 2.13.0+cu130
  • weights repo: CondadosAI/detectors (Super Gradients Model EULA, non-commercial)
  • random inputs per variant: 15 (see the inputs column), seed 1234, device CPU
variant dtype inputs ckpt tensors miss/unexp (ours) miss/unexp (SG) RepVGG blocks worst box abs worst box rel worst score abs
yolo_nas_s float32 15 921 0/0 0/0 37 vs 37 1.221e-04 1.853e-07 0.000e+00
yolo_nas_m float32 15 965 0/0 0/0 39 vs 39 9.155e-05 1.134e-07 0.000e+00
yolo_nas_l float32 15 1097 0/0 0/0 45 vs 45 6.104e-05 7.473e-08 0.000e+00
yolo_nas_s float32 3 921 0/0 0/0 37 vs 37 6.104e-05 9.265e-08 0.000e+00
yolo_nas_s float64 3 921 0/0 0/0 37 vs 37 2.274e-13 3.452e-16 0.000e+00

worst score abs of exactly 0.000e+00 means the class scores are bit-identical, so the backbone, neck and classification branch agree exactly. Any remaining box difference is confined to the distance decode.

If you ran --precision-sweep, compare the float32 and float64 rows for yolo_nas_s at the same input count: a relative error that collapses by ~2^28 is the signature of floating-point rounding rather than a genuine difference in the arithmetic, since extra precision does not repair a wrong formula.