Quantized Neural Networks for Ball Detection on the NAO Robot: An Optimized Implementation
摘要
Improving the latency of neural networks on low-end hardware such as the NAO robot used in the RoboCup Standard Platform league has been a relevant research topic since deep learning models can be effectively used for real-time computer vision. This paper focuses on optimizing the implementation of quantized neural networks (QNNs) for ball detection on the NAO V6 robot. The goal is to improve inference speed and reduce memory usage. A direct quantization scheme is employed, where weights and activations are represented as 8-bit integers. SIMD instructions available on the NAO’s processor architecture are utilized for efficient calculations. Quantization-aware training is used to train the models, and their inference is realized via automatically generated assembly code. The quantized models achieve a speedup of approximately \(2\times \) compared to float models. However, there is a slight decrease in model performance, as indicated by lower AUROC scores and mean ball IoU values for the quantized models. Paired t-tests confirm the statistical significance of the differences between float and quantized models. The optimized implementation of QNNs for ball detection on the NAO robot provides a practical speedup while maintaining reasonable model performance, however choosing simpler architectures leads to a better trade-off between latency and performance than quantization. Future work could involve comparing the results with the XNOR-Net for ball detection on the NAO and exploring the proposed approach in other RoboCup applications. All code used in the experiments is publicly available at https://github.com/fthielke/NaoQNN .