Related Experiment Videos
Fully Quantized Training vs. Post-Training Quantization for a Small Hyperspectral Transformer Model for Pixel-Level
Zirak Khan1, Seung-Chul Yoon2, Suchendra M Bhandarkar1
1School of Computing, University of Georgia, Athens, GA 30602, USA.
Abstract:
Low-precision floating-point computation has become central to efficient artificial intelligence, yet its behavior for compact transformer-based hyperspectral imaging (HSI) models remains underexplored. In this work, we present a controlled comparative study of fully quantized training (FQT) and post-training quantization (PTQ) for pixel-wise foreign plastic object (FPO) classification in poultry hyperspectral data. Using a fixed state-of-the-art spatial-spectral transformer backbone, a common mixed-precision strategy, and identical training and inference protocols, we evaluate FP32, FP16, BF16, FP8, and NVFP4 across predictive performance, model compression, training efficiency, and inference efficiency. The results show that mixed-precision FQT remains highly robust across the tested precision spectrum, with all reduced-precision configurations staying within 0.63 percentage points of the FP32 baseline in overall accuracy while consistently outperforming PTQ at matched precisions. Across the evaluated formats, BF16 provides the closest accuracy to FP32, whereas FP8 offers a particularly favorable balance between accuracy preservation and reduced precision, while model compression increases progressively to 3.69× under NVFP4. The computational benefits, however, are strongly workload dependent. Native FP8/FP4 hardware support does not automatically improve training throughput for this compact model at moderate workloads, and the larger training batches required to better utilize low-precision hardware can degrade predictive performance. In contrast, large-batch inference can effectively exploit FP8 and NVFP4 without affecting predictive accuracy. An ablation study further shows that selective retention of numerically sensitive modules in FP32 is essential for stable ultra-low-precision operation. Overall, the findings demonstrate that low precision is a viable but workload-dependent design choice for compact HSI transformers, with FQT providing greater accuracy robustness than PTQ and FP8, offering a favorable overall accuracy-efficiency trade-off.