Teaching a Computer to Recognise Cats

Dr. Ahlad Kumar is currently doing research in Concordia University, Montreal Canada in the field of image processing. His area of interest is in the field of image restoration. He received his PhD degree from University of Malaya, Malaysia in 2016.

5428
Advertisement

Model testing:

In order to test the computer on how well it has learned to distinguish between cats and dogs, we provide it with the series of images not seen earlier and see how well it can identify the animal in each image. In Fig. 4 we show the sample of testing images consisting of three new cat and dogs not seen by the computer during the training phase. So, what computer does is it will take the features into account and check on which side of the line these images will fall. For instance, it can be observed in Fig. 5 all the new cats and all but one dog from the testing set have been identified properly. The misidentification of one of the dogs (shown in the red box) is completely due to our choice of features which we designed using training set as shown in Fig 1.

This dog is misunderstood as cat simply because its feature i.e. sizes of the nose and shape of the ears match with that of cats in the training set. To reduce this problem, we should train our computer with more training data and use more discriminating features that will help to distinguish cats from dogs.

Testing set of cats and dogs images, not in the training set
Fig. 4: Testing set of cats images, not in the training set
Fig. 4(B): Testing set of dogs images, not in the training set
Classification of test images using trained linear model
Fig.5: Classification of test images using trained linear model

To supplement this article, we are providing python script for recognizing cats from other animals. It has a database which consists of all kinds of animals and our algorithm will predict whether the image you uploaded to the software is a cat or not.

Download source file


Advertisement


SHARE YOUR THOUGHTS & COMMENTS

Please enter your comment!
Please enter your name here