Binary Classification Deep Learning Model for Horses or Human Using TensorFlow Take 1

Template Credit: Adapted from a template made available by Dr. Jason Brownlee of Machine Learning Mastery.

SUMMARY: The purpose of this project is to construct a predictive model using various machine learning algorithms and to document the end-to-end steps using a template. The Horses or Humans dataset is a binary classification situation where we are trying to predict one of the two possible outcomes.

INTRODUCTION: When learning Computer Vision, especially the training of DNNs and CNNs to recognize and classify images, there is a shortage of suitable datasets. Laurence Moroney wanted to fix that problem by creating a dataset that could be used for teaching binary classifiers that were unique and distinct from existing datasets. Laurence also wished to see if he could use Photo-real CGI to train a neural network that could then recognize and classify real images with the same subject matter.

The set contains 500 rendered images of various species of horses in different poses in multiple locations. It also includes 527 rendered images of humans in various poses and locations. Emphasis has been taken to ensure the diversity of humans, and to that end, there are both men and women as well as different ethnic groups present in the training set. The validation set adds six different figures of varying gender, race, and pose to ensure the breadth of data.

In this Take1 iteration, we will construct and tune machine learning models for this dataset using TensorFlow with three VGG blocks. Laurence also demonstrated the dataset using a model with five VGG blocks, each block with just one convolution layer. We will observe the best result that we could obtain using different VGG-3 models with a different number of convolution layers.

ANALYSIS: From this Take1 iteration, the performance of the baseline model achieved an accuracy score of 82.03% on the validation dataset after 15 epochs. After a series of modeling trials, the TensorFlow model with three VGG blocks and two convolution layers processed the validation dataset with an accuracy score of 85.94%.

CONCLUSION: For this dataset, the model built using TensorFlow with three VGG blocks and two convolution layers the result from the baseline model. We should consider using TensorFlow and VGG blocks to model this dataset further.

Dataset Used: Horses or Humans Dataset

Dataset ML Model: Binary Classification with numerical attributes

Dataset Reference:

The HTML formatted report can be found here on GitHub.