Inspiration

This was inspired by something my AP Environmental Science teacher once said in class. He was talking about how convenient it would be to have the ability to scan any type of food and find the nutritional information one could find on a Nutrition Facts label. As I delved deeper into the topic, I couldn't help but notice the alarming prevalence of obesity in America. It's a significant public health concern that affects millions of people and has far-reaching consequences. That's what inspired me to create an app that could empower individuals to make healthier food choices by providing instant access to nutritional information, just like a Nutrition Facts label. By offering a convenient tool for people to make informed decisions about their diet, I hope to play a small part in combating obesity and promoting a healthier lifestyle for everyone.

What it does

NutriFood is a web application that gives nutritional information from just an image of food. This includes calories, total fat, saturated fat, sodium, sugar, and more. It is designed to help people diet by informing them of what’s in their food before they eat, just like a Nutrition Facts label.

How we built it

NutriFood is a web application built using Flask. It contains a trained TensorFlow model that identifies the food in the image uploaded. This model was trained locally on my computer using the FoodX-251 dataset, which is publicly available here. The Flask application then uses an api called CalorieNinjas to find the nutritional information for the food identified. It is built with user friendliness in mind, utilizing custom Bootstrap CSS to give a sleek and polished look.

Challenges we ran into

The lack of time and resources were major obstacles to overcome. The input images in the TensorFlow model had to be downscaled several times for it to train even remotely fast enough for the time constraints. These constraints also led to a lack of fine tuning, which resulted in relatively poor accuracy of the model. Additionally, the dataset only had 251 types of food, which is not holistic enough to be used by the general population.

Accomplishments that we're proud of

I’m personally proud of how fast I was able to create something functional. Working under the intense time constraints of the hackathon was a novel experience for me. Successfully completing my initial idea within that time frame was a notable achievement that filled me with satisfaction.

What we learned

I’m not extremely experienced with TensorFlow, so having the chance to learn transfer learning for training a model proved to be a valuable educational journey. I also learned to work under extreme time constraints, given the limited time frame of the competition. .

What's next for NutriFood

The next steps would be to use a larger dataset with more types of food, which would allow for more accurate identification. This would also mean having more time and more computing power to fine tune the model to be much more accurate. Eventually, I imagine NutriFood being integrated into a dieting app such as Apple or Samsung health, where users can simply scan the food they’re eating and it will automatically be tracked.

Built With

Share this project:

Updates