Giter Site home page Giter Site logo

andy-zzf / piepredict Goto Github PK

View Code? Open in Web Editor NEW

This project forked from aras62/piepredict

0.0 0.0 0.0 81.33 MB

PIE: A Large-Scale Dataset and Models for Pedestrian Intention Estimation and Trajectory Prediction

License: Apache License 2.0

Python 100.00%

piepredict's Introduction

Pedestrian intention and trajectory estimation

pie_predict

This repository contains Python code and pretrained models for pedestrian intention and trajectory estimation presented in our paper A. Rasouli, I. Kotseruba, T. Kunic, and J. Tsotsos, "PIE: A Large-Scale Dataset and Models for Pedestrian Intention Estimation and Trajectory Prediction", ICCV 2019.

Table of contents

Dependencies

The interface is written and tested on Ubuntu 16.04 with Python 3.5, CUDA 9 and cuDNN 7. The interface also requires the following external libraries:

  • tensorflow (tested with 1.9 and 1.14)
  • keras (tested with 2.1 and 2.2)
  • scikit-learn
  • numpy
  • pillow

To install via virtual environment (recommended) follow these steps:

  • Install virtual environment sudo apt-get install virtualenv.

  • Create a virtual environment with Python3:

> virtualenv --system-site-packages -p python3 ./venv
> source venv/bin/activate
  • Install dependencies: pip3 install -r requirements.txt

PIE Dataset

The code is trained and tested with Pedestrian Intention Estimation (PIE) dataset.

Download annotations and video clips from the PIE webpage and place them in the PIE_dataset directory. The folder structure should look like this:

PIE_dataset
    annotations
        set01
        set02
        ...
    PIE_clips
        set01
        set02
        ...

Videos will be automatically split into individual frames for training. This will require 1.1T of free space on the hard drive.

Create environment variables for PIE data root and add them to your .bashrc:

export PIE_PATH=/path/to/PIE/data/root
export PIE_RAW_PATH=/path/to/PIE/data/PIE_clips/

Download PIE data interface pie_data.py from PIE github.

Train

To train all models from scratch and evaluate them on the test data use this command:

python train_test.py 1

This will train intention, speed and trajectory models separately and evaluate them on the test data.

_Note: training intention model uses image data and requires 32GB RAM.

Due to the random initialization of the networks and minor changes to the annotations there might be slight variation in the results.

Test

To reproduce the results of our best model which combines pedestrian intention and vehicle speed for pedestrian trajectory prediction run this command:

python train_test.py 2

Citation

If you use our dataset and/or models, please cite:

@inproceedings{rasouli2017they,
  title={PIE: A Large-Scale Dataset and Models for Pedestrian Intention Estimation and Trajectory Prediction},
  author={Rasouli, Amir and Kotseruba, Iuliia and Kunic, Toni and Tsotsos, John K},
  booktitle={ICCV},
  year={2019}
}

Corresponding authors

Should you have any questions about downloading and using the data or the models, please feel free to raise an issue or send an email to [email protected] or [email protected].

License

This project is licensed under the Apache 2.0 License - see the LICENSE file for details

piepredict's People

Contributors

aras62 avatar yizhoufan avatar ykotseruba 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.