• Nu S-Au Găsit Rezultate

View of Object Tracking Using OpenCYand Python

N/A
N/A
Protected

Academic year: 2022

Share "View of Object Tracking Using OpenCYand Python"

Copied!
10
0
0

Text complet

(1)

Object Tracking Using OpenCYand Python

J Thirupathi1, N V Krishna Rao2, Dr.MMadhu Bala3, K Prathima,D Naveen4, G Mallikarjun5

Department of Computer Science and Engineering, Institute of Aeronautical Engineering, JNTU, Dundigal,Hyderabad,India.

ABSTRACT

This paper gives you clear idea of tracking an object in video as well as in visual mode. Object tracking, is really challenging. Due to abrupt motion of an object tracking that object becomes difficult. Object tracking is more popular because many applications are using it. Object tracking technology has been driven by an increasing processing power available in software and hardware. Here we present a developed application for tracking objects based on OpenCV libraries. The proposed application deals with real time system implementations. The results give an indication of the cases where object tracking applications are complex and where it is simpler.

Keywords: Object Tracking, Python 3.7, OpenCV.

I. Introduction

Object tracking is a process of tracking an object in successive frames of video. We use tracking algorithms because it is faster than detection algorithms. When you are tracking an object that was detected in the previous frame, you know a lot about the appearance of the object. OpenCV is famous libraries for tracking an object. OpenCV stands for Open Source Computer Vision. It is a library which aimed at real-time computer vision. It is developed by Intel.

In computer vision object tracking plays a major role. Object tracking created great interest because of proliferation of high-powered computers, the availability of high quality and inexpensive video cameras, and the increasing need for automated video. Object tracking and location in digital images has become one of the most important applications for industries. It makes easy for user, save time and achieve parallelism. This is not new technique but an improvement of existing technique.

Software Details:

1. Programming Language: Python3.7

2. Packages Used: Tensorflow, Numpy,Pandas,Matplotlib 3. Operating System: Windows

Hardware Details:

1. System : Pentium IV 2.4 GHz.

2. Hard Disk : 40 GB.

3. Floppy Drive : 1.44 Mb.

4. Monitor : 15 VGA Colour.

5. Mouse : Logitech.

6. Ram : 512 Mb.

(2)

Fig.1: Architecture diagram for Object Tracking Existing solutions:

Object tracking created great interest in computer visualization industry due to advancementsinvideo surveillance and image processing. The main reason why we use tracking algorithms is that achieving high performance and a near-real-time object detection in both large- scale systems and embedded platforms. Therefore, a reliable and accurate near real-time object detection application, running on an embedded system, is crucial, due to the rising security concerns in different fields.

II. Related Work

Here we present a developed application for tracking objects based on OpenCV libraries. The complexity-related aspects that were considered in the object detection using cascade classifier are described. The proposed application deals with real time system implementations. The results give an indication of the cases where object tracking applications are complex and where it is simpler.

Modules:

Browse System Videos:

This module allows the user to upload any video from his system so that application will connect to that video and start playing it. If an object is detected while playing the video application marks that object with bounding boxes, while playing video if you want to stop playing the video then you have to press „q‟ key on your keyboard so that it stops video playing.

Start Webcam Video Tracking:

This module connects itself with an inbuilt webcam and start streaming the video, while streaming if any object is detected then application surrounds that detected object with bounding boxes. If you want to stop playing press „q‟ on keyboard so it stops webcam streaming.

(3)

Exit:

Exit is used to exit from the output which stops the current process.

Modules from Python Used in Project:

TensorFlow

TensorFlow is free and open-source. It is a part of math library. It is used in many applications of machine learning. It can be used for research purpose and production purpose.

It was developed by the Google Brain team for internal use of Google.

Numpy

Numpy is a package which is used for array processing. It gives multidimensional array object, and also tools for working with these arrays.

It has following uses:

1. N-dimensional array object 2. Sophisticated functions

3. Tools for integrating C/C++ and Fortran code

Arbitrary data-types can be defined using Numpy which allows Numpy to integrate with different databases.

Pandas

Pandas is also Python Library which is open source providing data manipulation and analysis tool using its data structures.It is used for data munging and data preparation. Using Pandas, we can accomplish five steps in the data analysis such as data load, prepare, manipulate, model, and analyze. Python pandas have wide range of applications.

Matplotlib

Matplotlib is a Python 2D plotting library which produces figures in a variety of formats and interactive environments across platforms. It can be used in Python scripts.You can generate plots, histograms, power spectra, bar charts, error charts, scatter plots, etc., within a few lines of code.

Scikit – learn

Scikit-learn provides both supervised and unsupervised learning algorithms through relevant interface in Python. It is distributed under many Linux distributions, encouraging academic and commercial use.

III. Procedure and Algorithms How to install OpenCV on Mac OS?

Our system must be loaded with python 3.7 and OpenCV. Install OpenCV, using pip3 installnumpy.and import cv2

import cv2

tracker_types = ['BOOSTING', 'MIL','KCF', 'TLD', 'MEDIANFLOW', 'CSRT', 'MOSSE']

(4)

ALGORITHMS:

1.Boosting

It is a tracker which is a version of AdaBoost. It uses HAAR cascade face detector. This tracker is examined at runtime using positive and negative examples of an object.

2.MIL

It also works same as Boosting tracker as mentioned above. But MIL will not consider only current location of object as positive reference or example, it takes small neighborhood around current location as positive reference. As it concentrates only small neighborhood location, it is seen as bad idea of positive example.

3.KCF

The derivation of KCF isKernelized Correlation Filters. It adds other features to above mentioned trackers. It observed that in MIL tracker there are large overlapping region. This overlapping is removed by this tracker to make tracking fast and accurate.

4.TLD

The derivation of TLD is Tracking, learning and detection. It divides the long tracking work into 3 components tracking, learning, detection, “The tracker follows the object from frame to frame.

The detector localizes all appearances that have been observed so far and corrects the tracker if necessary. The learning estimates detector‟s errors and updates it to avoid these errors in the future.”

5.Medianflow

The Special feature of this tracker is that it tracks object in both forward and backward directions and measures discrepancies between these two, so we have to minimize this forward backward error, so it can detect tracking failure.

6.CSRT

This type of tracker uses special reliability map for adjusting filter support to selected region from frame which we take for tracking. It helps in localizing of selected part and improve tracking of objects. It use feature likeHoGs and Color names. It also gives higher accuracy for tracking an object.

7.MOSSE

This tracker uses adaptive correlation for object tracking, so it produces stable correlation filter when we use single frame for tracking. It is robust for variations in scale, pose, lighting, etc. It is also helps in detecting occlusion, which gives us option to pause and resume. MOSSE tracker also operates at a higher fps.

IV. Implementation and Results Output generation

After running the program this is how output looks like where we have 3 modules

(5)

1.Browse system Videos

2.Start Webcam Video Tracking 3.Exit

Fig.2: Object tracking dash board

If you choose the option Browse System Videos the control goes to videos where you have an option.

To select the video where you want to track objects. Even you have an option to download any video from browser and paste those in videos folder so that you can track the objects present in that videos.

Fig.3: Choosing video for object tracking

(6)

When you choose a particular video from the videos folder the tracking of objects will be done and a rectangular box will appeared as boundary of that objects to represent that the object has been tracked.

Fig 4: Video playing and object detected

Fig 5. Cars detected in video

(7)

Fig.6: Detecting objects in video

1. After the video has been stopped running the below output will be displayed.

Fig.7: List of detections in video

(8)

2. If you choose the option Start Webcam Video Tracking, it prompts you to allow camera you need to allow the camera so that we can track the objects on the spot. This is how the webcam video tracking will be done after webcam is enabled.

Fig.8: Object detection using webcam

3.when your task has been completed you need to choose exit option so that you get exit from the output window

Fig.9: Exit from the dash board

(9)

V. Conclusion and Future Scope

The developed application proves that object detection can be deployed in different platforms as needed. This system is a good match of the need to have surveillance cameras with object detection notification. The strength of this system is that it can be trained for any type of object to be detected for different situations. An extension to this work would be to adapt the system to low cost card and adapt it to the card architecture to obtain better performances. The next steps of this work will be to enhance the embedded platform performance. This enhancement can be achieved through the usage of parallelism. We can run several processors simultaneously and independently to enhance or improve response time and performance.

References

[1] G. Bradski and, A. Kaehler, “Learning OpenCV”, OReilly Publications, 2008

[2] M. Cerny, M. Dobrovolny, “Eye Tracking System on Embedded Platform”, International conference of Applied Electronics 2012

[3] P. Aby, A. Jose, et al, “Implementation and optimization of an Embedded Face Detection system”, International Conference on Signal Processing 2011.

[4] P. Viola, M. Jones, “Robust Real-Time Face Detection”, International Journal of Computer Vision 57(2), 137154, 2004

[5] R. Gonzalez and R. Woods, “Digital Image Processing”, PearsonEducation, 3rd Edition, 2008.

[6] Y. Freund and R. E. Schapire, “A decision-theoretic generalization of on-line learning and an application to boosting” Journal of computer and system sciences, no. 55, pp. 110 – 140, 1997.

[7] W. Bing, and C. Chareonsak, “Fpga implementation of adaboost algorithm for detection of face biometrics”, in Biomedical Circuits and Systems, 2004 IEEE International Workshop, Dec. 2004, pp. S1/6–17– 20.

[8] M. Pham, T. Cham, “Fast training and selection of Haar features using statistics in boosting- based face detection”, in: Proceedings of the IEEE International Conference on Computer Vision, 2007.

[9]N V Krishna Rao,YHarikaDevi,NShalini,AHarika,VDivyavani,Dr.N Manga Thayaru“Credit Card Fraud Detection Using Spark and Machine Learning Techniques”, ICACECS2020,Machine Learning Technologies and Applications pp 163-172, Algorithms for Intelligent Systems book series (AIS),march 2021.

[10]N.V.KrishnaRao,KayiramKavitha, AshokaDeepthiManukonda, R.V.S.Lalitha, B.Abhishek Reddy” Semi-Equalizing Load in Multi-hop Wireless Networks” ”,International Journal of Innovative Technology and Exploring Engineering‟ at Volume-9 Issue-1, November 2019 pp.3047-3051 (ISSN:2278-3075).

[11]N V Krishna Rao,S. Laxman Kumar, K. Kavitha,PuduPravalika,KotteSruthi,R.V.S. Lalitha,

“Fashion Compatibility using Convolutional Neural Networks”, ACCES September,2020.

[12]N.V. Krishna Rao, MotheRakesh , SrikanthCherukuvada , J Thirupathi and B Madhuravani,

“A Review on Data Mining Approach used in Education Data Mining using Decision Tree Algorithm”, Journal of Advanced Research in Dynamical and Control Systems, Vol.

10,Special Issue .7 July 2018 pp.1735- 1738 (ISSN 1943-023X )

(10)

[13]N.V.KrishnaRao , K Radhika, D Rahul , J Thirupathi and B Madhuravani, “ A Survey on Top- K Dominating Queries on Any Incomplete Information”, International Journal of Pure and Applied Mathematics, Vol. 119 No. 14 2018, pp. 1807-1811(ISSN: 1314-3395)

[14]JThirupathi , D Rahul , K Radhika , N.V.KrishnaRao and B Madhuravani,“ An Enhanced Novel Based Incentive Framework for Cellular Traffic Offloading”, International Journal of Pure and Applied Mathematics, Vol. 119 No. 14 2018, pp. 1813-1817 (ISSN: 1314-3395).

[15] R. Leinhart and J. Maydt, “An extended set of haar-like features for rapid object detection”, in Proc. ICIP, 2002, vol.1, pp. 900 -910

[16] J. F. Henriques, R. Caseiro, P. Martins, and J. Batista. Highspeed tracking with kernelized correlation filters. IEEE Transactions on Pattern Analysis and Machine Intelligence, 2015.

[17] H. KianiGaloogahi, T. Sim, and S. Lucey. Correlation filters with limited boundaries. In IEEE Conference on Computer Vision and Pattern Recognition, 2015.

Referințe

DOCUMENTE SIMILARE

The legal interpretation of legal norm is important for the normal functioning of the activity of state bodies, respectively official persons, citizens and associations

As a result of these works in deep learning neural networks,we comewith idea of providing trained sets and networks that make the tracking algorithm easier and also

In the latter distribution, Romanian clauses are interesting in that they allow two patterns with different underlying syntax: an agreeing variant where the embedded subject is

The Black Sea seaside represents an important tourist and spa area not only for Romania, where there can be found the following resorts: Năvodari, Mamaia, Constanţa, Neptun,

The diagnostic accuracy of US could be improved in combination with CEUS (65.3% vs 83.7%). The diagnostic accuracy of the GB wall thickening type was higher than the mass forming

The Dope Sheet View is used to visualize motion tracking data, it is implemented as separate view of the Movie Clip editor just like the Graph View. It displays channels for

units, it is worth noting that the fundamental reference quantities in the British system of units (foot, pound, second) are based on the primary dimensions of length (L), force

 Fiecare grup de lucru va negocia relativ la ceea ce va face și relativ la ceea ce a făcut va primi punctajul pe care-l merită.  Acest punctaj va fi împărțit apoi de Team