In this chapter, we are going to classify food items using transfer learning. For this, we have built our own TensorFlow-based machine learning (ML) model of some Indian food items that we will focus on. Millions of parameters are there with the modern recognition models. We need a lot of time and data to train a new model from scratch, as well as hundreds of Graphical Processing Units (GPUs) or Tensor Processing Units (TPUs) that run for hours.
Transfer learning makes this task easier by using an existing model that is already trained and reusing it on a new model. In our example, we will use the feature extraction capabilities from the MobileNet model and train our own classifier on top of it. Even if we don't get 100% accuracy, this works best in a lot of cases and especially on a mobile phone, where we don't get...