Git Product home page Git Product logo

cannabisdisease's Introduction

Plant disease

Adapted from https://github.com/ClaudeCoulombe/deep-learning-with-python-notebooks/blob/master/5.3-using-a-pretrained-convnet.ipynb

data

The data was generated by crawling google and reddit. It was manually curated after reading about canabis diseases by a nonexpert. Please consult a professional if your marijuana is sick.

One source identifies 30 types of cannabis ailments:

  1. boron deficiency
  2. broad mites
  3. bud rot
  4. calcium deficiency
  5. copper deficiency
  6. fungus gnats
  7. heat light stress
  8. iron deficiency
  9. yellow leaf spot leaf septoria
  10. light burn
  11. magnesium deficiency
  12. male plants bananas hermies
  13. manganese deficiency
  14. molybdenum deficiency
  15. nitrogen deficiency
  16. nitrogen toxicity
  17. nutrient burn
  18. overwatering
  19. bugs pests symptoms marijuana grow
  20. ph fluctuations
  21. phosphorus deficiency
  22. potassium deficiency
  23. root problems
  24. root rot
  25. spider mites
  26. sulfur deficiency
  27. underwatering
  28. white powdery mildew
  29. wind burn
  30. zinc deficiency

resources:

the "other" dataset was generated from:

Data distribution

healthy 1120 sick 946 not_weed 964

train/validation/test 60/20/20

Notes

  • data augmentation make validation accuracy worse on first attempt. Must mean the transformations are not representative of valid data for our problem.
    • find transformations that produce valid data for our problem
  • resnet50 may overfit on datasets < 10K images
    • try VGG16
  • visualize misclassified samples to gain intuition about where the model is struggling
  • curate more data
  • consider dropping photos of groups of plants

gcloud notes

  • see projects gcloud projects list
  • see current project gcloud config list project
  • change project gcloud config set project <project name>
  • set bucket name BUCKET_NAME="keras-class-191806"
  • set your preferred region REGION=us-east1
  • copy model over gsutil cp src gs://$BUCKET_NAME/saved_model.pg NOTE: ml-engine expects your model's protocol buffer file to be name saved_model.{pb,pbtxt}
  • register ml-engine entry gcloud ml-engine models create <model name>
  • deploy version of model gcloud ml-engine versions create v4 --model=plantDisease01 --origin=gs://keras-class-191806/plantDisease01/vgg16_data_augmented-tf --runtime-version=1.4 the origin arg must be a local dir with the full tf model (protocol buffer and variables)
  • see models gcloud ml-engine models list
  • craft request payload python -c 'import base64, sys, json; img = base64.b64encode(open(sys.argv[1], "rb").read()).decode(); print(json.dumps({"foo-input": {"b64": img}}))' test_healthy.jpg &> request.json
  • craft request python -c 'req = []; [req.append(0.2) for i in range(224*224)]; print(req)' &> request-float32.json
  • inference gcloud ml-engine predict --model=plantDisease01 --json-instances=request.json

cannabisdisease's People

Contributors

morenoh149 avatar tharathep22 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.