Our website can predict the level of ripeness of fruits and recommend that you should eat or not.
- Python 3
Clone this repository and go to the cloned folder.
git clone https://github.com/PyaeLinn01/fruit-freshness-detector.git
cd fruit-freshness-detectorCreate python virtual environment.
pip install virtualenv
virtualenv venvInitialize virtual environment
source venv/bin/activateor use this if you are using windows
.\venv\bin\activate
Install dependencies using pip.
pip install -r requirements.txtrun the app with Flask
flask runand lastly, open http://127.0.0.1:5000/ on your browser.
Return recognize result as JSON.
-
URL
/api/recognize
-
Method:
POST -
Content-Type
multipart/form-data -
Data Params
image=[file] -
Success Response:
- Code: 200
Content:{ freshness_level : 100, price : 10000 }
- Code: 200
python -m unittest discover tests