Skip to content
forked from masc/colmto

Research Field B2.1: Cooperative Lane Management and Traffic flow Optimisation (CoLMTO)

License

Notifications You must be signed in to change notification settings

SocialCars/colmto

 
 

Repository files navigation

Table of Contents

Cooperative Lane Management and Traffic flow Optimisation (CoLMTO)

license Build Status Codacy Report Coverage Report

HTML documentation PDF documentation

Execution Model

The execution model of CoLMTO, developed to conduct my simulation studies, is depicted in the following figure:

CoLMTO Execution Model

Architecture

CoLMTO Architecture

The CoLMTO Simulation Architecture as of release v0.1.1

Build Instructions

Prerequisites

Checkout CoLMTO

git clone --recursive https://gitlab.com/ascm/colmto.git

Build SUMO Submodule (optional)

The version of SUMO currently used for my research is referenced as a submodule (hence the --recursive option above).

Feel free to use any other version, but make sure to set the SUMO_HOME environment variable correctly.

FreeBSD

sudo portmaster devel/git lang/python36 devel/autoconf textproc/xerces-c3 graphics/proj graphics/gdal x11-toolkits/fox16

cd colmto/sumo/sumo
make -f Makefile.cvs
./configure CXX=clang++ --with-xerces-libraries=/usr/local/lib --with-proj-libraries=/usr/local/lib --with-proj-includes=/usr/local/include --with-fox-config=/usr/local/bin/fox-config --enable-pic
make -j $(getconf NPROCESSORS_CONF)

MacOS

brew install Caskroom/cask/xquartz autoconf automake gdal proj xerces-c fox

export CPPFLAGS="$CPPFLAGS -I/opt/X11/include/"
export LDFLAGS="-L/opt/X11/lib"
cd colmto/sumo/sumo
make -f Makefile.cvs
./configure --with-xerces=/usr/local --with-proj-gdal=/usr/local --enable-pic
make -j $(getconf NPROCESSORS_CONF)

Ubuntu

sudo apt-get install autoconf libproj-dev proj-bin proj-data libtool libgdal-dev libxerces-c-dev libfox-1.6-0 libfox-1.6-dev

cd colmto/sumo/sumo
make -f Makefile.cvs
./configure --enable-pic
make -j $(getconf NPROCESSORS_CONF)

Install Required System Packages

FreeBSD

sudo portmaster devel/py-pip@py36 math/py-numpy@py36 science/py-h5py@py36 math/py-matplotlib@py36 textproc/libyaml lang/gcc math/openblas math/atlas math/lapack science/hdf5 print/freetype2

MacOS

brew install libxml2 homebrew/science/hdf5 libyaml

Ubuntu (Yakkety)

sudo apt-get install libyaml-dev libxslt1-dev

Build and Install CoLMTO

On OSes with include paths other than /usr/include, e.g., FreeBSD, MacOS export CPPFLAGS (adjust accordingly):

export CPPFLAGS="-I/usr/local/include"

Install dependencies via pip3 (append --prefix= on MacOS)

pip3.7 install -r requirements.txt --user

Build package

python3.7 setup.py build

Run unit tests

python3.7 setup.py test

Install (local)

python3.7 setup.py install --user

Run CoLMTO

You can run CoLMTO directly as a script, providing your local python install directory is in your $PATH: Keep in mind to set SUMO_HOME accordingly:

export SUMO_HOME=~/colmto/sumo/sumo # adjust accordingly
colmto --runs 1

If you have not installed CoLMTO in the previous section, run it inside the project directory as module.

cd colmto
python3.7 -m colmto --runs 1

Upon first start CoLMTO creates YAML formatted default configurations and its log file in ~/.colmto/:

~/.colmto/
├── colmto.log
├── runconfig.yaml
├── scenarioconfig.yaml
└── vtypesconfig.yaml

Further help on command line options can be obtained by running

colmto --help

Copyright & License

About

Research Field B2.1: Cooperative Lane Management and Traffic flow Optimisation (CoLMTO)

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Python 99.9%
  • Shell 0.1%