All Projects → aditya9211 → Blur-and-Clear-Classification

aditya9211 / Blur-and-Clear-Classification

Licence: other
Classifying the Blur and Clear Images

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to Blur-and-Clear-Classification

Deepdetect
Deep Learning API and Server in C++14 support for Caffe, Caffe2, PyTorch,TensorRT, Dlib, NCNN, Tensorflow, XGBoost and TSNE
Stars: ✭ 2,306 (+2520.45%)
Mutual labels:  image-classification, neural-nets
Genann
simple neural network library in ANSI C
Stars: ✭ 1,088 (+1136.36%)
Mutual labels:  artificial-neural-networks, backpropagation
NumPyANN
Implementation of Artificial Neural Networks using NumPy
Stars: ✭ 85 (-3.41%)
Mutual labels:  artificial-neural-networks, ann
Malware Classification
Towards Building an Intelligent Anti-Malware System: A Deep Learning Approach using Support Vector Machine for Malware Classification
Stars: ✭ 88 (+0%)
Mutual labels:  image-classification, artificial-neural-networks
python-neuron
Neuron class provides LNU, QNU, RBF, MLP, MLP-ELM neurons
Stars: ✭ 38 (-56.82%)
Mutual labels:  artificial-neural-networks, ann
img classification deep learning
No description or website provided.
Stars: ✭ 19 (-78.41%)
Mutual labels:  image-classification, ann
ai-backpropagation
The backpropagation algorithm explained and demonstrated.
Stars: ✭ 20 (-77.27%)
Mutual labels:  artificial-neural-networks, backpropagation
etiketai
Etiketai is an online tool designed to label images, useful for training AI models
Stars: ✭ 63 (-28.41%)
Mutual labels:  image-classification
ICCV2021-Paper-Code-Interpretation
ICCV2021/2019/2017 论文/代码/解读/直播合集,极市团队整理
Stars: ✭ 2,022 (+2197.73%)
Mutual labels:  image-classification
image-recognition-and-information-extraction-from-image-documents
Image Recognition and Information Extraction from Image Documents using Keras and Watson NLU
Stars: ✭ 71 (-19.32%)
Mutual labels:  image-classification
LegoBrickClassification
Repository to identify Lego bricks automatically only using images
Stars: ✭ 57 (-35.23%)
Mutual labels:  image-classification
Spatially-Varying-Blur-Detection-python
python implementation of the paper "Spatially-Varying Blur Detection Based on Multiscale Fused and Sorted Transform Coefficients of Gradient Magnitudes" - cvpr 2017
Stars: ✭ 43 (-51.14%)
Mutual labels:  blur-detection
ai-background-remove
Cut out objects and remove backgrounds from pictures with artificial intelligence
Stars: ✭ 70 (-20.45%)
Mutual labels:  artificial-neural-networks
NeuroFlow
Awesome deep learning crate
Stars: ✭ 69 (-21.59%)
Mutual labels:  backpropagation
ML4K-AI-Extension
Use machine learning in AppInventor, with easy training using text, images, or numbers through the Machine Learning for Kids website.
Stars: ✭ 18 (-79.55%)
Mutual labels:  image-classification
deep-learning
Deep Learning Bootcamp
Stars: ✭ 60 (-31.82%)
Mutual labels:  image-classification
Poke-Pi-Dex
Our deep learning for computer vision related project for nostalgic poke weebs (Sistemi digitali, Unibo).
Stars: ✭ 18 (-79.55%)
Mutual labels:  image-classification
image-recognition
采用深度学习方法进行刀具识别。
Stars: ✭ 19 (-78.41%)
Mutual labels:  image-classification
super-gradients
Easily train or fine-tune SOTA computer vision models with one open source training library
Stars: ✭ 429 (+387.5%)
Mutual labels:  image-classification
Covid-chest-Image-classification-from-Deep-Residual-Networks
No description or website provided.
Stars: ✭ 14 (-84.09%)
Mutual labels:  artificial-neural-networks

Blur-and-Clear Images Classification

Classifying the Blur and Clear Images

Introduction

In day to day Life, we encounter the poor images clicked from our Camera due to poor focus, a motion of objects in the frame or handshaking motion while capturing the Images.

Blur is typically the thing which **suppress the high-frequency** of our Images, therefore can be detected by using various low-pass filter eg. Laplacian Filter.

As a smart person(myself a CS guy) we doesn't want to manually filter out the Clear and Blurred Images, so we need some smart way to delete the unnecessary Images.

LoG Filter

I also applied the Laplacian of gaussian(LoG) filter to detect the blur images, but it was difficult to find the exact value of the threshold needed to differentiate images; despite that results were not fascinating.

Used variance of LoG filter

Some of its discussions

https://stackoverflow.com/questions/7765810/is-there-a-way-to-detect-if-an-image-is-blurry

https://stackoverflow.com/questions/5180327/detection-of-blur-in-images-video-sequences

LoG Ref:

http://aishack.in/tutorials/sift-scale-invariant-feature-transform-log-approximation/

Repo which implemented LoG filter in Python: https://github.com/WillBrennan/BlurDetection2

As the Now, the era of Deep Conv Nets has suppressed the Standard Computer Vision Techniques, Thus I focussed on the root of it which is Neural Nets. Neural Nets learn very Quickly the complex features, therefore can be used much easily then std. CV technique. Tuning ANN efficiently can provide me the results much better than CV TEchnique.

Neural Network Model

Model has 3 Layers Containing

 1 Input Layer -> 100*100 U
 
 1 Hidden Layer -> 300 HU
 
 1 Output Layer -> 2 U

I have used the Backprop Algorithm for Training ANN using the SGD Optimizer with Momentum. Rescaled the Images to 100 x 100 Pixels in Grayscale Coding and done median filtering to filter out the noise from Images.

Quick Start

Need the Images that are clear in the separate folder and one with blurred in another folder.

# Python3+ user install Tkinter package (Python 3.5.xx)
# Currently code is supported for Python 3.5.xx version only
sudo apt-get install python3-tk
# Clone the repo
git clone https://github.com/aditya9211/Blur-and-Clear-Classification.git
# Change the working Directory
cd Blur-and-Clear-Classification/
# Install the requirements
pip install -r requirements.txt
# Train the Network
python train.py  --good_path  '/home/......good/'  --bad_path  '/home/......./bad/'
# Test the Network 
python test.py
# Predict output 
python predict.py --img '/home/....../laptop.png'

Code Structure

Code is segmented as follows:

  1. Training Part :

    train.py

    which train the neural network with given images and stores the trained parameters and splitted train, test set to disk

  2. Testing Part :

    test.py

    test the neural network with test data stored by train.py

  3. Predict Part :

    predict.py

    predict the label of images(Good/Bad) provided by argument while calling

  4. Config File :

    config.py

    contains the list of constant used by files or hyper-parameters which can be changed by editing this file

  5. Utiltities Part :

    utils.py

    helper functions or common function among used in train/test and predict

  6. Requirement Package :

    requirements.txt

    packages required for running scripts

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].