Introduction

Classify 5 kind of flowers which are daisy, tulip, rose, sunflower, and dandelion with convolutional neural network. I got the datasets from https://www.kaggle.com/alxmamaev/flowers-recognition. I use Keras VGG16, Xception, Resnet50, and InceptionV3 as pre-trained model and deploying it in browser.

How to deploy

  1. First, you must have Tensorflow, Keras, and Flask.
  2. Download weight and json file here.
  3. Make weight and json folder in the root folder and put the weights and json files there.
  4. Open a terminal in this folder.
  5. run python app.y.
  6. Open your browser and go to http://0.0.0.0:5000/.
  7. Click choose file to input the image that you want to classify and predict button to display the result of model prediction.

Train your own model!

  1. First, download the datasets.
  2. Split training set and test set to this kind folder structure :
    /datasets
      /training_set
       /daisy
       /sunflower
       /tulip
       /rose
       /dandelion
      /test_set
       /daisy
       /sunflower
       /tulip
       /rose
       /dandelion
    
  3. Open {model name}_model.py, you can choose the base model as you like, and edit the CNN part.
  4. run edited python file in terminal. After the training process, it should appear weight and json file named according to the base model.
  5. Move them into the weight and json folder .

Contact me

if you have any question, email me for fast response.

email : fahrudinhasby12@gmail.com

facebook : https://www.facebook.com/hasby.fahrudin