GithubHelp home page GithubHelp logo

backend-bytes127 / mlai-community-labs Goto Github PK

View Code? Open in Web Editor NEW

This project forked from initmahesh/mlai-community-labs

0.0 0.0 0.0 1.32 MB

License: Creative Commons Zero v1.0 Universal

Python 40.95% Jupyter Notebook 59.05%

mlai-community-labs's Introduction

MLAI-community-labs

Labs that explain complex ML/AI ideas simply with code.

Training a ML box detector

Using Azure custom vision and cognitive service, we are training a model to detect boxes, once a box is detected it will notify the user along with an image showing where the box is.

Requirements

In a Nutshell

  • Install all the required modules from requirements.txt pip install -r requirements.txt
  • Add all the following required variables in a .env file
CONNECTION_STRING = Storage connection string from Azure storage
SOURCE = 'usb' or path to any .mp4 file
TIME_DELAY = Specifies frame capture interval in seconds
MANUAL_MODE = Set 0 for auto and 1 for manual mode
PREDICTION_KEY = Azure cognitive service key
TRAINING_KEY = Azure cognitive service key here as well
PROJECT_ID = Custom vision project id
TWILIO_ACCOUNT_SID = Account SID from twilio
TWILIO_AUTH_TOKEN = Auth Toekn from twilio
TWILIO_PHONE_NUMBER = Twilio phone number
ACCOUNT_NAME = Azure account name
BLOB_ACCOUNT_KEY = Storage account key
ENDPOINT_CUSTOM_VISION = Azure custom vision endpoint
SERPAPI_API_KEY = Serpapi API key for scraping tool.
  • The source can be direct video stream from a camera(USB), or from a .mp4 file.
  • Time delay sets the time threshold to capture frames from the video.
  • You can choose from two modes, manual(1) or auto(0).
  • Finally, py edge_to_blob.py

Using the scraper

If you wish to train the model with your own data you can use the provided scraper which uses a third party service Serpapi to download HD images from the inrernet. Refer this readme to know how to set up and run the provided scraper. serpapi readme link here

Training your own ML model

You can also train the Model using Azure custom vision and cognitive service. Follow these steps to train the ML model.

Follow this how to guide here:

Quick tutorial

box_detector.mp4

mlai-community-labs's People

Contributors

mayank-dev1822 avatar initmahesh 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.