An open API service indexing awesome lists of open source software.

https://github.com/0xdeval/greenintervalpredicting

Current repository represents method for calculating optimal duration of green interval for certain number of pedestrians
https://github.com/0xdeval/greenintervalpredicting

Last synced: about 1 year ago
JSON representation

Current repository represents method for calculating optimal duration of green interval for certain number of pedestrians

Awesome Lists containing this project

README

          

# GreenIntervalPredicting
Current repository represents method for calculating optimal duration of green interval based on object detection of crossing road pedestrians

# Structure

1. Notebooks - there are 3 notebooks, which consist all necessary code for:
a. Preprocessing images and data (DataProcessing.ipynb)
b. Formula and it description for calculating optimal green interval (GreenIntervalCalculation.ipynb)
c. Full pipeline with object detection of pedestrians and calculating optimal green interval (GreenIntervalCalculationFullPipeline.ipynb)
2. ObjectDetectionResults - some results of working object detection algorithm for detecting: Pedestrians, Non-Pedestrians and Road
3. Metrics - current folder consist all metrics and graphs, which depict how does object detection algorithm work
4. Data - current folder consist full, train annotation and label map of object detection algorithm

# Dependencies

1. Tensorflow Object Detection API (https://github.com/tensorflow/models/tree/master/research/object_detection). Full process of setting up you can find in GreenIntervalCalculationFullPipeline.ipynb notebook
2. Tensorflow < 2 version

# Run GUI Interface

There are scripts for GUI interface, which was designed for demonstrating curretn pipeline for predicting optimal green interval for pedestrians. For running current applications use the following instruction:
1. Clone current repository
2. Be sure that you have [Inference folder](https://drive.google.com/drive/folders/19McKlvEA2NohkTKk9AGlfo9MX2TWyYWT?usp=sharing), where does model weigths store
3. Run gui_interface.py in Script folder
4. Install dependencies (when you will click the button "Install dependencies", application will stop)
5. Test application!

# Train on your own data

If you want to train on your own data:
- Fill Train and Test folders on Data
- Create your own annotation files
All process of training and creating annotatio files you can find in GreenIntervalCalculationFullPipeline.ipynb notebook

# Model

Inference graph you can find [here](https://drive.google.com/drive/folders/19McKlvEA2NohkTKk9AGlfo9MX2TWyYWT?usp=sharing).
How to test current inference graph you can find in GreenIntervalCalculationFullPipeline.ipynb notebook

## Metrics

### PEDESTRIANS

![Preceision-Recall Curve For Pedestrian class](https://github.com/maikReal/GreenIntervalPredicting/blob/master/Metrics/Pedestrian.png)

Average mAp = 99.11%

### NON-PEDESTRIANS

![Preceision-Recall Curve For Non-Pedestrian class](https://github.com/maikReal/GreenIntervalPredicting/blob/master/Metrics/Non-Pedestrian.png)

Average mAp = 83.27%

### ROAD

![Preceision-Recall Curve For Road class](https://github.com/maikReal/GreenIntervalPredicting/blob/master/Metrics/Road.png)

Average mAp = 95.44%

# TODO

1. Web app for demo and testing
2. Dockerfile for this web app