simobility
simobility is a light-weight mobility simulation framework. Best for quick prototyping
simobility is a human-friendly Python framework that helps scientists and engineers to prototype and compare fleet optimization algorithms (autonomous and human-driven vehicles). It provides a set of building blocks that can be used to design different simulation scenarious, run simulations and calculate metrics. It is easy to plug in custom demand models, customer behavior models, fleet types, spatio-temporal models (for example, use OSRM for routing vehicles and machine learning models trained on historical data to predict ETA).
Motivation
Create an environment for experiments with machine learning algorithms for decision-making problems in mobility services and compare them to classical solutions.
Some examples:
-
Deep Reinforcement Learning with Applications in Transportation
-
T. Oda and C. Joe-Wong, "Movi: A model-free approach to dynamic fleet management". 2018
Installation
pip install simobility
Contributions and thanks
Thanks to all who contributed to the concept/code:
Simulation example
Metrics example
{
"avg_paid_utilization": 63.98,
"avg_utilization": 96.87,
"avg_waiting_time": 292.92,
"created": 3998,
"dropoffs": 589,
"empty_distance": 640.37,
"empty_distance_pcnt": 33.67,
"fleet_paid_utilization": 63.98,
"fleet_utilization": 96.87,
"num_vehicles": 50,
"pickup_rate": 15.48,
"pickups": 619,
"total_distance": 1902.04,
}
Simulation logs
Read logs with pandas
import pandas as pd
data = pd.read_csv(
"simulation_output.csv",
sep=";",
converters={"details": lambda v: eval(v)},
)
details = data.details.apply(pd.Series)
Run OSRM
wget http://download.geofabrik.de/north-america/us/new-york-latest.osm.pbf
docker run -t -v "${PWD}:/data" osrm/osrm-backend osrm-extract -p /opt/car.lua /data/new-york-latest.osm.pbf
docker run -t -v "${PWD}:/data" osrm/osrm-backend osrm-partition /data/new-york-latest.osrm
docker run -t -v "${PWD}:/data" osrm/osrm-backend osrm-customize /data/new-york-latest.osrm
docker run -d -t -i -p 5010:5000 -v "${PWD}:/data" osrm/osrm-backend osrm-routed --algorithm mld /data/new-york-latest.osrm
Metadata
Release files for simobility 0.3.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| simobility-0.3.0.tar.gz | 22.6 kB | Without provenance | Details for simobility-0.3.0.tar.gz |
Release files / simobility-0.3.0.tar.gz
| Download URL | simobility-0.3.0.tar.gz |
|---|---|
| Size | 22.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
8758755a14d3172b8065fb32b78bef279c2a62b5fc51552bd152470ab8fa2043
|
|
BLAKE2b-256 checksum How to use checksums |
3d0b3773e134cb075aca724a2612ca2fe68edf1827b1814e1c1884672a63c16b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/44.0.0 requests-toolbelt/0.9.1 tqdm/4.41.1 CPython/3.7.3
|
Security for simobility 0.3.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.