Abstract
Real-time detection of moving objects in a resource-constrained environment, such as a personal mobile device, is a challenging task. Nowadays, cameras of cell phones and other mobile devices produce high-resolution videos. In addition, possible camera motion which is inherent to mobile devices adds further complexity to the image processing. Real-time analysis of those videos can be performed using optimized versions of the background subtraction methods. The focus of this work is an efficient implementation of background subtraction using dual-mode single Gaussian model with age on Android platform. Several optimizations were applied: parallelization through RenderScript framework, block processing and grayscale transformation of pixels, and memory transfer and footprint reduction. Implemented algorithm was evaluated using multiple test scenarios on two different platforms. We observed speedups up to 6 times over the reference sequential implementation, real time performance of 50 FPS for 640 \(\times\) 480 videos and 20.7 FPS for 1280 \(\times\) 720 videos. Comparative analysis with state-of-the-art methods on CDNet 2014 PTZ category showed good F1-measure. The obtained results are carefully discussed.
Similar content being viewed by others
References
Acosta, A., Merino, C., Totz, J.: Analysis of OpenCL support for mobile GPUs on android. In: Proceedings of the International Workshop on OpenCL, pp. 1–6 (2018)
Allebosch, G., Deboeverie, F., Veelaert, P., Philips, W.: EFIC: edge based foreground background segmentation and interior classification for dynamic camera viewpoints. In: International Conference on Advanced Concepts for Intelligent Vision Systems, pp. 130–141. Springer (2015)
Bahri, H., Chouchene, M., Sayadi, F.E., Atri, M.: Real-time moving human detection using HOG and Fourier descriptor based on CUDA implementation. J. Real-Time Image Process. (2019). https://doi.org/10.1007/s11554-019-00935-1
Bianco, S., Ciocca, G., Schettini, R.: Combination of video change detection algorithms by genetic programming. IEEE Trans. Evol. Comput. 21(6), 914–928 (2017)
Bloisi, D.D., Pennisi, A., Iocchi, L.: Parallel multi-modal background modeling. Pattern Recognit. Lett. 96, 45–54 (2017)
Chapel, M.N., Bouwmans, T.: Moving objects detection with a moving camera: a comprehensive review. Comput. Sci. Rev. 38, 100310 (2020)
Fischler, M.A., Bolles, R.C.: Random sample consensus: a paradigm for model fitting with applications to image analysis and automated cartography. Commun. ACM 24(6), 381–395 (1981)
Garcia-Garcia, B., Bouwmans, T., Silva, A.J.R.: Background subtraction in real applications: challenges, current models and future directions. Comput. Sci. Rev. 35, 100204 (2020)
Guihot, H.: Pro Android Apps Performance Optimization. Springer (2012)
Guler, P., Emeksiz, D., Temizel, A., Teke, M., Temizel, T.T.: Real-time multi-camera video analytics system on gpu. J. Real-Time Image Process. 11(3), 457–472 (2016)
Henderson, P., Vertescher, M.: An analysis of parallelized motion masking using dual-mode single gaussian models. arXiv preprint arXiv:1702.05156 (2017)
Kalsotra, R., Arora, S.: A comprehensive survey of video datasets for background subtraction. IEEE Access 7, 59143–59171 (2019)
Kovačev, P., Mišić, M., Tomašević, M.: Parallelization of the mixture of Gaussians model for motion detection on the GPU. In: 2018 Zooming Innovation in Consumer Technologies Conference (ZINC), pp. 58–61. IEEE (2018)
Kumar, P., Singhal, A., Mehta, S., Mittal, A.: Real-time moving object detection algorithm on high-resolution videos using GPUs. J. Real-Time Image Process. 11(1), 93–109 (2016)
Kushwaha, A., Khare, A., Prakash, O., Khare, M.: Dense optical flow based background subtraction technique for object segmentation in moving camera environment. IET Image Process. 14(14), 3393–3404 (2020)
Li, X., Hu, W., Shen, C., Zhang, Z., Dick, A., Hengel, A.V.D.: A survey of appearance models in visual object tracking. ACM Trans. Intell. Syst. Technol. (TIST) 4(4), 1–48 (2013). https://doi.org/10.1145/2508037.2508039
Mabrouk, L., Huet, S., Belkouch, S., Houzet, D., Zennayi, Y., Hamzaoui, A.: Performance and scalability improvement of GMM background segmentation algorithm on multi-core parallel platforms. In: International Conference on Electronic Engineering and Renewable Energy, pp. 120–127. Springer (2018)
Mabrouk, L., Huet, S., Houzet, D., Belkouch, S., Hamzaoui, A., Zennayi, Y.: Efficient adaptive load balancing approach for compressive background subtraction algorithm on heterogeneous CPU–GPU platforms. J. Real-Time Image Process. 17(5), 1567–1583 (2020)
Montero, V.J., Jung, W.Y., Jeong, Y.J.: Fast background subtraction with adaptive block learning using expectation value suitable for real-time moving object detection. J. Real-Time Image Process. 18, 967–981 (2021)
Moo Yi, K., Yun, K., Wan Kim, S., Jin Chang, H., Young Choi, J.: Detection of moving objects with non-stationary cameras in 5.8 ms: bringing motion detection to your mobile device. In: Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition Workshops, pp. 27–34 (2013)
Nurhadiyatna, A., Wijayanti, R., Fryantoni, D.: Extended Gaussian mixture model enhanced by hole filling algorithm (GMMHF) utilize GPU acceleration. In: Inf. Sci. and Appl. (ICISA), pp. 459–469. Springer (2016)
Piccardi, M.: Background subtraction techniques: a review. In: 2004 IEEE International Conference on Systems, Man and Cybernetics (IEEE Cat. No. 04CH37583), vol. 4, pp. 3099–3104. IEEE (2004)
Plyer, A., Le Besnerais, G., Champagnat, F.: Massively parallel Lucas Kanade optical flow for real-time video processing applications. J. Real-Time Image Process. 11(4), 713–730 (2016)
Renderscript: setting floating point precision. https://developer.android.com/guide/topics/renderscript/compute#setting-floating-point-precision. Accessed: 2021-03-15
Sajid, H., Cheung, S.C.S.: Universal multimode background subtraction. IEEE Trans. Image Process. 26(7), 3249–3260 (2017)
Sheikh, Y., Javed, O., Kanade, T.: Background subtraction for freely moving cameras. In: 2009 IEEE 12th International Conference on Computer Vision, pp. 1219–1225. IEEE (2009)
Shen, Y., Hu, W., Yang, M., Liu, J., Wei, B., Lucey, S., Chou, C.T.: Real-time and robust compressive background subtraction for embedded camera networks. IEEE Trans. Mobile Comput. 15(2), 406–418 (2015)
Sobral, A., Vacavant, A.: A comprehensive review of background subtraction algorithms evaluated with synthetic and real videos. Comput. Vis. Image Underst. 122, 4–21 (2014)
Sooraj, P.S.A., Kollerathu, V., Sudhakaran, V.: Real-time traffic counter using mobile devices. J. Big Data Anal. Transp. 3, 109–118 (2021)
St-Charles, P.L., Bilodeau, G.A., Bergevin, R.: Subsense: a universal change detection method with local adaptive sensitivity. IEEE Trans. Image Process. 24(1), 359–373 (2014)
Stauffer, C., Grimson, W.E.L.: Adaptive background mixture models for real-time tracking. In: Proceedings. 1999 IEEE Computer Society Conference on Computer Vision and Pattern Recognition (Cat. No PR00149), vol. 2, pp. 246–252. IEEE (1999)
Szwoch, G., Ellwart, D., Czyżewski, A.: Parallel implementation of background subtraction algorithms for real-time video process. On a supercomputer platform. J. Real-Time Image Process. 11(1), 111–125 (2016)
Tezcan, M.O., Ishwar, P., Konrad, J.: BSUV-Net 2.0: spatio-temporal data augmentations for video-agnostic supervised background subtraction. IEEE Access 9, 53849–53860 (2021)
Tomasi, C., Kanade, T.: Detection and tracking of point features. Int. J. Comput. Vis. 137–154 (1991)
Wang, Y., Jodoin, P.M., Porikli, F., Konrad, J., Benezeth, Y., Ishwar, P.: Cdnet 2014: An expanded change detection benchmark dataset. In: Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition Workshops, pp. 387–394 (2014)
Xu, Y., Dong, J., Zhang, B., Xu, D.: Background modeling methods in video analysis: a review and comparative evaluation. CAAI Trans. Intell. Technol. 1(1), 43–60 (2016). https://doi.org/10.1016/j.trit.2016.03.005
Yu, Y., Kurnianggoro, L., Jo, K.H.: Moving object detection for a moving camera based on global motion compensation and adaptive background model. Int. J. Control Autom. Syst. 17(7), 1866–1874 (2019)
Yun, K., Choi, J.Y.: Robust and fast moving object detection in a non-stationary camera via foreground probability based sampling. In: 2015 IEEE International Conference on Image Processing (ICIP), pp. 4897–4901. IEEE (2015)
Author information
Authors and Affiliations
Corresponding author
Additional information
Publisher's Note
Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.
This work has been partially funded by the Ministry of Education, Science and Technological Development of the Republic of Serbia (III44009 and TR32047). The authors gratefully acknowledge the financial support.
Supplementary Information
Below is the link to the electronic supplementary material.
Rights and permissions
About this article
Cite this article
Mišić, M., Kovačev, P. & Tomašević, M. Improving performance of background subtraction on mobile devices: a parallel approach. J Real-Time Image Proc 19, 275–286 (2022). https://doi.org/10.1007/s11554-021-01184-x
Received:
Accepted:
Published:
Issue Date:
DOI: https://doi.org/10.1007/s11554-021-01184-x