Skip to content

Made a CNN model for the classification of Dog and Cat images and tested it with lookalike images.

Notifications You must be signed in to change notification settings

prateekagr21/Classification-of-pets

Repository files navigation

Classification of pets using Convolution Neural Networks!

For Solving this Usecase, What I have done is :

  • Collected the data and organized to form a meaningful dataset.
  • Used binary classification for Dog and Cat images.
  • Did Exploratory Data Analysis on the dataset.
  • Visualizations were made by using Matplotlib and Seaborn Libraries.

Did data Preprocessing.

Did Data Augmentation.

And then I made a Model for the Prediction :

Used Convolution Neural Networks - CNN

Created this model:

  • Added CNN layer
  • Max pooling
  • Added second layer
  • Flattening
  • Added Dense Layer

And then for the last layer,

  • Used Support Vector Machine - SVM
  • Since, it is a binary classification, so i used Linear SVM.

Initialized the Model
and Trained it.

  • by training for 20 epoches.!!

Plotted the Prediction.

Accuracy -

image

And Loss -

image

Finded the best parameters. Saved the model using Tensorflow's Load_model.

Now, for the Prediction part :

  • Read an image from the test dataset
  • And predicted it using the value of Array.
  • And the classification was distinguished using the positive and negative value of the resulted array.

And did the prediction again,

Model did right for the both time and hence, it works
And can be used for further classification regarding dog-cat images.

About

Made a CNN model for the classification of Dog and Cat images and tested it with lookalike images.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published