Module 4. Question and Answer
Module 4. Question and Answer
SUBMODULE 1
Question 109 (14 Marks)
Answer
Introduction
Image classification is one of the fundamental tasks in computer vision where an image is
automatically assigned to a predefined category based on its visual content. The goal of an
image classification system is to enable computers to understand and categorize images
similar to how humans recognize objects.
Image classification systems are widely used in many real-world applications such as
medical image diagnosis, autonomous driving, object recognition, agriculture
monitoring, and security systems.
Building an image classification system involves several sequential stages that allow the
computer to learn patterns from image data.
1. Data Collection
The first step is to collect a large dataset containing images belonging to different classes.
The dataset must include sufficient examples for each category so that the classification
model can learn distinguishing features.
Example:
For an animal classification system, the dataset may contain images of cats, dogs, horses,
and birds.
• Diversity of images
2. Data Preprocessing
Raw images may contain noise, different sizes, or variations in brightness. Therefore
preprocessing is required to standardize the dataset.
• Noise removal
• Contrast adjustment
These steps ensure that all images have similar properties before feature extraction.
3. Feature Extraction
Feature extraction is the process of identifying important characteristics in an image that help
distinguish one class from another.
• Edges
• Corners
• Shapes
• Texture patterns
• Color information
Feature extraction converts an image into a numerical feature vector that represents the
important visual information.
These techniques capture structural patterns that are useful for classification.
4. Feature Representation
After extracting features, the next step is to represent these features in a structured form
suitable for machine learning algorithms.
Feature vectors are organized into a feature matrix, where:
• Rows represent images
5. Model Training
During training, a machine learning classifier learns patterns from the labeled dataset.
• Decision Trees
• Neural Networks
The classifier analyzes the feature vectors and learns to associate them with the correct class
labels.
6. Model Evaluation
After training, the model must be evaluated using a test dataset that was not used during
training.
• Accuracy
• Precision
• Recall
• F1-score
Evaluation ensures that the system can correctly classify new unseen images.
• Security surveillance
Conclusion
Building an image classification system involves several stages including data collection,
preprocessing, feature extraction, feature representation, model training, evaluation,
and prediction. By learning patterns from large datasets, these systems can accurately
classify images and support many intelligent computer vision applications.
Answer
Introduction
In computer vision and object tracking, it is necessary to model how objects move over time.
A linear dynamical model is a mathematical model used to describe the motion of objects in
dynamic systems.
This model predicts the future state of an object based on its previous states and motion
parameters.
State Representation
For example, the state vector of a moving object can be represented as:
• x, y → position coordinates
The motion of the object can be described using the state transition equation:
xₜ = A xₜ₋₁ + wₜ
Where:
• xₜ → state at time t
• wₜ → process noise
Observation Model
In addition to motion prediction, observations from sensors are represented as:
zₜ = H xₜ + vₜ
Where:
• zₜ → observed measurement
• H → observation matrix
• vₜ → observation noise
Example
Importance
• Robot navigation
• Autonomous vehicles
• Surveillance systems
Answer
Linear dynamical models are commonly used for this prediction process.
Example
Consider tracking a person walking in a video.
If the person moves steadily toward the right side of the frame, the linear dynamical model
predicts that the person will continue moving in the same direction in the next frame.
This predicted location helps the system locate the object quickly.
Advantages of Prediction
Prediction also helps reduce computational complexity by limiting the search area.
Applications
Answer
Linear dynamical models provide a mathematical framework for describing how an object's
state changes over time.
The model assumes that the motion of an object follows a linear relationship between
current and previous states.
Where:
• x, y → object position
• vx, vy → object velocity
This representation allows the system to describe both location and movement of the object.
Motion Equation
The change in the object's state over time is modeled as:
xₜ = A xₜ₋₁ + wₜ
Here:
The matrix A determines how the object moves from one frame to the next.
Example
Consider a ball rolling on the ground.
If the ball moves with constant velocity, the linear dynamical model predicts the next position
based on the previous position and velocity.
Importance
Linear dynamical models help represent motion patterns efficiently and are widely used in
visual tracking and motion estimation.
b) Explain how prediction using a linear dynamical model helps estimate the future
position of a moving object. (7 Marks)
Answer
Prediction using a linear dynamical model allows a system to estimate the future position of
an object based on its past motion.
Prediction Steps
Example
If a vehicle moves at a constant speed along a road, the system predicts its future position
using the motion model.
Even if the object temporarily disappears due to occlusion, the predicted location helps the
tracking system maintain continuity.
Benefits
Prediction helps in:
Application
• Robotics
Answer
1. Medical Image Analysis – Image classification helps doctors identify diseases from
medical images such as X-rays, MRI scans, and CT scans.
Answer
Classifies data into two possible categories Classifies data into more than two
only. categories.
The output contains only two labels. The output contains multiple class labels.
Example: Spam vs Non-spam email, Face Example: Classifying images as cat, dog,
vs Non-face detection. horse, bird.
Answer
The purpose of classification is to automatically identify the type of object or scene present
in an image. It is widely used in applications such as object recognition, medical image
analysis, and facial recognition systems.
SUBMODULE 2
Question 115 (14 Marks)
Answer
Introduction
Image classification is a computer vision task in which images are assigned to predefined
categories such as animals, vehicles, or objects. Machine learning models are trained using
labeled image datasets to recognize patterns in images. However, during training, the model
may learn the training data too closely and fail to generalize to new unseen images. This
phenomenon is called overfitting.
Overfitting is a major problem in image classification because it reduces the model’s ability
to perform well on real-world data. Therefore, several techniques are used to control
overfitting and improve model generalization.
Overfitting occurs when the classification model becomes too complex and learns noise or
irrelevant details present in the training data. As a result:
This indicates that the model is not learning the general characteristics of the objects.
Example:
A classifier trained to recognize cats and dogs may memorize specific training images instead
of learning general features like shape, ears, and fur patterns.
A larger training dataset helps the model learn general patterns rather than memorizing
specific examples.
Advantages:
• Different backgrounds
2. Data Augmentation
Data augmentation increases the training dataset by creating modified versions of existing
images.
• Image rotation
• Scaling or zooming
• Cropping
• Brightness and contrast adjustment
Data augmentation improves robustness because the model learns to recognize objects under
different transformations.
3. Regularization
Regularization techniques add a penalty term to the model’s loss function to prevent overly
complex models.
L1 Regularization
4. Cross Validation
Cross validation divides the dataset into multiple subsets and repeatedly trains the model
using different subsets for training and validation.
Advantages:
In dropout:
Benefits include:
6. Early Stopping
If validation error starts increasing while training error continues decreasing, the training
process is stopped.
This prevents the model from learning noise in the training dataset.
7. Model Simplification
Examples include:
• Reducing the number of features
Applications
Techniques for controlling overfitting are used in many applications such as:
• Medical image classification
• Face recognition systems
• Autonomous driving
Conclusion
Overfitting is a common challenge in image classification tasks that reduces the model’s
ability to generalize. Techniques such as data augmentation, regularization, cross
validation, dropout, early stopping, and increasing training data help improve
classification performance and ensure reliable predictions on unseen data.
a) Demonstrate how cross validation helps in selecting the best classifier model. (7
Marks)
Answer
Cross validation is a model evaluation technique used to assess how well a classifier performs
on unseen data. It is widely used in machine learning to compare different classification
models and select the most accurate one.
5. Repeat the process until every subset has been used as validation.
6. Compute the average performance across all folds.
Selecting the Best Classifier
• Decision Tree
• K-Nearest Neighbors (KNN)
• Neural Networks
Advantages
• Prevent overfitting
• Provide reliable model evaluation
• Select optimal hyperparameters
b) Explain how training, validation and testing datasets are used to evaluate model
performance. (7 Marks)
Answer
To properly evaluate classification models, datasets are usually divided into three parts:
• Training dataset
• Validation dataset
• Testing dataset
1. Training Dataset
The classifier learns patterns and relationships between input features and class labels.
Example:
Images used to train a system that identifies animals.
2. Validation Dataset
The validation dataset is used during training to tune the model.
It helps in:
• Selecting hyperparameters
• Preventing overfitting
The validation dataset guides the training process.
3. Testing Dataset
This dataset provides an unbiased estimate of how well the classifier will perform in real-
world scenarios.
Importance
• Better generalization
• Reduced overfitting
Answer
Classification errors occur when the predicted class label differs from the actual class label.
These errors are commonly represented using a confusion matrix.
Answer
It modifies the loss function by adding a penalty term for large parameter values.
Types of Regularization
L1 Regularization
• Adds the absolute value of weights to the loss function
• Encourages sparse models
L2 Regularization
• Adds the squared value of weights to the loss function
Benefits of Regularization
• Reduce overfitting
• Improve model generalization
• Control model complexity
Example
Answer
Cross validation is a technique used to evaluate and compare machine learning models by
dividing the dataset into multiple subsets for training and validation.
It provides a more reliable estimate of model performance than using a single train-test split.
Answer
It limits the complexity of the model by restricting the magnitude of model parameters.
Answer
Overfitting occurs when a classification model learns the training data too closely, including
noise and irrelevant patterns.
As a result, the model performs very well on the training dataset but performs poorly on
unseen test data.
Overfitting reduces the ability of the classifier to generalize and decreases prediction
accuracy in real-world applications.
SUBMODULE 3
Question 121 (14 Marks)
Answer
Introduction
Object tracking in computer vision refers to the process of continuously locating a moving
object across consecutive frames of a video. In real-world video scenes, objects rarely move
in a perfectly predictable way. Instead, they may change direction, speed, or trajectory due to
various environmental factors. These changes are called motion variations.
Tracking systems must handle such motion variations effectively to maintain accurate
tracking.
Motion Variation in Practical Videos
In practical video scenes, objects may exhibit different types of motion variations such as:
• Changes in speed
• Sudden direction changes
• Acceleration or deceleration
For example, a person walking in a surveillance video may suddenly turn or stop, causing
unpredictable motion.
1. Motion Models
Motion models describe how objects move from one frame to the next.
Examples include:
These models predict the next position of the object based on previous motion.
2. Kalman Filter
Kalman filters are widely used in tracking systems to estimate object motion.
3. Particle Filters
Particle filters are used when motion is highly unpredictable.
Advantages:
4. Optical Flow
Optical flow estimates motion between consecutive frames by analyzing pixel movement.
Example
Conclusion
Handling motion variation is essential for robust tracking systems. Techniques such as
motion models, Kalman filters, particle filters, and optical flow help maintain accurate
tracking even when objects move unpredictably.
b) Explain how adaptive models help maintain tracking accuracy during scale and
appearance changes. (7 Marks)
Answer
Introduction
In video tracking, the appearance of objects may change due to factors such as scale
variation, lighting changes, or object deformation. Adaptive models help update the tracking
model to account for these changes and maintain accurate tracking.
Scale Variation
Scale variation occurs when the object moves closer to or farther from the camera.
Example:
• A person walking toward the camera appears larger in the frame.
Adaptive tracking models update the size of the tracking window to match the object scale.
Appearance Changes
• Lighting conditions
• Viewing angles
• Object rotation
• Partial occlusion
Example:
A person turning sideways may look different from a frontal view.
The tracking system updates the appearance model using newly observed frames.
Benefits:
2. Multi-scale Tracking
Multi-scale tracking uses different window sizes to detect objects at different scales.
3. Feature Adaptation
Tracking models update features such as:
• Color histograms
• Texture descriptors
• Shape features
Example
Conclusion
Adaptive tracking models improve robustness by updating object representations during
tracking. By handling scale variation and appearance changes, adaptive models maintain
accurate object tracking in dynamic environments.
Tracking strategies are methods used to monitor moving objects across video frames.
Different strategies are used depending on the complexity of the scene and object motion.
1. Feature-Based Tracking
Feature-based tracking uses distinctive features such as corners or edges to track objects.
Example features:
• SIFT features
• SURF features
• Harris corner points
2. Region-Based Tracking
Region-based tracking identifies a region or bounding box around the object and tracks that
region.
• CamShift tracking
3. Motion-Based Tracking
Example methods:
• Optical flow
• Frame differencing
4. Model-Based Tracking
Example:
Tracking a human body using body structure models.
Applications
• Autonomous vehicles
• Sports analysis
• Human activity monitoring
b) Explain how appearance and motion cues are used together to improve tracking
performance. (7 Marks)
Answer
Tracking performance improves when both appearance cues and motion cues are combined.
Appearance Cues
Appearance cues describe the visual characteristics of the object.
Examples include:
• Color information
• Texture features
• Shape descriptors
Motion Cues
Examples include:
• Direction of movement
• Motion trajectory
Steps involved:
In surveillance videos:
Answer
Object tracking systems follow a sequence of processing steps known as the tracking
pipeline.
1. Video Acquisition
2. Object Detection
• Background subtraction
• Feature-based detection
3. Feature Extraction
• Shape features
• Texture features
4. Motion Estimation
Techniques include:
• Optical flow
• Motion models
5. Object Association
The system associates detected objects across frames.
This ensures that the same object is tracked over time.
6. Trajectory Generation
Applications
Tracking pipelines are used in:
• Surveillance systems
• Traffic monitoring
• Sports analytics
Advantages
Example
In pedestrian tracking:
Answer
Tracking by detection is a method in which objects are first detected independently in each
video frame and then associated across frames to maintain object identity.
Instead of relying only on motion prediction, the system repeatedly detects objects using an
object detector and links the detections to track objects over time.
This approach improves tracking accuracy and allows objects to be re-detected even after
temporary occlusion.
Question 125 (3 Marks)
Answer
Three commonly used tracking strategies in video analysis are:
Answer
Object tracking is the process of locating and following a moving object across consecutive
frames of a video sequence.
The goal of object tracking is to maintain the identity and position of the object as it moves
through the scene.
SUBMODULE 4
Question 127 (14 Marks)
a) Apply linear dynamical models for motion prediction in video tracking systems. (7
Marks)
Answer
In video tracking systems, the position of a moving object must be predicted in future frames
based on its previous motion. Linear dynamical models (LDM) are mathematical models
used to describe and predict the motion of objects over time.
A linear dynamical model represents the motion of an object using a state vector that
includes parameters such as position and velocity.
𝑥𝑡 = [𝑥, 𝑦, 𝑣𝑥 , 𝑣𝑦 ]𝑇
Where:
The motion of the object between frames is described using the state transition equation:
𝑥𝑡 = 𝐴𝑥𝑡−1 + 𝑤𝑡
Where:
• 𝑥𝑡 = state at time 𝑡
• 𝑤𝑡 = process noise
In tracking systems, the model predicts the next position of the object based on its previous
position and velocity.
Example:
In a traffic monitoring system, a vehicle moving along a road can be tracked by predicting its
next location using the linear dynamical model.
The predicted position helps the tracking algorithm search for the object within a smaller
region, improving tracking efficiency and accuracy.
Thus, linear dynamical models are widely used in video surveillance, autonomous driving,
and robotics for motion prediction.
b) Explain how model parameters are estimated and updated during tracking. (7
Marks)
Answer
In object tracking systems, the parameters of the motion model must be continuously
estimated and updated as new video frames are processed.
• Noise parameters
Parameter Estimation
Initially, the model parameters are estimated from observations in the first few frames.
Example:
This initial estimate forms the initial state of the tracking model.
As new frames are processed, the tracking system performs two steps:
1. Prediction Step
The motion model predicts the next object state using the state transition equation.
2. Correction Step
The predicted state is compared with the actual observed object position.
The difference between the prediction and observation is used to update the model
parameters.
A commonly used technique for updating model parameters is the Kalman filter.
Importance
Updating model parameters helps tracking systems:
• Adapt to changes in motion
Answer
A linear dynamical model describes how the state of a moving object evolves over time
using linear equations. It is commonly used in object tracking and motion analysis.
State Representation
The motion of an object is represented using a state vector that includes position and
velocity.
𝑥𝑡 = [𝑥, 𝑦, 𝑣𝑥 , 𝑣𝑦 ]𝑇
Where:
The motion of the object between consecutive frames is described using the state transition
model:
𝑥𝑡 = 𝐴𝑥𝑡−1 + 𝑤𝑡
Where:
• 𝑥𝑡 = state at time 𝑡
• 𝑤𝑡 = process noise
The matrix 𝐴determines how position and velocity change over time.
Observation Model
The observed measurement is related to the object state using the equation:
𝑧𝑡 = 𝐻𝑥𝑡 + 𝑣𝑡
Where:
• 𝑧𝑡 = observed measurement
• 𝐻= observation matrix
• 𝑣𝑡 = observation noise
Example
In vehicle tracking:
• The linear dynamical model predicts the next position based on previous motion.
Importance
Linear dynamical models are important because they provide a structured way to represent
object motion and enable efficient prediction in tracking systems.
Answer
Prediction is a key component of object tracking systems. It estimates the future position of a
moving object using its previous motion information.
𝑥̂𝑡 = 𝐴𝑥𝑡−1
Where:
This equation estimates the object's future position based on its previous state.
Steps in Prediction
4. Search for the object near the predicted location in the next frame.
Example
• Using its velocity, the model predicts where the car will appear in the next frame.
This prediction reduces the search area and improves tracking efficiency.
Benefits
Prediction helps to:
Linear dynamical models represent object motion by describing how the object's state
changes over time using linear equations.
State Variables
The object's state includes parameters such as:
• Position coordinates
• Velocity components
𝑥𝑡 = [𝑥, 𝑦, 𝑣𝑥 , 𝑣𝑦 ]𝑇
Motion Representation
𝑥𝑡 = 𝐴𝑥𝑡−1 + 𝑤𝑡
Where:
Motion Characteristics
Example
In pedestrian tracking:
• The model predicts how the person moves across video frames.
Importance
These models simplify motion representation and form the basis for many tracking
algorithms.
b) Explain the role of prediction in tracking the future position of a moving object. (7
Marks)
Answer
Prediction plays a crucial role in object tracking by estimating the object's future location
before the next frame is processed.
Purpose of Prediction
Prediction Process
Example
• The model predicts where the person will appear in the next frame.
Advantages
Prediction improves:
• Tracking accuracy
• Tracking speed
Answer
2. Robot navigation and autonomous vehicles – Used to estimate the future position
of moving objects and avoid collisions.
Answer
State space representation describes the current state of a moving object using variables
such as position and velocity.
State space models are widely used in tracking algorithms such as Kalman filters.
Answer
A linear dynamical system model is a mathematical model that describes how the state of a
system changes over time using linear equations.
Linear dynamical models are commonly used for motion prediction, object tracking, and
control systems.
SUBMODULE 5
Question 133 (3 Marks)
Explain the difference between the prediction step and update step in the Kalman filter.
Answer
The Kalman filter estimates the state of a moving object through two main steps: prediction
and update (correction).
Prediction step:
In this step, the filter predicts the future state of the system using the motion model. It
estimates the next position of the object based on its previous state and motion dynamics.
Update step:
In this step, the predicted state is corrected using the actual measurement obtained from
sensors or observations. The filter combines the predicted value and measured value to
produce a more accurate estimate.
Thus, the prediction step estimates the future state, while the update step corrects the
prediction using new observations.
Answer
Introduction
The Kalman filter is a recursive estimation algorithm widely used in computer vision and
control systems for tracking moving objects. It provides an efficient method to estimate the
state of a system over time by combining predictions from a motion model with
measurements obtained from sensors.
In real-time tracking applications, the Kalman filter helps predict and update the position of
moving objects accurately even when measurements are noisy.
1. Prediction Stage
Prediction Step
In the prediction stage, the filter predicts the next state of the object using the motion model.
State prediction equation:
𝑥𝑡 = 𝐴𝑥𝑡−1 + 𝐵𝑢𝑡 + 𝑤𝑡
Where:
• 𝑥𝑡 = predicted state
• 𝑢𝑡 = control input
• 𝑤𝑡 = process noise
This step estimates where the object will appear in the next frame.
Update Step
When a measurement from the sensor becomes available, the filter updates the predicted state
using the measurement equation.
Measurement equation:
𝑧𝑡 = 𝐻𝑥𝑡 + 𝑣𝑡
Where:
• 𝑧𝑡 = observed measurement
• 𝐻= observation matrix
• 𝑣𝑡 = measurement noise
The Kalman filter combines the prediction and measurement to produce an improved
estimate.
In video tracking:
1. Detect object position in the current frame.
Example:
Tracking a moving car in a traffic monitoring system.
Advantages
Conclusion
b) Explain how process noise and measurement noise influence Kalman filter
performance. (7 Marks)
Answer
In Kalman filtering, two types of noise affect the accuracy of state estimation:
1. Process Noise
2. Measurement Noise
These noise components represent uncertainties in the system model and sensor
measurements.
Process Noise
Examples:
• Environmental disturbances
If process noise is high, the Kalman filter relies more on measurements rather than
predictions.
Measurement Noise
Measurement noise represents errors in sensor observations.
Examples include:
• Sensor inaccuracies
The Kalman filter balances prediction and measurement based on noise levels.
Conclusion
Process noise and measurement noise significantly influence Kalman filter performance.
Accurate modeling of these noises helps achieve reliable state estimation in tracking systems.
Illustrate how the Kalman filter balances prediction and measurement to estimate
object position.
Answer
Introduction
The Kalman filter is a powerful algorithm used to estimate the position of moving objects by
combining predictions from a motion model with measurements obtained from sensors.
This balancing of prediction and measurement helps achieve accurate tracking even when
observations contain noise.
Prediction Step
In the prediction step, the filter estimates the object's future state using the previous state and
motion model.
Prediction equation:
𝑥𝑡 = 𝐴𝑥𝑡−1
This step provides an estimate of where the object is expected to appear in the next frame.
Measurement Step
The system then measures the object's actual position using sensors or detection algorithms.
Correction Step
The Kalman filter combines the predicted state and the measured state using a weighting
factor called the Kalman gain.
Kalman gain determines how much the prediction and measurement influence the final
estimate.
Example
In vehicle tracking:
Advantages
Conclusion
By combining predictions from the motion model with actual sensor measurements, the
Kalman filter produces accurate and stable estimates of object position in dynamic
environments.
Question 136 (14 Marks)
Answer
Kalman filtering is widely used in object tracking systems to estimate the position and
velocity of moving objects over time.
The algorithm recursively updates the estimated state of the object using predictions and
observations.
1. State Vector
• Position
• Velocity
Example:
𝑥𝑡 = [𝑥, 𝑦, 𝑣𝑥 , 𝑣𝑦 ]𝑇
2. Prediction Stage
The system predicts the next state using the motion model.
3. Measurement Stage
4. Correction Stage
Example
Applications
• Video surveillance
• Autonomous driving
• Robot navigation
Answer
The Kalman filter is based on several assumptions about the system and noise characteristics.
Both process noise and measurement noise are assumed to follow a Gaussian distribution.
The system matrices such as state transition matrix and observation matrix must be known.
Importance
These assumptions simplify the mathematical formulation and allow efficient computation of
optimal state estimates.
Answer
In the Kalman filter, the state vector represents the current estimated state of the system,
such as position and velocity of a moving object.
The covariance matrix represents the uncertainty or error in the state estimate. It indicates
how confident the filter is about the predicted state.
During filtering, the covariance matrix is updated to reflect changes in uncertainty, helping
the filter determine how much to rely on predictions or measurements.
Answer
In Kalman filtering, prediction refers to estimating the future state of a system using the
previous state and motion model.
Correction (or update) refers to adjusting the predicted state using the actual measurement
obtained from sensors.
Prediction provides an estimate of the system state, while correction improves the estimate by
incorporating new observations.
SUBMODULE 6
Question 139 (14 Marks)
Answer
Introduction
The Kalman filter is a recursive algorithm used for estimating the state of a dynamic system
from noisy observations. In computer vision and video tracking, it is widely used to estimate
the position and velocity of moving objects over time. The Kalman filter continuously
updates its estimates using two major steps: prediction and correction (update).
The algorithm is especially useful in tracking applications where measurements may contain
noise or uncertainty.
1. Initialization
𝑥0 = [𝑥, 𝑦, 𝑣𝑥 , 𝑣𝑦 ]𝑇
Where
𝑥, 𝑦= object position
𝑣𝑥 , 𝑣𝑦 = velocity components
2. Prediction Step
The filter predicts the next state of the object using the state transition model.
State prediction:
𝑥𝑡 = 𝐴𝑥𝑡−1
Covariance prediction:
𝑃𝑡 = 𝐴𝑃𝑡−1 𝐴𝑇 + 𝑄
Where
𝐴= state transition matrix
𝑄= process noise covariance
This step estimates where the object will appear in the next frame.
3. Measurement Step
𝑧𝑡 = [𝑥𝑚𝑒𝑎𝑠𝑢𝑟𝑒𝑑 , 𝑦𝑚𝑒𝑎𝑠𝑢𝑟𝑒𝑑 ]𝑇
However, measurements may contain noise.
Kalman gain:
𝐾𝑡 = 𝑃𝑡 𝐻 𝑇 (𝐻𝑃𝑡 𝐻 𝑇 + 𝑅)−1
𝑥𝑡 = 𝑥𝑡 + 𝐾𝑡 (𝑧𝑡 − 𝐻𝑥𝑡 )
Updated covariance:
𝑃𝑡 = (𝐼 − 𝐾𝑡 𝐻)𝑃𝑡
Where
𝐻= observation matrix
𝑅= measurement noise covariance
The Kalman filtering algorithm provides a structured approach for estimating object motion
in video sequences. By continuously predicting and updating object states, it enables accurate
and efficient tracking in dynamic environments.
Illustrate the role of state transition and measurement models in Kalman filter based
motion estimation.
Answer
Introduction
In Kalman filter based motion estimation, two important models describe the system
dynamics and observations:
2. Measurement model
These models allow the Kalman filter to estimate the motion of objects and update the
estimates using observed data.
The state transition model describes how the object's state changes over time.
State equation:
𝑥𝑡 = 𝐴𝑥𝑡−1 + 𝑤𝑡
Where
𝑥𝑡 = state at time 𝑡
𝐴= state transition matrix
𝑤𝑡 = process noise
𝑥𝑡 = [𝑥, 𝑦, 𝑣𝑥 , 𝑣𝑦 ]𝑇
The transition matrix defines how position and velocity change between frames.
Measurement Model
The measurement model relates the predicted state to the observed measurement.
Measurement equation:
𝑧𝑡 = 𝐻𝑥𝑡 + 𝑣𝑡
Where
𝑧𝑡 = measurement vector
𝐻= observation matrix
𝑣𝑡 = measurement noise
Example
In tracking a pedestrian:
• State transition model predicts the next position.
Importance
Conclusion
The state transition model predicts object motion while the measurement model corrects the
prediction using observations. Both models are essential for accurate motion estimation in
Kalman filtering.
The prediction step estimates the future state of the system based on the previous state and
the motion model.
Where
Covariance Prediction
𝑃𝑡 = 𝐴𝑃𝑡−1 𝐴𝑇 + 𝑄
Where
Purpose
The prediction step:
• Estimates the next state of the object
Example
• The system predicts where the car will appear in the next frame.
b) Derive the Kalman filter update (correction) step using the measurement equations.
(7 Marks)
Answer
The update step corrects the predicted state using the actual measurement obtained from
sensors.
Measurement Equation
𝑧𝑡 = 𝐻𝑥𝑡 + 𝑣𝑡
Where
𝑧𝑡 = measurement vector
𝐻= observation matrix
𝑣𝑡 = measurement noise
Kalman Gain
The Kalman gain determines how much weight is given to the measurement.
𝐾𝑡 = 𝑃𝑡 𝐻 𝑇 (𝐻𝑃𝑡 𝐻 𝑇 + 𝑅)−1
Where
𝑃𝑡 = (𝐼 − 𝐾𝑡 𝐻)𝑃𝑡
Purpose
Answer
The covariance matrix represents the uncertainty or error in the estimated state of the
system.
Answer
The state vector represents the internal state of a system that needs to be estimated. In object
tracking, it may include parameters such as position and velocity of the object.
Example:
𝑥𝑡 = [𝑥, 𝑦, 𝑣𝑥 , 𝑣𝑦 ]𝑇
The measurement vector represents the observations obtained from sensors or detectors.
Example:
𝑧𝑡 = [𝑥𝑚𝑒𝑎𝑠𝑢𝑟𝑒𝑑 , 𝑦𝑚𝑒𝑎𝑠𝑢𝑟𝑒𝑑 ]𝑇
Thus, the state vector describes the system state while the measurement vector provides
observed data used to update the estimate.
Answer
The Kalman filter algorithm consists of two main steps:
1. Prediction Step – The filter predicts the next state of the system using the motion
model.
2. Update (Correction) Step – The predicted state is corrected using the measurement
obtained from sensors.
These two steps are repeated continuously to estimate the state of the system over time.