Simulate Vehicle-to-vehicle (V2V) communication on street networks obtained from OpenStreetMap (OSM)
Main software components are:
To get started on Debian 8 follow these steps.
-
Install basic tools
apt-get install python3 python3-pip git
-
Install libraries
apt-get install libfreetype6-dev libxft-dev libgeos-dev libgdal-dev libspatialindex-dev
-
Optionally install linear algebra libraries for a faster numpy experience
apt-get install libopenblas-dev liblapack-dev gfortran
or if you want to use ATLAS instead of OpenBLAS:
apt-get install liblapack-dev libatlas-dev libatlas-base-dev gfortran
-
Clone the repository and cd into it
-
Create a virtual environment
python3 -m venv venv --without-pip
-
Activate the virtual environment
source venv/bin/activate
-
Download and install pip
wget https://bootstrap.pypa.io/get-pip.py python3 get-pip.py
-
Either
-
Install the package
pip install .
or via symlinks
pip install -e .
Or
-
Install only the dependencies
pip install -r requirements.txt
-
-
Run an exemplary simulation
python3 -m vtovosm.simulations.main
-
Modify the simulation parameters in
vtovosm/simulations/network_config/default.json
and run the simulation again
python3 -m vtovosm.simulations.main
-
Get help by executing
python3 -m vtovosm.simulations.main -h
-
Optional: For realistic vehicle placement and movement install SUMO from the backports repository:
apt-get -t jessie-backports install sumo sumo-tools
To run the tests install the test specific dependencies by executing
pip install -r requirements-test.txt
Run the unit tests by executing
nosetests -v
For all tests to complete successfully SUMO needs to be installed (see Quickstart).
To only run fast tests or tests that do not need network access exectute
nosetests -v -a '!slow'
or
nosetests -v -a '!network'
Run the tests with coverage analysis by starting
nosetests --with-coverage --cover-html --cover-tests --cover-package=vtovosm --verbose
And then open cover/index.html
.
To create a badge execute
coverage-badge -f -o .travis/coverage.svg