Developing an Automated Vision System for Maintaing Social Distancing to Cure the Pandemic


  • Fatima Hardan Department of Mechatronics Engineering / Al-Khwarizmi College of Engineering University of Baghdad
  • Ahmed R. J. Almusawi Department of Mechatronics Engineering / Al-Khwarizmi College of Engineering University of Baghdad



The world is currently facing a medical crisis. The epidemic has affected millions of people around the world since its appearance. This situation needs an urgent solution. Most countries have used different solutions to stop the spread of the epidemic. The World Health Organization has imposed some rules that people should adhere. The rules are such, wearing masks, quarantining infected people and social distancing. Social distancing is one of the most important solutions that have given good results to confront the emerging virus. Several systems have been developed that use artificial intelligence and deep learning to track social distancing. In this study, a system based on deep learning has been proposed. The system includes monitoring and detecting people besides measuring the social distance between them. The proposed system consists of two parts: (1) detecting the faces of people using the Viola-Jones algorithm. The Cascade classifiers were trained. The Cascade classifiers used in the algorithm with feature descriptors to detect side faces and wear masks. Hence, training is dominant for detection. (2) measurement of the Euclidean distance between the centers of the rectangles of the people who were revealed in the first part. The distance between individuals' is measured to check how well they adhere to social distancing. The results revealed that the proposed system can perform well in applying images to track the distance between people.


Download data is not yet available.


Deep Learning Official Website - Check it out on August 17, 2016. Archived December 13, 2017 on the Wayback Machine website.

Wikipedia contributors, "Deep learning," Wikipedia, The Free Encyclopedia, (accessed February 23, 2022).

Song, H.A.; Lee, S. Y. (2013). "Hierarchical Representation Using NMF". Neural doi:10.1007/978-3-642- .473–466 . Springer. Information Processing pages. 8226 .978-3-642-42053-5 42054-2_58. ISBN

A. Marion, Introduction to image processing. Springer, 2013.

C. T. Nguyen et al., “A Comprehensive Survey of Enabling and Emerging Technologies for Social Distancing - Part I: Fundamentals and Enabling Technologies,” IEEE Access, vol. 8, pp. 153479–153507, 2020, doi: 10.1109/ACCESS.2020.3018140.

M. Rezaei and M. Azarmi, “Deepsocial: Social distancing monitoring and infection risk assessment in covid-19 pandemic,” Appl. Sci., vol. 10, no. 21, pp. 1–29, 2020, doi: 10.3390/app10217514.

M. Greenstone and V. Nigam, “Does Social Distancing Matter?,” SSRN Electron. J., 2020, doi: 10.2139/ssrn.3561244.

A. C. Sankaranarayanan, R. Patro, P. Turaga, A. Varshney, and R. Chellappa, “Modeling and visualization of human activities for multicamera networks,” Eurasip J. Image Video Process., vol. 2009, 2009, doi: 10.1155/2009/259860.

N. S. Punn, S. K. Sonbhadra, S. Agarwal, and G. Rai, “Monitoring COVID-19 social distancing with person detection and tracking via fine-tuned YOLO v3 and Deepsort techniques,” arXiv Prepr. arXiv2005.01385, 2020.

N. Sulman, T. Sanocki, D. Goldgof, and R. Kasturi, “How effective is human video surveillance performance?,” in 2008 19th International Conference on Pattern Recognition, 2008, pp. 1–3.

J. S. Cobb and M. A. Seale, “Examining the effect of social distancing on the compound growth rate of COVID-19 at the county level (United States) using statistical analyses and a random forest machine learning model,” Public Health, vol. 185, pp. 27–29, 2020.

F. Yin, X. Li, H. Peng, F. Li, K. Yang, and W. Yuan, “A highly sensitive, multifunctional, and wearable mechanical sensor based on RGO/synergetic fiber bundles for monitoring human actions and physiological signals,” Sensors Actuators B Chem., vol. 285, pp. 179–185, 2019, doi:

A. A. Chaaraoui, J. R. Padilla-López, F. J. Ferrández-Pastor, M. Nieto-Hidalgo, and F. Flórez-Revuelta, “A vision-based system for intelligent monitoring: human behaviour analysis and privacy by context,” Sensors, vol. 14, no. 5, pp. 8895–8925, 2014.

J. Redmon and A. Farhadi, “YOLO v.3,” Tech Rep., pp. 1–6, 2018, [Online]. Available:

A. Rahim, A. Maqbool, and T. Rana, “Monitoring social distancing under various low light conditions with deep learning and a single motionless time of flight camera,” PLoS One, vol. 16, no. 2 February, pp. 1–19, 2021, doi: 10.1371/journal.pone.0247440.

A. Bochkovskiy, C.-Y. Wang, and H.-Y. M. Liao, “YOLOv4: Optimal Speed and Accuracy of Object Detection,” 2020, [Online]. Available:

S. Yadav, “Deep Learning based Safe Social Distancing and Face Mask Detection in Public Areas for COVID-19 Safety Guidelines Adherence,” Int. J. Res. Appl. Sci. Eng. Technol., vol. 8, no. 7, pp. 1368–1375, 2020, doi: 10.22214/ijraset.2020.30560.

A. H. Ahamad, N. Zaini, and M. F. A. Latip, “Person Detection for Social Distancing and Safety Violation Alert based on Segmented ROI,” Proc. - 10th IEEE Int. Conf. Control Syst. Comput. Eng. ICCSCE 2020, no. August, pp. 113–118, 2020, doi: 10.1109/ICCSCE50387.2020.9204934.

W. Liu et al., “Ssd: Single shot multibox detector,” in European conference on computer vision, 2016, pp. 21–37.

G. Bradski and A. Kaehler, Learning OpenCV: Computer vision with the OpenCV library. “ O’Reilly Media, Inc.,” 2008.

K. Bhambani, T. Jain, and K. A. Sultanpure, “Real-Time Face Mask and Social Distancing Violation Detection System using YOLO,” Proc. B-HTC 2020 - 1st IEEE Bangalore Humanit. Technol. Conf., 2020, doi: 10.1109/B-HTC50970.2020.9297902.

Y. C. Hou, M. Z. Baharuddin, S. Yussof, and S. Dzulkifly, “Social Distancing Detection with Deep Learning Model,” 2020 8th Int. Conf. Inf. Technol. Multimedia, ICIMU 2020, pp. 334–338, 2020, doi: 10.1109/ICIMU49871.2020.9243478.

R. Girshick, J. Donahue, T. Darrell, J. Malik, U. C. Berkeley, and J. Malik, “1043.0690,” Proc. IEEE Comput. Soc. Conf. Comput. Vis. Pattern Recognit., vol. 1, p. 5000, 2014, doi: 10.1109/CVPR.2014.81.

R. Girshick, “Fast R-CNN,” Proc. IEEE Int. Conf. Comput. Vis., vol. 2015 Inter, pp. 1440–1448, 2015, doi: 10.1109/ICCV.2015.169.

D. Chen, S. Ren, Y. Wei, X. Cao, and J. Sun, “LNCS 8694 - Joint Cascade Face Detection and Alignment,” pp. 109–122, 2014.

P. Felzenszwalb, D. McAllester, and D. Ramanan, “A discriminatively trained, multiscale, deformable part model,” in 2008 IEEE conference on computer vision and pattern recognition, 2008, pp. 1–8.

X. Zhu and D. Ramanan, “Face Detection , Pose Estimation , and Landmark Localization in the Wild.”

J. Redmon and A. Farhadi, “Yolo V2.0,” Cvpr2017, no. April, pp. 187–213, 2017, [Online]. Available:

F. Wikipedia, “Viola – Jones object detection framework,” pp. 2–4, 2001.

Y. Wang, “An Analysis of the Viola-Jones Face Detection Algorithm,” vol. 4, pp. 128–148, 2014.

M. R. Mohammed and A. I. Daood, “Smart surveillance system to monitor the committed violations during the pandemic.”




How to Cite

Hardan, F., & R. J. Almusawi, A. . (2022). Developing an Automated Vision System for Maintaing Social Distancing to Cure the Pandemic. Al-Khwarizmi Engineering Journal, 18(1), 38–50.