Giter VIP home page Giter VIP logo

humanbinaryclassificationsuite's Introduction

Human Binary Classification Suite

Hello! Thank you for visiting this repo!

This repo contains almost everything you need in getting started for Human Binary classification

Table of Contents

Dependencies

These are packages that is tested in my system to run the suite:

  • Python 3.6.9
  • OpenCV 3.4.7
  • Numpy 1.17.2
  • Matplotlib 3.1.1
  • Tensorflow 1.10.0
  • h5py 2.10.0
  • scipy 1.3.1
  • scikit-learn 0.21.3
  • pydot 1.4.1
  • graphviz 2.40.1

For more information of installed packages in my system, refer to the packages.txt

Dataset Creation

dataset_generator folder contains basic tool for creating the dataset.

The dataset is a binary class data, consisting of human region-of-interest images and non-human images. The images varies in size, with smallest being 25 X 25 px.

The ROI images are retrieved from a foreground mask by using contour detection to make a bounding rectangle for cropping the original frame. The foreground mask is made by using background subtraction technique using Mixture of Gaussian (MOS)

Please refer to the included _INSTRUCTIONS.txt for steps & information.

Premade Dataset

dataset folder contains two subfolders representing two classes: human and nonhuman. There are 1229 human ROI images and 7126 nonhuman ROI images, retrieved from VIRAT 2.0 dataset using the dataset generator in this repo.

Huge thanks to Afriezal Lienardi and Vincenza Steven Ber for creating and doing manual labeling of the dataset!

Model Training & Visualization

In the root of the directory, there are three python files, run them in order:

  • dataset_pickler.py : Packs the dataset images in the dataset directory into separate training data and test data and saves it as a pickle file (train_data.pkl & test_data.pkl) for convenience.
  • model_maker.py : Makes pretrained model using Tensorflow and Keras. It saves the model(s) as .h5 file with an image of its architecture and loss & acc graph in a folder named from datetime in the models directory. Feel free to experiment with this file!
  • model_loader.py : Loads pretrained .h5 model for evaluation and visualization.

Pretrained Models

models directory contains several pretrained models, some are included with test data. You can use these pretrained model for anything you like! Make sure to read the architecture.

Detection Engine

Detection_Engine folder contains ready-to-use suite of files, models, and sample videos for human detection systems.

Run demo.py or HumanDetectionVisualization.py for demonstration, or see each source code for more in-depth analysis.

Featuring HumanDetector.py used in the TREYESpassing project. TREYESpassing is an app that alerts it's user when someone entered an area that is owned by the user and access to the area is prohibited for everyone.

humanbinaryclassificationsuite's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  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.