Image Classification for Small Data Using Transfer Learning

In the previous chapters, we developed deep learning networks and explored various application examples related to image data. One major difference compared to what we will be discussing in this chapter is that, in the previous chapters, we developed models from scratch.

Transfer learning can be defined as an approach where we reuse what a trained deep network has learned to solve a new but related problem. For example, we may be able to reuse a deep learning network that's been developed to classify thousands of different fashion items to develop a deep network to classify three different types of dresses. This approach is similar to what we can observe in real life, where a teacher transfers knowledge or learning gained over the years to students or a coach passes on learning or experience to new players. Another example is where learning to ride a bicycle is transferred to learning to ride a motorbike and this, in turn, becomes useful for learning how to drive a car.

In this chapter, we will make use of pretrained deep networks while developing models for image classification. Pretrained models allow us to transfer useful features that we've learned from a much larger dataset to models we are interested in developing with a somewhat similar, but new and relatively smaller dataset. The use of pretrained models not only allows us to overcome issues as a result of the dataset being small, but also helps reduce the time and cost of developing models.

To illustrate the use of pretrained image classification models, in this chapter, we will cover the following topics:

  • Using a pretrained model to identify an image
  • Working with the CIFAR10 dataset
  • Image classification with CNN
  • Classifying images using the pretrained RESNET50 model
  • Model evaluation and prediction
  • Performance optimization tips and best practices
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset