Skip to content

omrirh/genie.io

Repository files navigation

genie.io

genie image

Local Development

Pre-requisites:

  • Set KAGGLE_USERNAME and KAGGLE_KEY environment variables with your Kaggle credentials
  • Set FOOD_API_ID, FOOD_API_SECRET, RECIPES_API_ID and RECIPES_API_SECRET environment variables with your Edamam API credentials
  • Download food-101 images datasets from kaggle using mount_food_101.py script

Get started with genie running following commands:

  • Create a virtualenv:
python -m venv venv && source venv/bin/activate
  • install requirements:
pip install -r requirements.txt

Note: app requires python version>=3.11 (according to vermin)

  • run genie in CLI mode:
python genie_driver.py --cli-mode
  • run genie in API mode:
python genie_driver.py --api-mode
  • train a new genie CNN model with specific number of food types (default=101):
python genie_driver.py --new-genie --num-types=<number of supported food types>
  • train a new genie CNN model with GPU adaptation:
python genie_driver.py --new-genie --gpu

Container Image

Build and run application docker image

  • Create secrets.env file with Kaggle and Edamam API credentials
  • Build a new image tag locally:
docker build -t genie-io:<image_tag> .
  • Run app in a container (API mode by default):
docker run -it -p 5000:5000  genie-io:<image_tag>

About

Python application that includes CNN learning of food images and providing recipe data for a given input food image using Edamam API integration

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors