Package: dietkit
DietkitDietkit is a library that provides tools for managing and analyzing diets.Class StructureThis library includes three classes to represent diet: Ingredient, Menu and Diet.Ingredient class stands for grocery ingredients. Each Ingredient instance includes nutrition information.Menu class stands for dishes served in diet. Each Menu instance contains its own ingredients.Diet class stands for diet plan. It is not single diet, but bundle of several diets. It is consist with pair of identifier and contents of diet.Also, Dietkit contains class 'Criteria' which stands for nutrition criteria. It is used as input to the evaluation method to evaluate nutrition of the menu or diet.FunctionsDietkit's function is divided into three main functions: Loader, Evaluator and Visualizer.Loader functions load ingredient, menu or diet data. If the specific file path is not passed, it automatically loads the our sample data.Evaluator functions evaluate the menu or diet in terms of ingredients and nutrition based on user's criteria.
Visualizer functions graphically visualize the diet's information or evaluation results.Dependencispandas (>=3.7)matplotlib (>= 3.0.0)seaborn (>= 0.11.0)InstallationYou can install this package bypip install dietkitTipIffrom dietkit import *is input, dietkit will import all of its functions and classes. It can take quite a long time (About 3 minutes). So, it is recommended to import only the functions to be used.About sample dataThe sample ingredient data were extracted from the 9th revision of the National Standard Food Components provided by Rural Development Administration of Korean government.The sample menu data is collected from Center for Children's food service management under the Ministry of Food and Drug safety of the Korean government.The sample diet data is work of our research.You can find detailed information about sample data in the study: 'Creating the K–MIND dataset for dietplanning and healthcare research: Byintegrating the capabilities of combinatorialoptimization, experts, and controllablegeneration'.Related documentsThis package is subject results of the research: [link TBD]
You can check detail information about this package and its sample data in supplementary material of above research: [link TBD]LicenseThe source code for Dietkit is subject to the LGPL license.However, the sample data following another license.License about sample dataLicense for sample inigredient dataSubject files'sample_ingredients_eng.csv', 'sample_ingredients_kor.csv'InformationThe ingredient data is distributed under the Korea Open Government License Type 1. In this license, user can use the data freely and without fee regardless of its commercial use, and can change or modify the data to create secondary works. However, the Rural Development Administration of Korean government, which is source of data, must be indicated.License for sample menu dataSubject files'sample_menus_eng.csv', 'sample_menus_kor.csv'InformationThe menu data is permitted to be used under the following conditions: The Center for Children’s Food Service Management in South Korea should be indicated as the author. Redistribution of the menu data and its derivative works are allowed. It should be used only for non-commerical purposes.License for sample diet dataSubject files'sample_diet_expert_eng.csv', 'sample_diet_expert_kor.csv', 'sample_diet_ml_eng.csv', 'sample_diet_ml_kor.csv', 'sample_diet_or_eng.csv', 'sample_diet_or_kor.csv'InformationThe 'CC BY-NC 4.0' license is applied to the diet data. When using diet data, the authors of this paper should be indicated as the attribution parties. Redistribution of diet data and its derivative works are allowed. Data should be used only for non-commercial purposes.