Object Tracking

You might also like

Download as doc, pdf, or txt
Download as doc, pdf, or txt
You are on page 1of 12

PROJECT TITLE

VIDEO TRACKING SYSTEM USING LABVIEW


Submitted in partial fulfilment of the requirement for the award of the degree of

BACHELOR OF TECHNOLOGY
IN
ELECTRONICS AND COMMUNICATION ENGINEERING
Submitted by

C.TEJA SRI 15R21A0408

E.SHRAVANI 15R21A0417

K.SOUMYA 15R21A0436

N.SOUJNAYA 15R21A0443

DEPARTMENT OF ELECTRONICS AND COMMUNICATION


ENGINEERING

MLR Institute of Technology


Laxman Reddy Avenue, Dundigal
Hyderabad-500043

1
TABLE OF CONTENTS

SNO CONTENTS PAGE NO


3
1 Abstract

2 History 3

3 Objectives 3

4 Introduction 4

5 Block diagram 5

6 Circuit diagram 6

7 Components required 7-11

8 Circuit and working explanation 12

9 Advantages and Dis-advantages 13

10 Applications 13

14
11 Implementation

12 Result and conclusion 15-17

2
VIDEO TRACKING SYSTEM
ABSTRACT

Detecting and tracking has much importance as a part of security. In this project we will develop an algorithm
for tracking of objects or human beings, which is mainly used for monitoring the actions or movements of the
specific object. Moving object detection is an interesting area in the field of video tracking. When the object is
moving then tracking that is challenging task in vision area. This paper is about detecting, tracking of moving
objects from the source. Many image processing methods to detect and track the moving object from the
source was proposed, but those methods require more time to implement and is complex. This paper gives
information about the moving object detection based on the tracking mean shift algorithm. LABVIEW vision
module introduces a recent algorithm for object detection and tracking, in this algorithm current location is
searched based on the histogram of the object in the previous image frame and result of mean shift is used to
find the peak of probability density function near the object old position. Initial location of the target object
needs to be determined for this to work correctly. Mean shift is an effective algorithm that has so many
applications especially in the field of computer vision like clustering, object contour detection etc. Tracking is
an important approach in various fields like, in military uses such as anti-aircraft, artificial intelligence,
monitoring and security. LABVIEW vision module introduces a recent algorithm for object detection and
tracking. It is more efficient and easier to track the objects movements.

HISTORY

In earlier days there is no system of identification and intimation of accident. When an accident occurs the
information is sent only through GSM i.e., the location of spot but there is no possibility of sending the
accident spot via SMS to mobile.

OBJECTIVES

The objective of video tracking is to associate target objects in consecutive video frames. The
association can be especially difficult when the objects are moving fast relative to the frame rate.
Another situation that increases the complexity of the problem is when the tracked object changes

3
orientation over time. For these situations video tracking systems usually employ a motion model
which describes how the image of the target might change for different possible motions of the object.
Examples of simple motion models are:

 When tracking planar objects, the motion model is a 2D transformation (transformation


or homography) of an image of the object (e.g. the initial frame).
 When the target is a rigid 3D object, the motion model defines its aspect depending on its 3D
position and orientation.
 For video compressions and key frames are divided into macroblocks. The motion model is a
disruption of a key frame, where each macroblock is translated by a motion vector given by
the motion parameters.
 The image of deformable objects can be covered with a mesh, the motion of the object is
defined by the position of the nodes of the mesh.

INTRODUCTION
 Emulation of human visual perception capabilities by machines is a challenging problem in
computer vision. It deals with algorithms or theory of building artificial vision systems that
extract information about the 3-D structure, orientation, spatial property of a generic object in a
given scene from 2-D images.
 This information analysis leads to provide a better way of detecting moving objects at different
instants of time in a given video sequence. Moving object detection in a scene has wide applications,
such as visual surveillance, activity recognition, robotics, and so on.
 Moving object detection in a given video scene can be achieved by two different ways: 1) motion
detection/change detection; and 2) motion estimation. Change or motion detection is the process of
identifying the moving objects by finding the changed and unchanged regions from the extracted
image frames when the camera is fixed and the objects are moving.
 For motion estimation, the motion vectors are computed to estimate the positions of the moving
objects from frame to frame. In case of motion estimation, both the objects and the camera may
move . It is very difficult to detect a moving object from a video captured with moving camera, where
objects and the camera both may have movements. To solve such problems one can, adhere to the
approaches, such as optical flow scheme.
 An optical flow-based motion vector computation for moving object detection is well studied by
Lucas and Kanade to track the translational motion of an object in the scene, popularly known as KLT
tracke. However, this scheme is unable to give good results in objects with complex motions and
dynamic background. A combination of spatial segmentation and motion prediction/estimation is
proved to be a better approach toward this, an early work for object detection by a computationally
efficient watershed-based segmentation scheme is suggested by Wang, where watershed algorithm is
used for object boundary identification.
 This method has two main drawbacks: 1) the complexity is high; and 2) spatial segmentation produces
an over-segmented result. To enhance the accuracy, Deng and Manjunath proposed a robust moving
object detection scheme, where the spatial segmentation of an image frame is obtained by colour
quantization followed by edge preserving region growing.
4
 For temporal segmentation, the regions corresponding to objects are matched in the temporal direction
by computing the motion vectors of the object regions in the target frame. It is considered that the use
of region based spatial segmentation scheme cannot handle the spatial ambiguities of image grey
values; and hence produces an over-segmented result that leads to misclassification in moving object
detection.
 The grey level of pixels in a video with high uncertainty and high ambiguity makes it difficult to
detect moving objects with reasonable accuracy by no statistical spatial segmentation schemes. Hence,
it requires some kind of stochastic method to model the important attributes of an image frame so that
a better segmentation result can be obtained. Markov random field (MRF) model.

BLOCK DIAGRAM

5
COMPONENTS REQUIRED:

 Webcam
 Motion and vision toolkit in LabVIEW
 LabVIEW

WEBCAM
 A webcam is a video camera that feeds or streams its image in real time to or through
a computer to a computer network. When "captured" by the computer, the video stream may
be saved, viewed or sent on to other networks travelling through systems such as the
internet, and e-mailed as an attachment.
 When sent to a remote location, the video stream may be saved, viewed or on sent there.
Unlike an IP camera (which connects using Ethernet or wifi), a webcam is generally
connected by USB cable, or similar cable, or built into computer hardware, such as laptops.
 The term "webcam" (a clipped board may also be used in its original sense of a video
camera connected to the Web continuously for an indefinite time, rather than for a particular
session, generally supplying a view for anyone who visits its web page over the Internet.
Some of them, for example, those used as online traffic cameras, are expensive,
rugged professional video cameras.

MOTION AND VISION TOOKLIT IN LABVIEW


 Use the Vision Development Module to take an open and adaptable
approach to machine vision software development. You can choose the
right hardware for your application and configure cameras, acquire
images, and analyse inspection results to build fully customized machine
vision systems.

6
 The Vision Development Module helps you develop software for machine
vision and image processing applications. You can use it with the
LabVIEW and LabVIEW NXG graphical programming environment, C, C++,
and C# for Windows systems and LabVIEW for real-time systems. Choose
from hundreds of image processing algorithms including filters,
morphologies, pattern matching, and classification. The module includes
IP for targeting both processors and FPGAs and features model importers
for performing inference using deep learning models developed in
TensorFlow.

LABVIEW

 LabVIEW, short for Laboratory Virtual Instrument Engineering Workbench, is a programming


environment in which you create programs using a graphical notation .The LabVIEW
development environment works on computers running Windows, Mac OS X, or Linux.
LabVIEW can create programs that run on those platforms, as well as Microsoft Pocket PC,
Microsoft Windows CE, Palm OS, and a variety of embedded platforms, including Field
Programmable Gate Arrays (FPGAs), Digital Signal Processors (DSPs), and
microprocessors.

 LabVIEW offers more flexibility than standard laboratory instruments because it is software-
based. You, not the instrument manufacturer, define instrument functionality. Your computer,
plug-in hardware, and LabVIEW comprise a completely configurable virtual instrument to
accomplish your tasks. Using LabVIEW, you can create exactly the type of virtual instrument
you need, when you need it, at a fraction of the cost of traditional instruments. When your
needs change, you can modify your virtual instrument in moments.

 LabVIEW's programs are portable across platforms, so you can write a program on a
Macintosh and then load and run it on a Windows machine without changing a thing in most

7
applications. You will find LabVIEW applications improving operations in any number of
industries, from every kind of engineering and process control to biology, farming,
psychology, chemistry, physics, teaching, and many others.

MEAN SHIFT ALGORITHM

Mean shift algorithm for moving object tracking was initially proposed by fukunaga et al, comaniciu in the
estimation of probability density function et al,[8].if we have a distribution points . Then according to the
mean shift algorithm modes or peaks in density function is determined. This method is called non-parametric
method ,this method of tracking tracks the object for long time and more robust compare to other tracking
algorithm. To find the new location of the object that we are going to track, we need to find a vector which
can suggest the direction of the moving object. This vector is called mean shift vecto .

First we need to draw the ROI around the object and get the data points, approximate location of the mean of
this data. Then estimate the exact location of the mean of the data by determining the mean shift vector from
the initial mean.

 In the first frame, tracking object is selected and object model has probability distribution of color
histogram. If 𝑦0 is the center of an object, then the position of pixels are{ 𝑥𝑖 ∗ i=1…N, where N is the number
of pixels in the image. statical histogram distribution model of target area given by 𝑞ℎ =C 𝑘 𝑥𝑖 ∗ 2 𝑛 𝐼=1 𝛿 𝑏 𝑥𝑖
∗ −ℎ .

 At the current frame the statistical histogram distribution given by 𝑝 ℎ 𝑦0 =𝐶ℎ 𝑘 || 𝑦0−𝑥𝑖 𝑊 𝑛ℎ 𝑖=1 𝛿 𝑏 𝑥𝑖 −ℎ

 Computing the measurement between the object and candidate template by Bhattacharyya coefficient. P (𝑝
ℎ (𝑦0), 𝑞 ℎ )= 𝑝ℎ ( 𝑦0 )𝑞 ℎ 𝐻−1 ℎ=0 (2) Weight of the window of pixels in tracking window 𝑤𝑖 = 𝛿[𝑏(𝑥𝑖 𝐻−1
ℎ=0 )− ℎ] 𝑞 ℎ 𝑝ℎ (𝑦0)

 New object position search by mean shift value given by 𝑦𝑖= 𝑥𝑖 𝑤𝑖 𝑔( 𝑦𝑜−𝑥1 𝑊 2 ) 𝑛ℎ 𝑖=0 𝑤𝑖 𝑔( 𝑦𝑜−𝑥1 𝑊 2)
𝑛ℎ 𝑖=0 (3) Then computing the Bhattacharya coefficient given by P 𝑃ℎ 𝑦1 , 𝑞 = 𝑝 ℎ 𝐻−1 ℎ=0 (𝑦1 )𝑞 ℎ
Comparing coefficients and update the candidate window.

 If ||𝑦1 −𝑦0 || < 𝜀 iteration stops, and going to step 2.

8
MEAN SHIFT ALOGRITHM

9
BLOCK MATCHED METHOD

ADVANTAGES:
• LABVIEW IS COST EFFECTIVE
• LOW MAINTAINCE
• CODE IS EASY TO USE
• MEAN SHIFT ALGORITHM IS EFFECTIVE
• HIGH ACCURATE

DISADVANTAGES:
• MULTIPLE OBJECT TRACKING IS DIFFICULT
• COLOUR AND LBP FEATURES ARE NOT CONSIDERED
• SHOULD USE TOO MANY METHODS FOR EVERY ACTIONS

APPLICATIONS:
• VEHICLE NAVIGATION
• ROBOTICS
• VIDEO GAMES
• MILITARY AND SECURITY
• AUTOMATION

10
IMPLEMENTATION:

RESULT:

CONCLUSION :

11
• MANY IMAGE PROCESSING METHODS TO TRACK THE MOVING OBJECT WAS PROPOSED, BUT THOSE
METHODS REQUIRE MORE TIME TO IMPLEMENT AND IS COMPLEX. LABVIEW VISION MODULE
INTRODUCES A RECENT ALGORITHM FOR OBJECT DETECTION AND TRACKING. IT IS MORE EFFICIENT
AND EASY TO TRACK THE OBJECTS MOVEMENTS.

REFERENCES

12

You might also like