Repository navigation
docs(yolo11): record why FP8 is not shipped - #2146
Conversation
Add a family README that records the FP8 self-quantization study of yolo11n on TensorRT 11.4 and 11.1: FP8 is slower than fp16 (0.90x to 0.93x at batch 1, 0.88x to 0.89x at batch 8), the plan saves about 2 MiB and COCO AP drops by 1.2 points, because bias, SiLU and the next Quantize are not fused into the FP8 convolution. Documentation only. Signed-off-by: Zhenshan Xie <zhenshanx@nvidia.com>
|
No actionable comments were generated in the recent review. Summary
Merge Risk:
|
Background
families/yolo11buildsyolo11n(Ultralytics/YOLO11) as one detector engine (640 x 640, batch 1, fp16 in the manifest; class-aware NMS in the runtime) and has no quantized build. No FP8 or NVFP4 checkpoint of any YOLO detector exists on the Hub, so FP8 self-quantization of the convolutions (the recipe of theyolov10study, #2093) was built and measured on TensorRT 11.4 and 11.1. FP8 does not pay for this family: it is slower than fp16 (0.90x to 0.93x at batch 1, 0.88x to 0.89x at batch 8), the plan saves only about 2 MiB (6.56 to 4.65 MiB on B200), and COCO AP drops from 0.4158 to 0.4034. This change adds a README for the family that records the study, like the yolov10 (#2093) and yolov8 (#2101) studies, so that it does not have to be repeated. The FP8 code is not part of this change. NVFP4 was not tried: TensorRT does not support NVFP4 on convolutions.Exit Criteria
Implementation
families/yolo11/README.md(new): a short family description and the section "FP8 quantization study (not shipped)": summary and decision, recipe, method, results (speed, size, quality, variant), NVFP4, what was not tried, when to revisit.Recipe that was measured (code kept out of the repository):
model.2, the 7 depthwise convolutions, the DFL decode and the top-1 class stay fp16.FP8_DEFAULT_CFGstatistic) on the family's PyTorch reference, 256 COCO 2017 validation images. fp16 Dequantize.Why no gain: the convolutions run on FP8 kernels, but bias, SiLU and the next Quantize are not fused into the FP8 convolution, so the generated pointwise kernels grow from 45 to 64 (plan layers 137 to 159) and the small, launch-bound model ends up slower. FP8 depthwise convolutions have no TensorRT 11.4 kernel ("no tactics"), so the 7 depthwise convolutions of yolo11n stay fp16.
Change categories
Validation
Commands and Results
Documentation only.
python3 -m tools.model_ci validatepytest tools/tests/test_architecture.py tools/tests/test_public_source_hygiene.py(CPU)git diff --checkpython3 tools/pr_metadata.py validateon this descriptionThe numbers in the README come from the local study and are not re-run by this change (yolo11n, x is fp16 time over FP8 time):
No NaN or Inf on 500 held-out images and 3 stress inputs.
Hardware, Environment, and Revisions
upstream/mainatf8800ce3. The study ran onupstream/mainatf8800ce3;families/yolo11has not changed since.Ultralytics/YOLO11(yolo11n.pt) at8b8ac7d1fae7468f85dbf89670dd66f41f485aab(manifest revision).detection-datasets/cocovalidation images 0 to 255 (calibration) and 300 to 799 (held out), with their COCO 2017 annotations.Not Run / Remaining Gaps
Contributor Self-Review
Notes For Future Readers
Risk level
Risk rationale: documentation only; one README added, no code, build, bundle or test change.
🤖 Generated with Claude Code