Vehicle Counting Detection on Roadways using YOLO Algorithm with PyTorch Transfer Learning


Authors

  • Prihandoko Gunadarma University, Jakarta, Indonesia
  • Ahsan Firdaus Universitas Putra Indonesia “YPTK” Padang, Padang, Indonesia
  • Rini Sovia Universitas Putra Indonesia “YPTK” Padang, Padang, Indonesia

DOI:

https://doi.org/10.30865/klik.v5i1.1880

Keywords:

Vehicle Counting Detection; PyTorch Transfer Learning; Centroid Tracker

Abstract

This research discusses the implementation of a vehicle counting detection system on roadways utilizing the YOLO (You Only Look Once) algorithm, integrated with PyTorch's transfer learning and fine-tuning techniques. The study is motivated by the rapid increase in private vehicle ownership in Indonesia, which has heightened concerns regarding traffic congestion and accident risks. The primary objective of this research is to develop an efficient vehicle counting system based on Convolutional Neural Networks (CNN), designed to process images and videos. The methodology encompasses a literature review, system analysis, design, implementation, and evaluation. The system is built using YOLOv8, tailored with transfer learning to enhance object detection, focusing on cars. To track and count vehicles, the Centroid Tracker algorithm is employed. A dataset of 1,667 images was used, partitioned into training (1,488 images), validation (118 images), and testing (61 images) sets. The model achieved a detection accuracy of 97.92%, though minor detection errors were observed. In video-based testing, the system effectively detected and tracked vehicles, assigning unique IDs to individual cars. In conclusion, the YOLOv8-based model, combined with the Centroid Tracker algorithm, demonstrates strong performance in detecting and counting vehicles, offering potential contributions to traffic monitoring systems and providing a foundation for more sophisticated applications in future research.

Downloads

Download data is not yet available.

References

D. A. Kurniawan, "Mengapa Kendaraan Pribadi Terus Bertumbuh," Pusat Studi Transportasi dan Logistik Universitas Gadjah Mada: https://pustral. ugm. ac. id/2017/10/05/mengapakendaraan-pribadi-terus-bertumbuh, 2017.

Astra, "Astra International Investor Relations." [Online]. Available: https://www.astra.co.id/investor-relations

Badan Pusat Statistik, "Perkembangan Jumlah Kendaraan Bermotor Menurut Jenis (Unit), 2021-2022." [Online]. Available: https://www.bps.go.id/id/statistics-table/2/NTcjMg==/number-of-motor-vehicle-by-type.html

Z. Wang, L. Hu, F. Wang, M. Lin, and N. Wu, "Assessing the Impact of Different Population Density Scenarios on Two-Wheeler Accident Characteristics at Intersections," Sustainability, vol. 16, no. 5, p. 1737, 2024, doi: https://doi.org/10.3390/su16051737.

Q. Ma, G. Huang, and X. Tang, "GIS-based analysis of spatial–temporal correlations of urban traffic accidents," European transport research review, vol. 13, pp. 1–11, 2021, doi: https://doi.org/10.1186/s12544-021-00509-y.

N. Sohaee and S. Bohluli, "Nonlinear analysis of the effects of socioeconomic, demographic, and technological factors on the number of fatal traffic accidents," Safety, vol. 10, no. 1, p. 11, 2024, doi: https://doi.org/10.3390/safety10010011

P. Trojanowski, A. Trusz, and B. Stupin, "Correlation between accidents on selected roads as fundamental for determining the safety level of road infrastructure," in Design, simulation, manufacturing: the innovation exchange, Springer, 2022, pp. 104–113. doi: https://doi.org/10.1007/978-3-031-06025-0_11.

U. Jilani, M. Asif, M. Y. I. Zia, M. Rashid, S. Shams, and P. Otero, "A systematic review on urban road traffic congestion," Wirel Pers Commun, pp. 1–29, 2023, doi: https://doi.org/10.1007/s11277-023-10700-0.

S. R. Samal, M. Mohanty, and S. M. Santhakumar, "Adverse effect of congestion on economy, health and environment under mixed traffic scenario," Transportation in Developing Economies, vol. 7, no. 2, p. 15, 2021, doi: https://doi.org/10.1007/s40890-021-00125-4.

Y. Ma, V. Sanchez, and T. Guha, "CLIP-EBC: CLIP Can Count Accurately through Enhanced Blockwise Classification," arXiv preprint arXiv:2403.09281, 2024, doi: https://doi.org/10.48550/arXiv.2403.09281.

L. Deng, Q. Zhou, S. Wang, J. M. Górriz, and Y. Zhang, "Deep learning in crowd counting: A survey," CAAI Trans Intell Technol, doi: https://doi.org/10.1049/cit2.12241.

Y.-J. Zhang, "Computer Vision Overview," in 3-D Computer Vision: Principles, Algorithms and Applications, Springer, 2023, pp. 1–35. doi: https://doi.org/10.1007/978-981-19-7580-6_1.

Kemenhub, "Perkembangan Jumlah Kendaraan Bermotor Menurut Jenis." [Online]. Available: https://portaldata.kemenhub.go.id/content/dataset/10030

P. A. Rosyady and M. R. Feter, "Prototype Lampu Lalu Lintas Adaptif Berdasarkan Panjang Antrian Kendaraan Berbasis Arduino Uno," Circuit: Jurnal Ilmiah Pendidikan Teknik Elektro, vol. 6, no. 2, pp. 173–186, 2022, doi: http://dx.doi.org/10.22373/crc.v6i2.13748.

W. Hariri, “Unlocking the potential of ChatGPT: A comprehensive exploration of its applications, advantages, limitations, and future directions in natural language processing,” arXiv preprint arXiv:2304.02017, 2023, doi: https://doi.org/10.48550/arXiv.2304.02017.

X. Zhao, L. Wang, Y. Zhang, X. Han, M. Deveci, and M. Parmar, “A review of convolutional neural networks in computer vision,” Artif Intell Rev, vol. 57, no. 4, p. 99, 2024, doi: https://doi.org/10.1007/s10462-024-10721-6.

A. Bochkovskiy, C.-Y. Wang, and H.-Y. M. Liao, “Yolov4: Optimal speed and accuracy of object detection,” arXiv preprint arXiv:2004.10934, 2020, doi: https://doi.org/10.48550/arXiv.2004.10934.

P. Li, M. Zhang, J. Wan, and M. Jiang, "Multi?Scale Guided Attention Network for Crowd Counting," Sci Program, vol. 2021, no. 1, p. 5596488, 2021, doi: https://doi.org/10.1155/2021/5596488.

M. I. L. Tan, C. J. Calgo, S. E. P. Cabantac, J. L. E. Honrado, N. J. C. Libatique, and G. L. Tangonan, "Vehicle detection using YOLO and mobility tracking during COVID-19 pandemic lockdowns," in 2021 IEEE Global Humanitarian Technology Conference (GHTC), IEEE, 2021, pp. 1–7. doi: https://doi.org/10.1109/GHTC53159.2021.9612481.

M. Iman, H. R. Arabnia, and K. Rasheed, "A review of deep transfer learning and recent advancements," Technologies (Basel), vol. 11, no. 2, p. 40, 2023, doi: https://doi.org/10.3390/technologies11020040.

M. S. Azari, F. Flammini, S. Santini, and M. Caporuscio, "A systematic literature review on transfer learning for predictive maintenance in industry 4.0," IEEE access, vol. 11, pp. 12887–12910, 2023, doi: https://doi.org/10.1109/ACCESS.2023.3239784.

F. Zhuang et al., "A comprehensive survey on transfer learning," Proceedings of the IEEE, vol. 109, no. 1, pp. 43–76, 2020, doi: https://doi.org/10.1109/JPROC.2020.3004555.

S. Chilamkurthy, "Transfer Learning for Computer Vision Tutorial." [Online]. Available: https://pytorch.org/tutorials/beginner/transfer_learning_tutorial.html

J. Terven, D.-M. Córdova-Esparza, and J.-A. Romero-González, "A comprehensive review of yolo architectures in computer vision: From yolov1 to yolov8 and yolo-nas," Mach Learn Knowl Extr, vol. 5, no. 4, pp. 1680–1716, 2023, doi: https://doi.org/10.3390/make5040083.

E. Smith, "Scientific Machine Learning with PyTorch," in Introduction to the Tools of Scientific Computing, Springer, 2022, pp. 359–410.

N.-E.-A. Mimma, S. Ahmed, T. Rahman, and R. Khan, "Fruits classification and detection application using deep learning," Sci Program, vol. 2022, no. 1, p. 4194874, 2022, doi: https://doi.org/10.1155/2022/4194874.

K. Banachewicz and L. Massaron, The Kaggle Book: Data analysis and machine learning for competitive data science. Packt Publishing Ltd, 2022.


Bila bermanfaat silahkan share artikel ini

Berikan Komentar Anda terhadap artikel Vehicle Counting Detection on Roadways using YOLO Algorithm with PyTorch Transfer Learning

Dimensions Badge

ARTICLE HISTORY


Published: 2024-08-31
Abstract View: 235 times
PDF Download: 98 times