Implement retrain model by using Inception V3
Training
1. The first thing download python code by Clone from https://github.com/tomtomAnalytics/magicscan
2. Next step is download dataset, which the most example use flower image dataset as this site http://download.tensorflow.org/example_images/flower_photos.tgz
3. Unzip dataset and copy all image folders to “datatemp” in the first step. Check each folder already has an image for training and testing.
Daisy flower
dandelion flower
roses flower
4. For my objective, I would like to change the label for each flower folder to be:
daisy >> 101-CH1011D1
dandelion >> 101-FD1011V1
roses >> 101-HO1036N1
sunflowers >> 201-NS1633H1
tulips >> 201-TT1611N1
Note!:
1. You should cut some image from each folder to be testing the model in testing process.
2. Images should be in .jpg format
4. Edit some information in flie “c2_retrainModel” as follwing:
For other parameters depend on you to change or do some modification.
If everything ready, go to run you code.!!!!!!!!
- In the first time of running this python file, it will be take long time because it will re-generate graph for modeling. It may take an hour for that processes.
- Wait for running till it finish! and then go for check it result!
Testing
1. From file “c3_label_image” edit some testing image path as follow:
2. Run “c3_label_image.py” and result is show as:
The model tell us that the testing image is categorized to be in 201-TT1611N1 for 69.072%, which corresponding with our testing image(D:/scansystem/magicscan/TestImg/201_TT1611N1_4.jpg)
Credit: https://www.tensorflow.org/hub/tutorials/image_retraining
Read this article from medium website: https://medium.com/@ascomlab.space/implement-retrain-model-by-using-inception-v3-707cc05a965c