VisiSolve is a vision-based equation resolver that employs image processing and machine learning techniques to recognize handwritten mathematical equations. This project aims to overcome the challenges associated with interpreting handwritten symbols through a series of preprocessing steps and neural network evaluations.
- Noise Reduction: Two versions developed; basic thresholding and blurring (Version 1), and advanced techniques including shadow removal and adaptive thresholding (Version 2). Command-line execution with
-nparameter to select the version. - Brightness Adjustment: Not included due to potential impairment of results.
- Histogram Equalization: Tested but not optimal for preprocessing as it could amplify unwanted background features.
- Symbol Extraction: Implemented in two versions; Mean Shift Clustering (Version 1) and Contour Detection (Version 2). Command-line execution with
-sparameter to select the version. - Results: Version 2 (Contour Detection) proved more effective for symbol segmentation.
Transformed separated symbols into a consistent format for CNN processing, which involved centering and resizing symbols to a standard size of 28x28 pixels.
A collection of handwritten mathematical operators and numbers, comprising 554 images per symbol, publicly available for use.
Evaluated various neural network architectures:
- Multi-layer Perceptrons (MLPs): Both shallow and deep architectures were tested.
- Convolutional Neural Networks (CNNs): Shallow and deep architectures were evaluated, with the deep CNN emerging as the superior model due to better generalization capabilities.
The project highlights the importance of advanced noise reduction, image preprocessing, and deep CNNs for the recognition of handwritten mathematical symbols. The deep CNN demonstrated the best performance in terms of accuracy and loss metrics.
Use the following command to execute the noise reduction and symbol extraction on the specified image:
python pipeline.py -n [Noise Reduction Version] -s [Symbol Extraction Version] -f [Image Path]
Example:
python pipeline.py -n 1 -s 2 -f ./eq_rejected.png
- Various references to methods and datasets used are included in the report.
- Project Report: View the full project report here
- Presentation Slides: Access the presentation slides here