Program predicting the cuisine of the recipe given the ingredients list.
Run the cuisine_classification.py
script with options:
option | long option | argument | description |
---|---|---|---|
-p | --predict | [FILE] | predicts a cuisine given the json file consisting of list of dictionaries containing key: "ingredients" - list of ingredients "id" - recipe id the result is written into the file specified by -out-file and is in .csv format |
-h | --help | shows this message | |
-t | --train | [FILE] | trains the neural network with the new data [FILE] format should be .json list of dictionaries containing keys: "cuisine" - string "ingredients" - list of ingredients default file path is ./input/train.json |
-e | --epochs | [NUM] | changes the number of epochs executed during training default is 10 |
-c | --cuisines | shows list of cuisines that the program is able to identify | |
-o | --out-file | [FILE] | specifies the out file name for predictions |
- Sample train file: input/train.json
- Sample prediction file: input/test.json
Current accuracy is ~77% but can go up to ~96% with more train time.