Adaptive Confidence and IoU Optimization for Accurate Real-Time Eel Counting Using YOLO-ONNX
DOI:
https://doi.org/10.62677/IJETAA.2607151Keywords:
Adaptive Threshold Optimization, Aquaculture, Eel Counting, Fish Counting, IoU, Object Detection, ONNX, YOLOv8nAbstract
Accurate fish counting is important in aquaculture hatcheries because it supports production planning, inventory monitoring, and fish dispersal management. Eels' small size, elongated body structure, transparency during the glass eel stage, and overlapping movement make it difficult to count them using image-based methods because, in contrast to other fish species, eels are prone to occlusion. Counting mistakes, duplicate detections, and missing detections are frequently caused by these traits. This study used adaptive confidence and Intersection over Union (IoU) threshold optimization to develop and evaluate an improved YOLO-ONNX-based eel counting framework. 1,541 eel images made up of glass eel and elver samples were used to train a YOLOv8n model, which was then exported to the Open Neural Network Exchange (ONNX) format for use. For threshold adjustment, a different set of 333 eel counting images arranged according to manual ground-truth counts was used. A confidence threshold of 0.25 and an Intersection over Union (IoU) threshold of 0.70 were utilized in the baseline YOLO-ONNX configuration. To find the optimal counting configuration, the adaptive optimization method tried several combinations of confidence and Intersection over Union. After selecting the optimized threshold configuration, a separate 200-image evaluation set was used to compare the baseline and optimized YOLO-ONNX configurations. Based on the results of the 200-image evaluation set, the optimized setup increased the mean counting accuracy by 11.29 percentage points, from 80.95% to 92.24%, using a confidence threshold of 0.15 and an IoU threshold of 0.40. The Mean Absolute Error decreased from 2.58 to 0.91, while the Root Mean Square Error decreased from 3.88 to 1.42. Based on the results, adaptive threshold optimization enhances detection-based eel counting by lowering overcounting and undercounting brought on by eel body overlap and occlusion. The proposed YOLO-ONNX framework provides a practical approach for improving eel counting accuracy through post-processing threshold optimization, without modifying the internal structure of the YOLO model.
Downloads
References
G. Wang, J. Yu, W. Xu, A. Muhammad, and D. Li, "Automated fish counting system based on instance segmentation in aquaculture," Expert Systems with Applications, vol. 259, Art. no. 125318, 2025. DOI: 10.1016/j.eswa.2024.125318 DOI: https://doi.org/10.1016/j.eswa.2024.125318
X. Yu, Y. Wang, D. An, and Y. Wei, "Counting method for cultured fishes based on multi-modules and attention mechanism," Aquacultural Engineering, vol. 96, Art. no. 102215, 2022. DOI: 10.1016/j.aquaeng.2021.102215 DOI: https://doi.org/10.1016/j.aquaeng.2021.102215
S. M. D. Lainez and D. B. Gonzales, "Automated fingerlings counting using convolutional neural network," in Proc. 2019 IEEE 4th Int. Conf. Computer and Communication Systems (ICCCS), 2019, pp. 67–72. DOI: 10.1109/CCOMS.2019.8821746 DOI: https://doi.org/10.1109/CCOMS.2019.8821746
E. S. Yap et al., "Initial development of tilapia fingerlings counter machine with smart camera," in Proc. 2024 IEEE 16th Int. Conf. Humanoid, Nanotechnology, Information Technology, Communication and Control, Environment, and Management (HNICEM), 2024, pp. 1–6. DOI: 10.1109/HNICEM64917.2024.11258850 DOI: https://doi.org/10.1109/HNICEM64917.2024.11258850
G. Farjon, L. Huijun, and Y. Edan, "Deep-learning-based counting methods, datasets, and applications in agriculture: A review," Precision Agriculture, vol. 24, no. 5, pp. 1683–1711, 2023. DOI: 10.1007/s11119-023-10034-8 DOI: https://doi.org/10.1007/s11119-023-10034-8
G. D. Espeña, A. I. F. D. Casarungan, O. S. M. Villaverde, and J. R. D. Riñon, "Using YOLOv8 for milkfish (Chanos chanos) fry counting in Philippine hatcheries," in Proc. 2025 IEEE Int. Conf. Internet of Things and Intelligence Systems (IoTaIS), 2025, pp. 41–46. DOI: 10.1109/IoTaIS67227.2025.11282093 DOI: https://doi.org/10.1109/IoTaIS67227.2025.11282093
H. Mokayed, T. Z. Quan, L. Alkhaled, and V. Sivakumar, "Real-time human detection and counting system using deep learning computer vision techniques," Artificial Intelligence and Applications, vol. 1, no. 4, pp. 221–229, 2023. DOI: 10.47852/bonviewAIA2202391 DOI: https://doi.org/10.47852/bonviewAIA2202391
H. Liu, X. Ma, Y. Yu, L. Wang, and L. Hao, "Application of deep learning-based object detection techniques in fish aquaculture: A review," Journal of Marine Science and Engineering, vol. 11, no. 4, Art. no. 867, 2023. DOI: 10.3390/jmse11040867 DOI: https://doi.org/10.3390/jmse11040867
M. L. Ali and Z. Zhang, "The YOLO framework: A comprehensive review of evolution, applications, and benchmarks in object detection," Computers, vol. 13, no. 12, Art. no. 336, 2024. DOI: 10.3390/computers13120336 DOI: https://doi.org/10.3390/computers13120336
K. Zhang, Y. Lv, Y. Zhang, C. Bian, J.-H. Wu, Q. Shi, et al., "Genomics comparisons provide new insights into the evolution of karyotype and body patterns in Anguilliformes species," International Journal of Biological Macromolecules, vol. 308, Part 1, Art. no. 142504, 2025. DOI: 10.1016/j.ijbiomac.2025.142504 DOI: https://doi.org/10.1016/j.ijbiomac.2025.142504
S. Abba, A. M. Bizi, J.-A. Lee, S. Bakouri, and M. L. Crespo, "Real-time object detection, tracking, and monitoring framework for security surveillance systems," Heliyon, vol. 10, no. 15, Art. no. e34922, 2024. DOI: 10.1016/j.heliyon.2024.e34922 DOI: https://doi.org/10.1016/j.heliyon.2024.e34922
V. Mohankumar and S. Anbalagan, "A benchmark dataset and ensemble YOLO method for enhanced underwater fish detection," ETRI Journal, 2025. DOI: 10.4218/etrij.2024-0383
U. Sirisha, S. P. Praveen, P. N. Srinivasu, P. Barsocchi, and A. K. Bhoi, "Statistical analysis of design aspects of various YOLO-based deep learning models for object detection," International Journal of Computational Intelligence Systems, vol. 16, Art. no. 126, 2023. DOI: 10.1007/s44196-023-00302-w DOI: https://doi.org/10.1007/s44196-023-00302-w
M. Işık and M. Yalçinkaya, "Enhancing aquarium fish classification through YOLO: A deep learning approach," in Proc. 2024 8th Int. Artificial Intelligence and Data Processing Symp. (IDAP), 2024, pp. 1–4. DOI: 10.1109/IDAP64064.2024.10710813 DOI: https://doi.org/10.1109/IDAP64064.2024.10710813
Z. Zhang et al., "An improved YOLOv8n used for fish detection in natural water environments," Animals, vol. 14, no. 14, Art. no. 2022, 2024. DOI: 10.3390/ani14142022 DOI: https://doi.org/10.3390/ani14142022
M. Vijayalakshmi and A. Sasithradevi, "A comprehensive annotated image dataset for real-time fish detection in pond settings," Data in Brief, vol. 57, Art. no. 111007, 2024. DOI: 10.1016/j.dib.2024.111007 DOI: https://doi.org/10.1016/j.dib.2024.111007
M. Cui et al., "Fish tracking, counting, and behaviour analysis in digital aquaculture: A comprehensive survey," Reviews in Aquaculture, 2024. DOI: 10.1111/raq.13001
K. Noh, S. Hong, S. Makonin, and Y. Lee, "Enhancing object detection in dense images: Adjustable non-maximum suppression for single-class detection," IEEE Access, vol. 12, pp. 130253–130263, 2024. DOI: 10.1109/ACCESS.2024.3459629 DOI: https://doi.org/10.1109/ACCESS.2024.3459629
S. Yadav et al., "An improved deep learning-based optimal object detection system from images," Multimedia Tools and Applications, vol. 83, pp. 30045–30072, 2023. DOI: 10.1007/s11042-023-16736-5 DOI: https://doi.org/10.1007/s11042-023-16736-5
C. Mohan et al., "A comprehensive review of image segmentation architectures," in Proc. 2024 11th Int. Conf. Electrical Engineering, Computer Science and Informatics (EECSI), 2024, pp. 223–229. DOI: 10.1109/EECSI63442.2024.10776322 DOI: https://doi.org/10.1109/EECSI63442.2024.10776322
A. Chinnaraju, "Benchmarking cross-platform AI: WebAssembly, ONNX Runtime and TVM for real-time web, mobile, and IoT deployment," World Journal of Advanced Research and Reviews, vol. 26, no. 2, pp. 1937–1963, 2025. DOI: 10.30574/wjarr.2025.26.2.1832 DOI: https://doi.org/10.30574/wjarr.2025.26.2.1832
C. Mani, T. Paul, P. Archambault, and A. Marois, "Machine learning workflow for edge computed arrhythmia detection in exploration class missions," NPJ Microgravity, vol. 10, 2024. DOI: 10.1038/s41526-024-00409-0 DOI: https://doi.org/10.1038/s41526-024-00409-0
R. Chang and T. Hoang, "Constructing an AI compiler for ARM Cortex-M devices," Computer Systems Science and Engineering, vol. 46, pp. 999–1019, 2023. DOI: 10.32604/csse.2023.034672 DOI: https://doi.org/10.32604/csse.2023.034672
Z. Lv et al., "Efficient deployment of peanut leaf disease detection models on edge AI devices," Agriculture, vol. 15, no. 3, Art. no. 332, 2025. DOI: 10.3390/agriculture15030332 DOI: https://doi.org/10.3390/agriculture15030332
D. Annam, "Advancements in latency reduction for real-time data processing in the cloud," World Journal of Advanced Engineering Technology and Sciences, 2025. DOI: 10.30574/wjaets.2025.15.2.0673 DOI: https://doi.org/10.30574/wjaets.2025.15.2.0673
H. Wen et al., "AdaptiveNet: Post-deployment neural architecture adaptation for diverse edge environments," in Proc. 29th Annual Int. Conf. Mobile Computing and Networking, 2023. DOI: 10.1145/3570361.3592529 DOI: https://doi.org/10.1145/3570361.3592529
P. Slater and F. Hasson, "Quantitative research designs, hierarchy of evidence and validity," Journal of Psychiatric and Mental Health Nursing, vol. 32, no. 3, pp. 656–660, 2025. DOI: 10.1111/jpm.13135 DOI: https://doi.org/10.1111/jpm.13135
Downloads
Published
Issue
Section
Categories
License
Copyright (c) 2026 Catleen Glo M. Feliciano, Maria Amelia E. Damian (Author)

This work is licensed under a Creative Commons Attribution-NonCommercial 4.0 International License.