Code Monkey home page Code Monkey logo

speed-prediction's Introduction

Enhancement of Vehicle Speed Estimation Based on Optical Flow and Deep Learning Approaches

Abstract

In recent times, the subject of Intelligent vehicles has become very popular. The inspiration of this popularity cannot be discussed without mentioning computer vision and deep learning. This is because many vehicles, today, have all kinds of high-quality cameras installed on them to capture videos for different benefits. Object tracking and speed estimation are important tasks in video processing. Several methods for speed estimation have been proposed. This paper deals with speed estimation of a car from a video. We propose a method for estimating the speed of a car, with better accuracy, from a video captured by the car’s dashboard camera. The method uses two networks, one for estimating the displacement of the car, and the other for learning the speed labels. We perform experiments applying several image-processing techniques and using a lightweight and efficient optical flow estimation based deep learning approaches to achieve this goal. The proposed model is trained on the comma.ai speed challenge dataset and the results are evaluated and compared to other submissions on this challenge.

How to Setup And Test (Use) The Program

The entire process of running the program includes:

  1. Make sure the videos and the labels are in the “data/” folder.
  2. Make sure your PC/server meets the system setup requirements below:
  • CUDA enable GPU.
  • At least 8 Gigabytes of RAM size will not freeze the system.
  1. Make sure python3 and the required libraries which includes the following are installed: Pytorch (with cuda).
  • openCV
  • Numpy
  • Matplotlib.pyplot
  • keras
  • scikit-learn
  • flowiz
  • PIL.Image
  1. Run “python main.py” to convert videos (train.mp4 and test.mp4) to images and to optical flow.
  2. Run “python train_model.py” to train on training video data. May take at least 4 hours and at most 24 hours to train.
  3. Run “python test_model.py” to predict speed for the test.mp4 video. Note that you can ignore the steps 5 and 6, and run only this step for prediction using our already trained model. Thus, if you like to test our model only.
  4. After step f, the output is stored as in the root directory as a video named, “test_output.mp4”
Sample of our OutPut results

Video 1 Video 1 Video 1 Video 1

Paper link - Pending...

speed-prediction's People

Contributors

jizzel avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

Forkers

zphilip

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.