0% found this document useful (0 votes)
59 views9 pages

Computer Vision Unit 4

The document discusses various computer vision techniques, including Sobel and Canny edge detection, corner detection, and deformable shape analysis, emphasizing their applications in traffic management, medical imaging, and augmented reality. It outlines the steps involved in these algorithms and the importance of edge detection in accurately identifying features in images. Additionally, it addresses the significance of behavioral design patterns in computer vision systems and the role of assertions and reasoning in understanding edge detection concepts.

Uploaded by

denzel0070
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
59 views9 pages

Computer Vision Unit 4

The document discusses various computer vision techniques, including Sobel and Canny edge detection, corner detection, and deformable shape analysis, emphasizing their applications in traffic management, medical imaging, and augmented reality. It outlines the steps involved in these algorithms and the importance of edge detection in accurately identifying features in images. Additionally, it addresses the significance of behavioral design patterns in computer vision systems and the role of assertions and reasoning in understanding edge detection concepts.

Uploaded by

denzel0070
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 9

computer vision unit 4

1.1.Question
To enhance traffic flow management at a congested intersection, a smart surveillance system is
being developed that leverages real-time CCTV camera feeds to detect and count vehicles. A key
challenge in this project is ensuring reliable vehicle detection under diverse lighting conditions, such
as intense daylight glare and low-light nighttime environments. To address this, the development
team integrates Sobel Edge Detection into the image pre-processing stage.
a)Based on this scenario, rearrange the steps involved in Sobel edge detection using Python and the
OpenCV library. Step 1: Apply Gaussian Smoothing - to reduce noise and make edge detection more
robust.
Step 2: Load and Display the Image - load a sample image and display it to understand what we’re
working with.
Step 3: Calculate Gradient Magnitude - Compute the gradient magnitude from the gradients in the x
and y directions. A threshold is applied to the gradient magnitude image to classify pixels as edges
or non-edges. Pixels with gradient magnitude above the threshold are considered edges.
Step 4: Display the Resulting Edge Image - normalize and display the edge-detected image Step 5:
Convert to Grayscale - the Sobel operator works on single-channel images.
Step 6: Normalization - the gradient magnitude and individual gradients.
Step 7: Apply Sobel Operator - to calculate the gradients in the x and y directions. Step 8:
Normalized range 0-255 for better visualization.
b)Based on this scenario, identify the functions of Sobel edge detection operator.
I.1212 filters
II.vertical Roberts Cross kernel
III.horizontal edges
IV.gradient direction
V.33 filters
VI.vertical edges
VII.vertical Prewitt kernel
positive values and negative values

Edge models are theoretical constructs used to describe and understand the different types of
edges that can occur in an image. These models help in developing algorithms for edge detection
by categorizing the types of intensity changes that signify edges. The basic edge models for step is
given as,
![|173x117](file:///C:\Users\kirut\AppData\Local\Temp\ksohtml47024\wps1.jpg)

Figure: Edge model Step

Construct an edge model for Ramp and Roof.

Question
A company is developing a smart medical imaging system to assist radiologists in detecting
abnormalities in X-ray images. The system needs to highlight sharp edges of bones and tissues
while filtering out noise from the medical scans.
Given the requirement for precise edge detection, the development team decides to implement the

Printed using ChatGPT to PDF, powered by PDFCrowd HTML to PDF API. 1/9
Canny Edge Detection algorithm.
In this case, rearrange the steps of Canny Edge Detection for extracting meaningful edges. Step 1:
Calculate Gradient Magnitude and Direction
Step 2: Binary Edge Map Output
Step 3: Apply Gaussian Blur (Noise Reduction)
Step 4: Apply Double Thresholding (High & Low Thresholds) Step 5: Convert Image to Grayscale
Step 6: Edge Tracking by Hysteresis
Step 7: Apply Non-Maximum Suppression
Step 8: Compute Image Gradients using Sobel Filters

4.Question
Consider a derivative of an image that measures the rate of change of pixel intensity and is useful
for detecting edges, as the derivatives can be classified into first derivative and second derivative.

image
image
707×546 29.1 KB

5.5.Question
Assertion (A) and Reason (R) type question:

Assertion (A): Corner detection algorithms identify points in an image where the gradient changes in
multiple directions.
Reason (R): Interest points are used in computer vision to extract unique features for matching,
object recognition, and tracking. Prefer the correct answer:
a)Both A and R are true and R is the correct explanation of A.
b)Both A and R are true but R is not the correct explanation of A.
c)A is false but R is true.
Both A and R are false.

6.6.Question
An augmented reality (AR) application is being developed to overlay digital information on real-
world objects. The AR system relies on detecting stable features in an image to accurately align
virtual objects with the physical environment.
Based on this scenario, find out the valid statements and provide justification on Corner and
Interest Point Detection in computer vision.

a.Corners are detected at points where the intensity changes significantly in multiple directions.
b.Shi-Tomasi Detector ignores all eigenvalues while detecting corners.
c.Interest points are key points that are stable under transformations such as scaling.
d.Interest point detection is widely used in application like object recognition.
e.Interest points are only used for detecting edges in images.
f.The Harris Corner Detector is sensitive to rotation rotation-invariant but not scale-invariant.
g.Corners can only be detected in grayscale images.
h.Subpixel accuracy can improve the precision of detected interest points.
i.Corner and interest point detection methods are useless in real-time CV applications.
Interest point detection cannot be used for object tracking.

7.Question
The process of identifying and analyzing the boundaries between different regions or objects within
an image, essentially outlining the edges of objects by detecting significant changes in pixel
Printed using ChatGPT to PDF, powered by PDFCrowd HTML to PDF API. 2/9
intensity or other image features, allowing for further analysis like object segmentation, shape
recognition, and feature extraction.

Complete the diagram with their blocks listed below for the shot boundary detection method.
(Shot boundaries are detected, Apply Cut Transition Detection, Shot boundary is detected, Select the
candidate segment, Apply Gradual Transition Detection

image
image
887×565 35.2 KB
8.Question
At airports, automated facial recognition systems verify passenger identities by comparing their
faces with stored biometric data. Thinning techniques simplify facial structures, reducing noise from
lighting variations or skin texture. This helps in accurately matching facial features, ensuring secure
and efficient passenger authentication, even under different lighting conditions or facial
expressions.

In a facial recognition system, thinning is applied to the contour of facial features such as the nose,
eyes, and mouth. Predict thinning improve the accuracy of feature recognition? Justify your answer.

9.9.Question
A digital forensics team is tasked with analyzing a dataset of 3D printed objects suspected of
intellectual property theft. The objects in question were modified slightly to bypass detection
algorithms. Using Deformable Shape Analysis, the team aims to identify subtle changes in the
geometric properties of the objects when compared to the original designs.

Predict the Deformable Shape Analysis to detect modifications in the 3D printed objects. Which of
the following would be the best approach and justify your answer.

a)Compare pixel intensity distributions of the objects using 2D images.


b)Measure geometric distortions in key features such as curves and angles.
c)Use checksum validation to identify changes in file integrity.
Perform binary pattern matching of object textures.

Question
A medical imaging system is being designed to track changes in organ shapes over time to detect
diseases. The system uses deformable shape analysis to model the variations in a patient’s organ
shapes across scans, accounting for factors like breathing-induced deformations and slight
positional changes during imaging. The goal is to identify pathological changes while ignoring
normal anatomical deformations.
a) Identify the difference between normal anatomical deformations in medical imaging helps in
tracking organ shape variations over time by Deformable shape analysis for the given scenario and
also justify it. (3Marks)
(Slight Positional Changes, Pathological Changes Identification, Multiple Sclerosis, Breathing-
Induced Deformations, Chronic Obstructive Pulmonary Disease)

Scenario 1: The system accounts for changes in organ shape due to respiration, ensuring that
normal movement does not lead to false positives.

Scenario 2: Variations in patient positioning during different scans are modeled to avoid
misinterpretation of shape differences. Scenario 3: It isolates abnormalities such as tumor
Printed using ChatGPT to PDF, powered by PDFCrowd HTML to PDF API. 3/9
progression, tissue shrinkage, or structural deformations that are not explained by normal
variations.

Assertion (A): A medical imaging system using deformable shape analysis can accurately
differentiate between normal anatomical deformations and pathological changes in organ shape.

Reason (R): Deformable shape analysis considers factors such as breathing-induced deformations
and slight positional changes to avoid false positives in disease detection.

Identify the correct answer and justify the reason. (3Marks)

Both Assertion (A) and Reason (R) are true, and (R) is the correct explanation of (A).

Both Assertion (A) and Reason (R) are true, but (R) is not the correct explanation of (A).

Assertion (A) is true, but Reason (R) is false.

Assertion (A) is false, but Reason (R) is true.


11.11. Question
The Canny Edge Detection algorithm is a widely used edge detection algorithm in today’s image
processing applications. Canny edge detection algorithm produces smoother, thinner, and cleaner
images than Sobel and Prewitt filters.

Here is a summary of the canny edge detection algorithm-


1.Smooth the input image and apply the Sobel filter to detect the edges.
2.Use non-max suppression to retain the local maximum pixels in the gradient direction while
suppressing the rest.
3.Apply thresholding to remove pixels below a certain threshold and retain those above it,
eliminating edges that could form due to noise.
4.Apply hysteresis tracking to make a pixel strong if any of the 8 neighboring pixels are strong.

Refer the algorithm and sketch the canny edge detection diagram with the process given below.
(Process: Finding gradients, Thresholding, Image smoothening, Edge tracking by hysteresis, non-
max suppressing)

Question
In a smart city traffic monitoring system, cameras are placed at various intersections to capture and
analyze traffic flow. The system uses object labeling and counting to track the number of vehicles,
pedestrians, and cyclists at the intersection. This helps traffic authorities manage congestion,
ensure pedestrian safety, and optimize traffic signal timing.
The object labeling system in traffic monitoring can accurately identify and classify different types of
vehicles, such as cars, buses, and trucks, allowing the system to count them separately for traffic
analysis.

13.Identify the given statment is valid or not and justify your answer.
Question
Complete the missing sections C1, B2, C3 and B4.

Transformation (A) Mapping (B) Key points (C)


A1.Geometric Transformation B1. A method for aligning images using scale, rotation, or translation
C1. ?
Printed using ChatGPT to PDF, powered by PDFCrowd HTML to PDF API. 4/9
A2. Homography B2. ? C2.A relationship that describes how an image is mapped onto a different
plane
A3. Image Registration B3. Mapping between two images of the same scene C3. ?
A4.Perspective Transformation B4. ? C4. Image Transformation
14.Question
Behavioral design patterns in computer vision help structure interactions between objects and
algorithms, making systems more maintainable and scalable. These patterns help manage complex
workflows, event handling, and decision-making logic in vision-based applications.

Map the appropriate descriptions that can be implemented on Behavioural design patterns. [Hint]:
Command, Mediator, Chain of Responsibility, Memento, Iterator.
a.Pass requests along a chain of handlers.
b.Turns a request into a stand-alone object that contains all information about the request.
c.Traverse elements of a collection without exposing its underlying representation (list, stack, tree,
etc.).
d.Reduce chaotic dependencies between objects.
Save and restore the previous state of an object without revealing the details of its implementation.

15.15.Question
Assertion (A): Abstraction is a high-level control layer for some entity. This layer isn’t supposed to do
any real work on its own. It should delegate the work to the implementation layer.

Reason (R): When talking about real applications, the abstraction can be represented by a graphical
user interface (GUI), and the implementation could be the underlying operating system code (API)
which the GUI layer calls in response to user interactions.

Options:
a)Both A and R are true and R is the correct explanation of A.
b)Both A and R are true but R is not the correct explanation of A.
c)A is false but R is true.
d)Both A and R are false.

Identify the correct statement and justify it.

Here are the detailed answers to each of your questions:

1.1 (a) Sobel Edge Detection Steps (Rearranged in correct order)

Correct Order:

1. Step 2: Load and Display the Image

2. Step 5: Convert to Grayscale


3. Step 1: Apply Gaussian Smoothing
4. Step 7: Apply Sobel Operator

5. Step 3: Calculate Gradient Magnitude

Printed using ChatGPT to PDF, powered by PDFCrowd HTML to PDF API. 5/9
6. Step 6: Normalization
7. Step 8: Normalized range 0–255 for better visualization
8. Step 4: Display the Resulting Edge Image

1.1 (b) Functions of the Sobel Edge Detection Operator

Valid functions:

III. Horizontal edges

IV. Gradient direction


VI. Vertical edges

V. 3×3 filters
Positive values and negative values (used in gradient computation)

Invalid options:

I. 1212 filters — Invalid


II. Vertical Roberts Cross kernel — Different operator

VII. Vertical Prewitt kernel — Different from Sobel

2. Edge Models – Ramp and Roof

Ramp Model
Represents a gradual transition in intensity. It’s a sloped curve showing a smooth gradient between
two regions.

Roof Model
Represents a sharp peak, where intensity increases and then decreases — common where two bright
regions meet with a dark boundary.

These help model realistic edge transitions in natural images.

3. Canny Edge Detection Steps (Correct Order)

Correct Order:

1. Step 5: Convert Image to Grayscale


2. Step 3: Apply Gaussian Blur (Noise Reduction)

3. Step 8: Compute Image Gradients using Sobel Filters

4. Step 1: Calculate Gradient Magnitude and Direction


5. Step 7: Apply Non-Maximum Suppression

6. Step 4: Apply Double Thresholding (High & Low Thresholds)

7. Step 6: Edge Tracking by Hysteresis

Printed using ChatGPT to PDF, powered by PDFCrowd HTML to PDF API. 6/9
8. Step 2: Binary Edge Map Output

4. First vs Second Derivative in Edge Detection

First derivative: Measures the rate of change, used in edge detection (Sobel, Prewitt).

Second derivative: Measures the rate of change of the rate of change, used to detect zero-
crossings (Laplacian of Gaussian).

5. Assertion & Reason (Corner Detection)

Assertion (A): True

Reason (R): True

R explains A accurately

✅ Correct Answer: (a) Both A and R are true and R is the correct explanation of A.
6. Corner and Interest Point Detection (Valid Statements)

Valid statements:

✅ a. Corners are detected at points where intensity changes in multiple directions.


❌ b. Shi-Tomasi uses eigenvalues (doesn't ignore them).
✅ c. Interest points are stable under scaling.
✅ d. Widely used in object recognition.
❌ e. Not only for edges.
✅ f. Harris detector is rotation-invariant but not scale-invariant.
❌ g. Can also be detected in color images by converting channels.
✅ h. Subpixel accuracy improves detection.
❌ i. Very useful in real-time applications.
❌ j. Interest points can be used for tracking.
7. Shot Boundary Detection – Complete the Diagram

Correct Order of Blocks:

1. Apply Cut Transition Detection

2. Select the Candidate Segment


3. Apply Gradual Transition Detection

4. Shot Boundary is Detected

8. Thinning for Facial Recognition


Printed using ChatGPT to PDF, powered by PDFCrowd HTML to PDF API. 7/9
✅ Yes, thinning improves accuracy.
Justification: Thinning simplifies the shape of facial features by reducing them to skeletal forms. This
reduces the influence of lighting/noise and helps the system focus on structural geometry, aiding in
more accurate feature matching even under variations.

9. Deformable Shape Analysis for 3D Printed Objects

Correct answer:
✅ (b) Measure geometric distortions in key features such as curves and angles

Justification: Comparing geometric structure (curves, angles, and shapes) helps detect subtle, non-
obvious changes — more effective than just pixel-level analysis.

10. Medical Imaging – Deformable Shape Analysis

✅ Correct Answer:
Both Assertion (A) and Reason (R) are true, and R is the correct explanation of A.

Justification: The system accurately distinguishes between normal anatomical variations (breathing,
posture) and abnormal pathological changes by modeling deformations across time, minimizing false
positives.

11. Canny Edge Detection – Sketch Blocks

Correct Process Order:

1. Image Smoothening (Gaussian filter)


2. Finding Gradients (Sobel operator)

3. Non-Max Suppression

4. Thresholding (double threshold)


5. Edge Tracking by Hysteresis

Use these to draw a flowchart-style diagram.

12. Smart City Traffic Monitoring – Object Labeling

✅ Valid Statement
Justification:
The object labeling system can use AI-based classifiers (YOLO, SSD, etc.) to accurately distinguish
between cars, buses, and pedestrians. This data is critical for traffic optimization and safety.

13. Complete the Table – Transformation Mapping

Transformation (A) Mapping (B) Key points (C)

A1. Geometric B1. A method for aligning images using scale, C1. Maintain spatial
Transformation rotation, or translation relationships

Printed using ChatGPT to PDF, powered by PDFCrowd HTML to PDF API. 8/9
Transformation (A) Mapping (B) Key points (C)

C2. A relationship that maps


A2. Homography B2. A transformation between planes
image planes

B3. Mapping between two images of the same C3. Aligns images for change
A3. Image Registration
scene detection

A4. Perspective B4. A transformation that simulates a camera


C4. Image Transformation
Transformation view

14. Behavioral Design Patterns

Pattern Description

a. Chain of Responsibility Pass requests along a chain of handlers


b. Command Turns a request into a stand-alone object

c. Iterator Traverse elements without exposing internal structure

d. Mediator Reduce chaotic dependencies between objects


e. Memento Save and restore previous state

15. Abstraction vs Implementation

✅ Correct Answer: a) Both A and R are true and R is the correct explanation of A.
Justification: Abstraction provides an interface (like GUI), and implementation carries out the
functionality (API, OS code). This structure is key to layered architecture.

Let me know if you’d like a visual diagram for the Canny process or Shot Boundary Detection.

Printed using ChatGPT to PDF, powered by PDFCrowd HTML to PDF API. 9/9

You might also like