Image Processing : Feature Extraction
CS-293 Guide: Prof G. Sivakumar
Compiled by: Siddharth Dhakad Chirag Sethi Nisarg Shah
Problem Definition
Image processing is a field of signal processing in which input and output signals are both images (2D matrices). Feature extraction involves simplifying the amount of resources required to describe a large set of data accurately. Our project studies and implements various algorithms on feature extractions.
The following Feature Extraction techniques were implemented
Edge Detection:
Sobels algorithm Cannys algorithm
Circle Detection:
Hough Transform
Line Detection:
Hough Transform
Corner Detection:
Trajkovics 8-neighbour algorithm
Solution Design & Implementation
Image
The images we handle are RGB type. Each pixel is a 32 bit integer. We have implemented a new data type for handling images called Picture.
Picture Class
Constructors
From Picture From a 2D array From a filename
Saving & Loading images Grayscale Crop
Picture Class
FILE SHOW IMAGE 2D ARRAY
IMAGE
EDIT PIXELS
GRAYSCALE
CROP
Edge Detection
Edge detection is a terminology which aim at identifying points in a digital image at which the image brightness changes sharply or more formally has discontinuities. Edge Detection algorithms are broadly classified as
First order Higher order
Original (Input) Image
Sobel Edge Detector
Input Image
Gray-Scaled Image
Masking
Threshold
Edge Detected
Canny Edge Detector
Input Image Gray-Scaled Image
Masking
Noise Reduction
Non-maxima Suppression
Threshold
Edge Detected
For reducing noise, we used Gaussian Filter (Blurring Algorithm). On edge detected by first order detector, we used an algorithm called Non-maximal Suppression to have single/thin edges. After that, we used Stack data structure for path traversal for finding continuous edges.
Manual Threshold
Automatic Threshold
Original Image
Sobel
Canny Manual
Canny Automatic
Canny v/s Sobel
Thin Edges Noise reduction Complete path High adjustability Thick Edges No blurring Discrete pixels Low adjustability
Line & Circle Detection
Input Image Edge Detection Hough Transform
Detected Lines/Circles
Threshold
Path Traversal
In Circle Detection, we also included taking range of radius of circles to be detected as input to make the algorithm run faster.
Original Image
Line Hough Transform
Original Image
Circle Hough Transform
Corner Detection
Input Image
Original Image
Cornerness of each pixel
Threshold
Corner Detected
Corner Detected
Threshold Selection
Manual:
User can set high-low thresholds for each operation performed during the algorithm.
Automatic:
By experimentation, we have found a heuristic to select a suitable threshold for any input image.
The Hard Part
Selecting suitable threshold for any input image Deciding the proper class hierarchy for modular implementation Implementing path traversal and nonmaximal suppression algorithms
Results & Analysis (Applied to standard test image)
Original Image
Standard Canny Output
Our Canny Output
Standard Sobel Output
Our Sobel Output
Original Image
Standard Canny Output
Our Canny Output
Automatic Canny Output
Our Sobel Output
Original Image
Standard Output
Our Output
Original Image
Standard Output
Our Output
Original Image
Standard Output
Our Output
Future Possibilities
Generalized Curve Detection Higher Order Edge Detection Some more shape based feature detection Optimizations in current algorithms Handling large size images Pattern recognition Face recognition
What we learnt
Feature Extraction Algorithms Limitations of algorithms when applied to real life problems
Image Size Selecting Threshold Noise
Handling Images
Image types : RGB, ARGB, Raster, Vector
Java/Swing Time Management Working as a team