Git Product home page Git Product logo

compostnet's Introduction

compostnet

Sarah Frost, Bryan Tor, Rakshit Agrawal, Angus G. Forbes

Link to our paper

Overview of Project:

WasteBins

It can be confusing to know what pieces of waste go in which bin. Many businesses, cafes, and outdoor spaces provide trash, recycling, and composting bins, requiring consumers to decipher instructional text, icons, or images in order to sort their waste accurately. Moreover, different locations may have different rules for how to separate waste, and often people inadvertently throw their trash in the wrong bin. Machine learning solutions can help us more quickly and accurately choose the proper receptacle for our waste by classifying a photograph of the waste. Building on recent work in deep learning and waste classification, we introduce CompostNet, a convolutional neural network that classifies images according to how they should be appropriately discarded. We provide details about the design and development of CompostNet, along with an evaluation of its effectiveness in classifying images of waste. Further, we discuss two different approaches to the design of our system, one using a custom network and the other augmenting a pre-trained image classification network (MobileNet) through transfer learning, and finding greater success with the transfer learning approach. To the best of our knowledge, CompostNet is the first waste classification system that uses a deep learning network to identify compostable, recyclable, and landfill materials. CompostNet is an application of machine learning for social good, and supports United Nations Sustainable Development Goal 12: Responsible Consumption and Production.

Installation

Dataset: We took the dataset built by Gary Thung and Mindy Yang for TrashNet and added a compost class.

We added 175 photos to the compost class, and added 49 photos to the trash class. We followed the data collecting methods outlined in Trashnet. We resized our images to 400ร—300 pixels. In the code for our Version A model, we resize the images to 224 ร— 224 pixels.

Our dataset was too large to upload to github, all data can be found on Google Drive.

Our Dataset for Version A

Our Dataset for Version B

Code:

Version A:

You will need:

Python 3.5

Tensorflow

pip install --upgrade "tensorflow==1.7.*"

Folders: scripts, tf_file (on google drive)

Dowload these folders and move them into the same directory

To retrain, change the image_dir path to the path with the training data in commands.txt to test run the second set of code with an image path from the testing data in commands.txt

Version B we built and ran our code in Google Colab, which can be found in this repo. You can access the notebook with Google Colab or the Jupyter notebook environment.

Architecture

Version A Architecture

VersionA Architecture

Version B Architecture

VersionB Architecture

Results

Version A Accuracy and Results

VersionA Accuracy Results More Results

Version B Accuracy

VersionBAccuracy

Deployment

We are in the process of building a mobile app for deploying this solution.

Credits

TrashNet - Gary Thung and Mindy Yang

compostnet's People

Contributors

bterrific2008 avatar sarahmfrost avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.