项目作者: dmis-lab

项目描述 :
KitcheNette: Predicting and Recommending Food Ingredient Pairings using Siamese Neural Networks
高级语言: Python
项目地址: git://github.com/dmis-lab/KitcheNette.git
创建时间: 2019-05-15T03:46:48Z
项目社区:https://github.com/dmis-lab/KitcheNette

开源协议:Apache License 2.0

下载


KitcheNette: Predicting and Ranking Food Ingredient Pairings using Siamese Neural Networks

This repository provides a Pytorch implementation of KitcheNette, Siamese neural networks and is trained on our annotated dataset containing 300K scores of pairings generated from numerous ingredients in food recipes. KitcheNette is able to predict and recommend complementary and novel food ingredients pairings at the same time.

KitcheNette: Predicting and Ranking Food Ingredient Pairings using Siamese Neural Networks

Donghyeon Park\, Keonwoo Kim, Yonggyu Park, Jungwoon Shin and Jaewoo Kang
Accepted and to be appear in IJCAI-2019

Our paper is available at:
https://www.ijcai.org/proceedings/2019/822*


You can try our demo version of KitchenNette:

http://kitchenette.korea.ac.kr/

For more details to find out what we do, please visit https://dmis.korea.ac.kr/

Pipeline & Abstract

figure


The Concept of KitcheNette (Left) & KitcheNette Model Architecture (Right)

Abstract

As a vast number of ingredients exist in the culinary world, there are countless food ingredient pairings, but only a small number of pairings have been adopted by chefs and studied by food researchers. In this work, we propose KitcheNette which is a model that predicts food ingredient pairing scores and recommends optimal ingredient pairings. KitcheNette employs Siamese neural networks and is trained on our annotated dataset containing 300K scores of pairings generated from numerous ingredients in food recipes. As the results demonstrate, our model not only outperforms other baseline models but also can recommend complementary food pairings and discover novel ingredient pairings.

Prerequisites & Development Environment

  • Python 3.6
  • PyTorch 0.4.0
  • Numpy (>=1.12)
  • Maybe there are more. If you get an error, please try pip install "pacakge_name".

  • CUDA 9.0

  • Tested on NVIDIA GeForce Titan X Pascal 12GB

Dataset

  • kitchenette_pairing_scores.csv (78MB)

    You can download and see our 300k food ingredient pairing scores defined on NPMI.

  • [For Training] kitchenette_dataset.pkl (49MB)

    For your own training, download our pre-processed dataset and place it in data folder.

    This pre-processed dataset 1) contains all the input embeddings, 2) is split into train[8]:valid[1]:test[2], and 3) and each split is divided into mini-batches for efficent training.

Training & Test

  1. python3 main.py --data-path './data/kitchenette_dataset.pkl'

Prediction for Unknown Pairings

You need the following three files to predict unknown pairings

  • kitchenette_pretrained.mdl (79MB)

    Download our pre-trained model for prediction of unknown pairings and place it in results folder.

    or you can predict the pairing with your own model by substituting the model file.

  • kitchenette_unknown_pairings.csv (308KB)

    Download the sample unknown pairings and place it in data folder.

    This files contains approximately 5,000 pairings that have no scores because that they are ralely or never used togeter. You can edit this file to score any pair of two ingredeints that you would like to find out.

  • kitchenette_embeddings.pkl (8MB)

    Download the sample ingredient embeddings for exisiting ingredients and place it in data folder.

    For this version, unfortunately, our model only scores the ingredients with pre-traiend embeddings.

  1. python3 main.py --save-prediction-unknowns True \
  2. --model-name 'kitchenette_pretrained.mdl' \
  3. --unknown-path './data/kitchenette_unknown_pairings.csv' \
  4. --embed-path './data/kitchenette_embeddings.pkl' \
  5. --data-path './data/kitchenette_dataset.pkl'

Contributors

Donghyeon Park, Keonwoo Kim

DMIS Labatory, Korea University, Seoul, South Korea

Please, report bugs and missing info to Donghyeon parkdh (at) korea.ac.kr.

Citation

  1. @article{park2019kitchenette,
  2. title={KitcheNette: Predicting and Ranking Food Ingredient Pairings using Siamese Neural Networks},
  3. author={Park, Donghyeon and Kim, Keonwoo and Park, Yonggyu and Shin, Jungwoon and Kang, Jaewoo},
  4. journal={Proceedings of the Twenty-Eighth International Joint Conference on Artificial Intelligence},
  5. year={2019}
  6. }

Liscense

Apache License 2.0