Skip to content

FoodSnap AI#8

Open
Adeelp1 wants to merge 12 commits intoWeCode-Community-Dev:mainfrom
Adeelp1:feature/adeelp1
Open

FoodSnap AI#8
Adeelp1 wants to merge 12 commits intoWeCode-Community-Dev:mainfrom
Adeelp1:feature/adeelp1

Conversation

@Adeelp1
Copy link

@Adeelp1 Adeelp1 commented Jul 2, 2025

🍱 Food Classification & Nutrition Prediction

A deep learning model that classifies food from images using EfficientNetB0 and returns nutritional facts using a SQLite3 database.

🚀 Features

  • Image classification with EfficientNetB0 pretrained on ImageNet

  • Transfer learning with fine-tuning for improved accuracy

  • Nutrition info retrieval from a SQLite3 database

  • Exported model in both .keras and .tflite formats

🖼️ Dataset

  • 12 custom food categories

  • 1200+ images

🧠 Model Architecture

  • Base model: EfficientNetB0 (ImageNet weights)

  • Layers: Base model, GlobalAveragePooling, Dense, Softmax

  • Loss: sparse_categorical_crossentropy

  • Optimizer: Adam

🧪 Results

  • Training Accuracy: ~97%

  • Validation Accuracy: ~98%

💾 Model Export

  • .tflite

🛠️ Tools & Frameworks

  • Python | TensorFlow | Keras | EfficientNet | SQLite3 | Google Colab | NumPy

📦 Nutrition Database (Example)

Food Calories Protein Fat
Apple 52 0.3g 0.2g
Samosa 262 4g 17g
Banana 96 1.3g 0.3g

Set Up and Run Locally

Clone repository

git clone https://github.com/Adeelp1/foodsnap-ai.git
cd foodsnap-ai

Checkout branch

git checkout feature/adeelp1

Install dependencies:

pip install -r requirements.txt

Make sure you have all dependencies installed, then run the program using:

python main.py path/to/your/image.jpg

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant