DETECTION OF MOVING OBJECTS
IN A VIDEO USING
HOPFIELD NEURAL NETWORK
Amlan Ray Chaudhuri
Why are we doing it?
Moving objects detection in video streams is a key
fundamental and critical task in many computer vision
Object detection in videos involves verifying the
presence of an object in image sequences and possibly
locating it precisely for recognition.
Why are we doing it?
Object tracking is to monitor an object’s spatial and
temporal changes during a video sequence, including its
presence, position, size, shape.
Object tracking from video sequence is the process of
locating moving objects in time using a camera. An
algorithm analyses the video frames and outputs the
location of moving targets within the video frame. The
main steps involved in this process are object detection,
tracking, and analysis of tracked objects
The main objective of this project is to devise a
method by which moving objects can be detected in a
Change detection is the process of identifying
differences in the state of an object or phenomenon by
observing it at different times. The goal of our study is
to utilize Hopfield Neural Network to address these
HOPFIELD NEURAL NETWORK
A Hopfield network is a form of recurrent
artificial neural network invented by John
Hopfield in 1982.
It can be seen as a fully connected single layer
auto associative network.
Hopfield nets serve as content addressable
memory systems with binary threshold nodes.
Hopfield networks are constructed from artificial neurons .These
artificial neurons have N inputs. With each input i there is a
weight wi associated.They also have an output. The state of the
output is maintained, until the neuron is updated.
A Hopfield neural network consists of a set
of neurons where each neuron corresponds
to a pixel of the difference image and is
connected to all the neurons in the
The output of the neuron is feedback to
each of the other neurons in the network.
The number of feedback loops is equal to the
number of neurons.
There is no self feedback loop.
PROPERTIES OF HOPFIELD NETWORK
A recurrent network with all nodes connected to all
Nodes have binary outputs(either 0,1 or 1,-1)
Weights between the nodes are symmetric
No connection from node to itself is allowed
Nodes are updates asynchronously(the nodes are
selected at random)
The network has no hidden layers or nodes.
A video stream is primarily divided into several
frames and our goal can be achieved if we can
identify the image portion which has changed over
time and that which has not changed.
A difference frame is obtained from the reference
frame and target frame.
Given an initial state, the status of each neuron is
The input Ui to the generic ith neuron comes from
two sources, namely
1. input Vj from other units (to which it is connected)
2. external input bias Ii, which is a fixed bias applied
externally to the unit i. Thus, the total input to a
neuron i is given by
Example: Second-order topological network. Each neuron in the
network is connected only to its eight neighbours. Neurons are
represented by circles, and lines represent connections between neurons.
The output Vi of neuron i is defined as
Vi = g(Ui)
where g(・) is an activation function.
In the discrete model, neurons are bipolar, i.e., the output Vi of neuron i is
either +1 or −1. In this model, the activation function g(・) is defined
according to the following threshold function:
Vi = g(Ui) =+1, if Ui ≥ θi
−1, if Ui < θi
where θi is the predefined threshold of neuron i.
Change detection maps are obtained by iteratively
updating the output status of the neurons until a minimum of the energy
function is reached and the network assumes a stable state.
Hopfield defined the energy function of the network by using
the network architecture, i.e., the number of neurons, their output
functions, threshold values, connection between neurons, and the strength
of the connections. Thus, the energy function represents the complete status
of the network.
Hopfield has also shown that, at each iteration of the processing of the
network, the energy value decreases and the network reaches a stable state
when its energy value reaches a minimum.
The energy function E of the discrete model is given by
Energy Function Ei=-∑i∑jWikViVk - ∑iIiVi
When the network reaches a stable state (local minimum of its energy
function), the difference image is classified into two classes (neurons having
ON (+1) status represent the changed pixels and those having OFF (−1) status
represent the unchanged pixels).
Input given is the reference frame and the target
Output is the movement recorded as separate
image. The change in the target frame is considered as
a movement of the object. That movement is detected
as a separate image and recorded for any surveillance.
1. R. Bogush, N. Brovko and S.Maltsev. Background
Reconstruction Based on Iterative Algorithm for Video
2. Manisha Chate, S.Amudha and Vinaya Gohokar. Object
Detection and tracking in Video Sequences.
3. S. Gopal and C. Woodcock, “Remote sensing of forest change
using artificial neural networks,” IEEE Trans. Geosci. Remote
Sens., vol. 34,