GithubHelp home page GithubHelp logo

wangtaoqd1987 / drone-dataset-tools Goto Github PK

View Code? Open in Web Editor NEW

This project forked from ika-rwth-aachen/drone-dataset-tools

0.0 0.0 0.0 728 KB

The goal of this repo is to make the drone datasets as easy to use as possible. For this purpose we provide source code in Python, which allows the import and visualization of the datasets.

License: Other

Python 100.00%

drone-dataset-tools's Introduction

Drone-Dataset Tools

The goal of this repository is to make using drone datasets as easy as possible. Therefore, we provide source code in Python for import and visualization. Thus, this source code not only allows to visualize trajectories and thus get an overview, but also serves as a template for your own projects.

Installation and Quick Start

  1. Create a new Python environment or select a pre-existing one. This code is tested with Python 3.6, but is very probably compatible with newer releases of Python.

    If you use Anaconda3, this can be done as follows:

    conda create --name drone-dataset-tools36 python=3.6
    conda activate drone-dataset-tools36
  2. Install required packages by navigating to the root directory and using

    pip3 install -r requirements.txt
  3. To run the visualization tool, first, navigate to the src/ directory

    cd src
  4. Then to visualize e.g. recording 26 from the exiD dataset, either copy the content of the dataset's data/ directory into the data/ subdirectory of this repository and use

    python3 run_track_visualization.py --dataset exid --recording 26

    or you can skip the data copying and directly provide the path to the dataset's data/ directory by using the --dataset_dir command line option:

    python3 run_track_visualization.py --dataset_dir /<path/to>/exiD-dataset-v1.2/data/ --dataset exid --recording 26

    See below for further explanations.

Importer

tracks_import.py

This module allows to import the tracks, tracks meta info and recording meta info for a single recording (read_from_csv(tracks_file, tracks_meta_file, recordings_meta_file)) or for all recordings (read_all_recordings_from_csv(base_path)).

Visualizer

The visualizer imports the data and visualizes them on an image of the recording site. The user may visualize specific frames or just playback the recorded tracks. In addition, information like the track id or speeds may be displayed (see "Command-line Options"). By clicking on track, a separate window is created with plots of the clicked track's positions, headings, velocities and accelerations.

Each road user class has its own color: cars are light blue, vans are purple, buses are orange, trucks are orange, pedestrians are red, bicycles are yellow and motorcycles are yellow.

The following shortcuts are currently implemented:

Keyboard Shortcut Description
space Play/Stop the playback
right arrow Jump to previous frame
left arrow Jump to next frame

"Screenshot of track visualization"

Command-line Options

The command-line options can be used when starting the run_track_visualization.py script. For example, run the following command from the src directory to start the visualization of recording 26.

python3 run_track_visualization.py --dataset exid --recording 26 

All available options are listed in the following table:

Command-line Options Default value Description
--help - Show this help message.
--dataset_dir "../data/" Path to directory that contains the dataset csv files.
--dataset exid Name of the dataset (ind, round, exid, unid). Needed to apply dataset specific visualization adjustments.
--recording 26 Name of the recording given by a number with a leading zero.
--playback_speed 4 During playback, only consider every nth frame.
--show_bounding_box False Plot the rotated bounding boxes of all vehicles. Please note, that for vulnerable road users, no bounding box is given.
--show_orientation False Indicate the orientation of all vehicles by triangles.
--show_trajectory False Show the trajectory up to the current frame for every track.
--show_future_trajectory False Show the remaining trajectory for every track.
--annotate_track_id False Annotate every track by its id.
--annotate_class False Annotate every track by its class label.
--annotate_speed False Annotate every track by its current speed.
--annotate_orientation False Annotate every track by its current orientation.
--annotate_age False Annotate every track by its current age.
--show_maximized False Show the track Visualizer maximized. Might affect performance.

Please note that drawing additional features may decrease the playback animation update rate.

Citation

If you use one of our datasets or these scripts in your work, please cite our datasets as follows:

inD Paper

@INPROCEEDINGS{inDdataset,
               title={The inD Dataset: A Drone Dataset of Naturalistic Road User Trajectories at German Intersections},
               author={Bock, Julian and Krajewski, Robert and Moers, Tobias and Runde, Steffen and Vater, Lennart and Eckstein, Lutz},
               booktitle={2020 IEEE Intelligent Vehicles Symposium (IV)},
               pages={1929-1934},
               year={2019},
               doi={10.1109/IV47402.2020.9304839}}

rounD Paper

@INPROCEEDINGS{rounDdataset,
               title={The rounD Dataset: A Drone Dataset of Road User Trajectories at Roundabouts in Germany},
               author={Krajewski, Robert and Moers, Tobias and Bock, Julian and Vater, Lennart and Eckstein, Lutz},
               booktitle={2020 IEEE 23rd International Conference on Intelligent Transportation Systems (ITSC)},
               year={2020},
               doi={10.1109/ITSC45102.2020.9294728}}

exiD Paper

@inproceedings{exiDdataset,
               title={The exiD Dataset: A Real-World Trajectory Dataset of Highly Interactive Highway Scenarios in Germany},
               author={Moers, Tobias and Vater, Lennart and Krajewski, Robert and Bock, Julian and Zlocki, Adrian and Eckstein, Lutz},
               booktitle={2022 IEEE Intelligent Vehicles Symposium (IV)},
               year={2022}}

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.