We wanted to create a health app that can benefit millions of people while being easy to use. We knew that entering the food in calorie apps always takes a really long time, so we wanted to make an easier way for people to keep track of their eating without having to manually enter everything.

What it does

The app allows a user to take a picture of their food. The app then uses the clarifai API to identify the food and uses the USDA api to identify the food's calorie count and food group, adding them to overall, weekly, and daily counts. These counts are displayed in clear, readable graphs for the user to observe their progression in calorie and food group consumption over time. User information of food consumption is stored in a MongoDB database on a Linode server. The app displays the last few meals that a person had along with the calorie counts and times they were eaten. The app also uses the EveryBlock API to suggest nearby events based on the user's calorie consumption. A user that seems to have eaten too much food is referred to nearby events that may involve exercise and movement. A user that seems to have eaten too little food is referred to nearby food events.

How we built it

We used the ionic framework that uses AngularJS, HTML5, and CSS to create a web-based iOS app. Our backend was written in Java and we had a MongoDB database on a Linode cloud server. The iOS front-end interacts with the Java backend which serves as a medium between the cloud server and the ionic-built frontend. After developing the backend and frontend to our satisfaction, we brought the two together, linking the frontend to the relevant parts of the backend.

Challenges we ran into

We had some trouble implementing the native camera app on iOS with the ionic framework with which we built the app. Also, none of us had experience with AngularJS and much of our time was spent getting used to AngularJS and the libraries that ionic implemented for the creation of our app. One major challenge was determining the best, most accurate way to identify the food in a picture and calculate the calories and food groups in the meal. We also spent some time getting accustomed with the various APIs that we chose to implement to make our app work.

Accomplishments that we're proud of

We were pleasantly surprised with how much we were able to accomplish on this app in the time that we had, considering that only one of our team has ever been to a hackathon before. The app contained all the features that we had envisioned, and we were even able to add more features than we had expected. The relative accuracy with which the app identifies foods is something we're also proud of.

What we learned

We learned ionic, AngularJS, proper usage of git, implementation of several APIs, and using a cloud server. We also learned how to effectively split the work between frontend and backend so that we would complete all of the major tasks in a timely fashion and have enough time to combine the two parts to complete the product.

What's next for Picknic

We would like to directly implement the native camera app, develop the application directly in iOS rather than ionic, and implement city healthy eating comparisons. If people in cities are able to compare how their city is doing in average calorie consumption compared to other cities, they may be more compelled to watch their diets. Improving image recognition accuracy is always something we can improve on.

Share this project: