Program implementing Transfer learning technique for the Devanagari Character Recognition.
Transfer Learning refers to is a machine learning method where a model developed for a task is reused as the starting point for a model on a second task. Hence preventing from training model from scratch thus saving the training time and computational power.
Three Approaches has been used in order to carry out the transfer learning for the purpose of Devanagari Character Recognition and the accuracy of all three approach has been compared.
- The VGG16 model pretrained over imagenet dataset was loaded and with all convolutional layer frozen only changing the dense layer according to requirement of classes for the classification of Devanagari Characters.
- The VGG16 model now is not totally freezed. The last layers of convolutional layers along with dense layers is fine tuned.
- A custom Model pretained on MNIST dataset(for number classification) which is similar to Devanagari Character Dataset was loaded and with all convolutional layer freezed and dense layer fine tuned was used for the training of Devanagari dataset.
Hence transfer Learning was implemented.
- vgg16 model is provided by keras which is pretrained on imagenet dataset
- mnist.json is the model trained for MNIST Dataset and mnist.h5 is the weights obtained after training MNIST dataset.
- VGG total frozen model.json is the model used for transfer learning with all convolutional layers of VGG model freezed.
- weights for Devanagri classification with total frozen VGG layers.h5 contains weights saved after training using first approach
- VGG fine tuning.json is the model used for transfer learning with last layers convolutional layers of VGG model fine tuned.
- weights for Devanagri classification with VGG last layers fine tuned.h5 contains weights saved after training using second approach
- MNIST Model fine tuning.json is model used for transfer learning with pretrained custom model trained on MNIST data.
- weights for Devanagri classification using fine tuning over MNIST Model.h5 contains weights saved after training using third approach