Giter VIP home page Giter VIP logo

plants's Introduction

Running

Everything you need to evaluate is ready. For Apple Silicon: pip install torch --pre

Install requirements: pip install -r requirements.txt web.py

Select an image from the plant_images/train or plant_images/test to evaluate. The defualt location is http://127.0.0.1:8080

Training

Requirements:

Python 3.10.12
Bing API key for image search

For Apple Silicon: pip install torch --pre

Install requirements: pip install -r requirements.txt

First get images from the Wikipedia page of your choice. Make sure to add the Bing API Key to the file: get_images.py

To update failing URLs: update_pending.py

To find non-JPEG files: ./verify.sh | grep 'Non-JPEG'

To convert images that can be converted to JPEG: ./convert.sh

(optional) If the testing set is small, use the move_files.sh script to move 20% of files: ./move_files plant_images/train plant_images/test

Train your model using the ResNet18 as the base (trains to 30 epochs): train.py

Example Output for 10 epochs:

Epoch 1/10 Loss: 3.4192 Acc: 0.0681
Epoch 2/10 Loss: 2.7664 Acc: 0.2893
Epoch 3/10 Loss: 2.2519 Acc: 0.4182
Epoch 4/10 Loss: 1.8852 Acc: 0.4990
Epoch 5/10 Loss: 1.6163 Acc: 0.5996
Epoch 6/10 Loss: 1.4078 Acc: 0.6488
Epoch 7/10 Loss: 1.2197 Acc: 0.6918
Epoch 8/10 Loss: 1.0836 Acc: 0.7107
Epoch 9/10 Loss: 0.9640 Acc: 0.7348
Epoch 10/10 Loss: 0.8566 Acc: 0.7579
Test Accuracy: 0.2444

Metadata and state data is saved and can be used between code and processor types.

Run the webserver and try uploading an images: web.py

plants's People

Contributors

mkommar avatar

Watchers

 avatar Kostas Georgiou 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.