Sandwhich is a mobile app built to solve the sandwich debate by determining if the picture you've taken is a sandwich using machine learning

Overview

Sandwhich

sandwhich-icon
Website | Twitter

Sandwhich is a mobile app built to solve the sandwich debate by determining if the picture you've taken is a sandwich using machine learning, Flutter, and TensorFlow Lite.

Available on Google Play and the App Store

Screenshots

Built With

Getting Started

Building from Source

Clone the repository

git clone https://github.com/MotionMobs/Sandwhich
cd Sandwhich

Run Sandwhich

flutter run

Train Your Model/ How To πŸš‹ Your πŸ₯ͺ

To train your πŸ₯ͺ , you need to install Docker and ImageMagick.

brew update && brew install imagemagick

Set up file structure for your images

training_images
β”‚   β”œβ”€β”€ input
β”‚   β”‚   β”œβ”€β”€ not-sandwich
β”‚   β”‚   β”‚   β”œβ”€β”€ processed  # processed not-sandwich images
β”‚   β”‚   β”‚   └── unprocessed  # original, not yet processed not-sandwich images
β”‚   β”‚   β”œβ”€β”€ sandwich
β”‚   β”‚   β”‚   β”œβ”€β”€ processed  # processed sandwich imagess
β”‚   β”‚   β”‚   └── unprocessed  # original, not yet processed sandwich images
β”‚   β”œβ”€β”€ output  # ready for model
β”‚   β”‚   β”œβ”€β”€ not-sandwich  # minimum 20 images to train
β”‚   β”‚   └── sandwich  # minimum 20 images to train
└──

Once original images are loaded into the folders, as described above, process the images

cd training_images
./conversion.sh

After all images have been processed we need to build the Docker image, run the script to retrain the model, and run the script to convert the retrained model to a .tflite model we can use in the app.

Go back to the root of the project and run:

cd -
./train.sh

Prepare to wait a while.

Testing

To test the new model, run ./test_model.sh $IMAGE_PATH where $IMAGE_PATH is any path to an image you want to test with. For convenience, you can even drag an image into the terminal to have its path placed at the end of whatever is currently in the terminal.

  • When ready to use the new model, move it to the assets folder and overwrite the old model. Backup old model if desired.
  • Run the app, find some sandwiches, and enjoy!

To release on Android:

flutter build apk --target-platform android-arm64

Team

MotionMobs Website

Credits

Sandwhich icon was created by Chad Remsing from the Noun Project

You might also like...
Weather Forecast Assigment is an iOS application built to highlight MVP and Clean Architecture concepts

Weather Forecast Assigment - iOS - MVP + Clean Architecture Description Weather Forecast Assigment is an iOS application built to highlight MVP (Model

An instagram clone for iOS built with Parse
An instagram clone for iOS built with Parse

Parstagram - Part II This is an Instagram clone with a custom Parse backend that allows a user to post photos, view a global photos feed, and add comm

This project is built to show how to support accessibility features in iOS applications in UIKit.
This project is built to show how to support accessibility features in iOS applications in UIKit.

ACCESSIBILITY EXAMPLE This project is built to show how to support accessibility features in iOS applications in a blog post. For the sake of Accessib

Sample app to demonstrate using Firebase features

Photoram Sample app to demonstrate using Firebase features Uses: Firebase authentification for login and registrations Firebase storage to keep image

An example app with using ShazamKit
An example app with using ShazamKit

ShazamKitExample An example app with using ShazamKit. Check out a live demo on Twitter. Related Resources Introducing ShazamKit WWDC21 β€” Explore Shaza

iOS App that browse the people from Star Wars Universe using GraphQL Api.
iOS App that browse the people from Star Wars Universe using GraphQL Api.

Ravn-Challenge-V2--OscarCastillo- iOS App that browse the people from Star Wars Universe using GraphQL Api. This project uses Apollo swift Client. htt

The demo app demonstrates a real-time application using FindSurface to search point clouds, which ARKit provides, for geometry shapes.
The demo app demonstrates a real-time application using FindSurface to search point clouds, which ARKit provides, for geometry shapes.

FindSurface-GUIDemo-iOS (Swift) CurvSurf FindSurfaceβ„’ GUIDemo for iOS (Swift) Overview This demo app demonstrates a real-time application using FindSu

iOS app for keeping track of tasks using to-do lists
iOS app for keeping track of tasks using to-do lists

ToDo ToDo is a simple app that helps you keep track of tasks. Requirements iOS 15+ iPadOS 15+ License Distributed under the GPLv3 license. See LICENSE

A basic todo app using swift
A basic todo app using swift

Toodoo A basic todo app Features Basics Today List Categorize Prioritize Future Tasks Support Pictures Reorder Tasks Cross platform Quick Entry Analyz

Comments
  • iOS build fails

    iOS build fails

    Xcode's output: ↳ === BUILD TARGET share OF PROJECT Pods WITH CONFIGURATION Debug === /Users/djoker/flutter/.pub-cache/hosted/pub.dartlang.org/tflite-1.0.4/ios/Classes/T flitePlugin.mm:19:10: fatal error: 'tensorflow/lite/kernels/register.h' file not found #include "tensorflow/lite/kernels/register.h" ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 1 error generated.

    opened by anoop-b 1
  • Optimized images

    Optimized images

    Your image file size has been reduced by 5% πŸŽ‰

    Details

    | File | Before | After | Percent reduction | |:--|:--|:--|:--| | /android/app/src/main/res/drawable-xxhdpi/ic_launcher_foreground.png | 6.88kb | 4.56kb | 33.76% | | /android/app/src/main/res/drawable-xxxhdpi/ic_launcher_foreground.png | 9.34kb | 6.23kb | 33.22% | | /android/app/src/main/res/drawable-xhdpi/ic_launcher_foreground.png | 4.53kb | 3.04kb | 32.96% | | /assets/images/sandwhich-icon.png | 23.79kb | 15.97kb | 32.86% | | /android/app/src/main/res/drawable-hdpi/ic_launcher_foreground.png | 3.45kb | 2.35kb | 32.00% | | /android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png | 3.03kb | 2.06kb | 32.00% | | /android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png | 4.01kb | 2.77kb | 30.91% | | /android/app/src/main/res/drawable-mdpi/ic_launcher_foreground.png | 2.22kb | 1.57kb | 29.17% | | /media/icon.png | 9.75kb | 7.25kb | 25.72% | | /android/app/src/main/res/mipmap-xhdpi/ic_launcher.png | 1.94kb | 1.45kb | 25.24% | | /ios/Runner/Assets.xcassets/AppIcon.appiconset/sandwhich-icon_base.png | 35.63kb | 26.80kb | 24.77% | | /media/ss4.png | 103.57kb | 81.56kb | 21.26% | | /android/app/src/main/res/mipmap-hdpi/ic_launcher.png | 1.44kb | 1.14kb | 20.27% | | /assets/images/sandwhich.png | 29.58kb | 23.78kb | 19.60% | | /ios/Runner/Assets.xcassets/AppIcon.appiconset/sandwhich-icon_167.png | 7.70kb | 6.59kb | 14.35% | | /android/app/src/main/res/mipmap-xxxhdpi/icon.png | 8.77kb | 7.53kb | 14.12% | | /android/app/src/main/res/mipmap-xxhdpi/icon.png | 6.62kb | 5.71kb | 13.87% | | /ios/Runner/Assets.xcassets/AppIcon.appiconset/[email protected] | 6.96kb | 6.01kb | 13.63% | | /ios/Runner/Assets.xcassets/AppIcon.appiconset/[email protected] | 8.23kb | 7.13kb | 13.33% | | /assets/images/mm-logo.png | 20.83kb | 18.42kb | 11.61% | | /android/app/src/main/res/mipmap-xhdpi/icon.png | 4.43kb | 3.95kb | 10.91% | | /ios/Runner/Assets.xcassets/AppIcon.appiconset/[email protected] | 5.48kb | 4.89kb | 10.73% | | /ios/Runner/Assets.xcassets/AppIcon.appiconset/[email protected] | 5.48kb | 4.89kb | 10.73% | | /ios/Runner/Assets.xcassets/AppIcon.appiconset/[email protected] | 3.97kb | 3.56kb | 10.19% | | /ios/Runner/Assets.xcassets/AppIcon.appiconset/[email protected] | 3.67kb | 3.33kb | 9.21% | | /ios/Runner/Assets.xcassets/AppIcon.appiconset/[email protected] | 3.67kb | 3.33kb | 9.21% | | /ios/Runner/Assets.xcassets/AppIcon.appiconset/sandwhich-icon_76.png | 3.42kb | 3.15kb | 7.80% | | /android/app/src/main/res/mipmap-hdpi/icon.png | 3.31kb | 3.06kb | 7.67% | | /media/ss.png | 2,236.77kb | 2,099.02kb | 6.16% | | /ios/Runner/Assets.xcassets/AppIcon.appiconset/[email protected] | 2.71kb | 2.56kb | 5.62% | | /media/ss3.png | 2,275.82kb | 2,173.60kb | 4.49% | | /android/app/src/main/res/mipmap-mdpi/ic_launcher.png | 0.87kb | 0.83kb | 4.27% | | /ios/Runner/Assets.xcassets/AppIcon.appiconset/[email protected] | 2.66kb | 2.55kb | 4.15% | | /ios/Runner/Assets.xcassets/AppIcon.appiconset/[email protected] | 2.66kb | 2.55kb | 4.15% | | /android/app/src/main/res/mipmap-mdpi/icon.png | 2.16kb | 2.07kb | 3.93% | | /media/ss2.png | 2,728.27kb | 2,625.05kb | 3.78% | | /ios/Runner/Assets.xcassets/AppIcon.appiconset/[email protected] | 1.79kb | 1.77kb | 0.93% | | /ios/Runner/Assets.xcassets/AppIcon.appiconset/[email protected] | 1.79kb | 1.77kb | 0.93% | | /ios/Runner/Assets.xcassets/AppIcon.appiconset/[email protected] | 1.79kb | 1.77kb | 0.93% | | | | | | | Total : | 7,588.98kb | 7,175.63kb | 5.45% |

    opened by anoop-b 0
Owner
null
PostsExam - A Valhalla take home exam for Mobile App Developer

Posts - iOS A Valhalla take home exam for Mobile App Developer - iOS position Cr

Val Moratalla 0 Mar 24, 2022
A sample iOS app built using the Clean Swift architecture

Main Purpose is to create a simple project for Clean-Swift This project wrote with using Clean-Swift and MVP Design Pattern

Eyup Cimen 8 Oct 24, 2022
A social feed app built using Texture framework

A social feed screen created using Texture framework for UI purposes only.

Ammad Akhtar 3 Nov 17, 2021
Saturday is a mobile only, computer vision enabled smart personal accountant.

Saturday NUS Computing Orbital 2022 Saturday is a mobile only, computer vision enabled smart personal accountant. Motivation Through our personal expe

null 1 Jun 13, 2022
Instagram Clone Application Built Using Swift And Firebase

InstagramClone Bu instagram klon uygulamasında CoreLocation, Snapkit, Firebase, KingFisher, IQKeyboardManagerSwift kütüphaneleri kullanılmıştır. Kulla

Barış Can Akkaya 2 Oct 20, 2021
SwiftUI Project built using the fundamentals of SwiftUI that I have learned.

GhibliLog About: I wanted to test my ability to create an application with a responsive SwiftUI interface that would format and display data pulled fr

Daniel Whitehorn 0 Nov 9, 2021
Scrumdinger-ios - Built as a part of iOS app dev tutorials from app-dev-training

Scrumdinger This repository contains the code written during my course of taking

Ashwin Ramakrishnan 1 Jan 23, 2022
NasaAPOD App Built with swift

NasaAPOD Technical Description: App Runs on Swift 5 + iOS 15 (for testing only traget can be changed) App Folows MVVM+R pattern where R = router for n

Kalam 0 Dec 28, 2021
Dribbble app built with React Native

A Dribbble app build with React Native.

Catalin Miron 2k Dec 29, 2022
iPhone app built with React Native for viewing houses for sale in the Northwest

Den is an iPhone app built with React Native for viewing houses for sale in the NW from rmls.com. After being frustrated with a site that hasn't changed since 2004, I decided to build a better viewing experience in the phone.

Asa Miller 464 Aug 31, 2022