Image Classification through Handcrafted Features using Machine Learning Algorithms
A C++ application for detecting image forgery using SURF (Speeded Up Robust Features) feature detection and matching algorithms.
- Converts input images to grayscale
- Extracts SURF features from images
- Matches features between original and suspect images
- Provides visual comparison with matching points
- Displays forgery detection results with confidence metrics
- OpenCV (with contrib modules for SURF)
- C++ compiler
- CMake (for building)
- Install OpenCV with contrib modules:
git clone https://github.com/opencv/opencv_contrib.git
git clone https://github.com/opencv/opencv.git
cd opencv
mkdir build && cd build
cmake -DOPENCV_EXTRA_MODULES_PATH=../../opencv_contrib/modules ..
make -j4
sudo make install- Clone this repository:
git clone https://github.com/kshitisha/Minor_Project1.git
cd Minor_Project1mkdir build
cd build
cmake ..
makeRun the program with three arguments:
./image_classifier <original_image> <output_grayscale_image> <suspect_image>Example:
./image_classifier original.jpg grayscale.jpg suspect.jpg- The program converts the original image to grayscale
- SURF features are extracted from both images
- Feature matching is performed using BFMatcher
- Good matches are filtered based on distance thresholds
- Results are displayed with visual matching points
- Classification decision is made based on number of good matches
A JavaScript-based web interface is included for easier interaction:
- Upload original and suspect images
- View image previews
- Get detailed forgery detection results
- Confidence scores and match statistics