Code Monkey home page Code Monkey logo

000jd / flowerresnet Goto Github PK

View Code? Open in Web Editor NEW
0.0 2.0 1.0 165 MB

This GitHub project classifies flower images using a custom ResNet model implemented in PyTorch. The Flowers-299 dataset with 299 flower classes is utilized. It includes data preprocessing, training with SGD, validation, and model checkpointing for reusability. The project offers insights into image classification and serves as a valuable resource.

Python 0.90% Jupyter Notebook 99.07% CSS 0.03%

flowerresnet's Introduction

FlowerResNet

This GitHub project showcases the classification of flower images using a custom ResNet model implemented in PyTorch. The Flowers-299 dataset, consisting of 299 flower classes, is utilized for training and evaluation. The project covers various aspects including data preprocessing, model training with SGD optimizer, validation, and model checkpointing for reusability.

Features

  • Custom ResNet model for flower image classification
  • Data preprocessing with resizing, normalization, and augmentation
  • Training using Stochastic Gradient Descent (SGD) optimizer
  • Validation during training for monitoring model performance
  • Checkpointing to save and load model for future use

Demo

Live Demo
App Screenshot

Accuracy and Loss Graphs

Accuracy Screenshot

Loss Screenshot

Accuracy and Loss Graphs of quantized Mode

Accuracy Screenshot

Loss Screenshot

Usage

To run the Streamlit application download the model and put it in the base diractry and runthe command.

    Streamlit run 1_๐Ÿ”ฎ_Flower_Prediction.py

Usage

To use this project, follow these steps:

  1. Clone the repository and install the required dependencies.

        pip install -r requirements.txt
  2. Prepare the dataset:

    • Download the Flowers-299 dataset and place it in the data/flowers-299 directory.
    • Ensure the dataset is structured with separate folders for each class.
  3. Train the model:

    • Adjust the hyperparameters in the training script according to your requirements.
    • Start the training process.
        python train.py
  4. Evaluate the model:

    • Adjust the paths in the evaluation script to point to the trained model checkpoint and test dataset.
    • Run the evaluation script to assess the model's performance on the test dataset.
        python evaluate.py
  5. Use the model for predictions:

    • Adjust the paths in the prediction script to point to the trained model checkpoint and the image you want to classify.
    • Run the prediction script to make predictions using the trained model.
        python predict.py

Contributing

Contributions are welcome! Please open an issue or submit a pull request for any enhancements or bug fixes.

Acknowledgements

We would like to thank the creators of the Flowers-299 dataset for providing the valuable data for this project.

References

flowerresnet's People

Contributors

000jd avatar cion247 avatar

Watchers

Kostas Georgiou avatar  avatar

Forkers

cion247

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.