No project description provided
Project description
eflips-eval
Part of the eFLIPS/simBA list of projects.
This repository contains code to evaluate an eflips/simBA simulation. It provides the eflips.evalpackage, which
contains functions to prepare (database -> pandas DataFrame) and visualize (pandas DataFrame -> plotly) simulation results.
It is organized hierarchically as follows:
eflips.eval.inputcontains functions to prepare and visualize simulation input data. That means it does not access any data from theEventorVehicleclasses.eflips.eval.outputcontains functions to prepare and visualize simulation output data. That means these functions all access theEventorVehicleclasses.- within each package, there is a
prepareand avisualizemodule. Thepreparemodule contains functions to prepare the data, thevisualizemodule contains functions to visualize the data. The functions must conform tp a naming convention, in which for theeflips.eval.input.preapre.foo(), there must also exist aeflips.eval.input.visualize.foo()method and vice versa. However, when the exact same data can be visualized in multiple ways, there can also be aeflips.eval.input.visualize.foo_scatter()and aeflips.eval.input.visualize.foo_hist()method. - the signature of a
preparemethod is alwaysprepare(identifier(s), session) -> pd.DataFrame, whereidentifier(s)is a single or tuple ofints identifying a specific database object andsessionis asqlalchemy.orm.session.Sessionobject that is used to access the database. - the signature of a
visualizemethod is alwaysvisualize(df: pd.DataFrame, **kwargs) -> plotly.graph_objects.Figure, wheredfis the DataFrame that is to be visualized andkwargsare additional arguments that can be used to customize the visualization. it does however create a legend (if necessary) and sets axis labels. - a visualize function does not make assumptions about the size of the viewport and does not set the title of the plot.
- The resulting plots should be in english, with proper names (e.g. "Distance [km]" instead of
total_dist) for the values that would be shown to the user.
Installation
TODO
Usage
TODO
Testing
TODO
Documentation
The documentation is generated using sphinx. To generate the documentation, execute the following command in the root directory of the repository:
sphinx-build doc/ doc/_build -W
Development
We utilize the GitHub Flow branching structure. This means that the main branch is always deployable and that all development happens in feature branches. The feature branches are merged into main via pull requests. We utilize the semantic versioning scheme for versioning.
Dependencies are managed using poetry. To install the dependencies, execute the following command in the root directory of the repository:
poetry install
We use black for code formatting. You can use black . to format the code.
We use MyPy for static type checking. You can
use mypy --strict --explicit-package-bases eflips/ to run MyPy on the code.
Please make sure that your poetry.lock and pyproject.toml files are consistent before committing. You can use poetry check to check this. This is also checked by pre-commit.
You can use pre-commit to ensure that MyPy, Black, and Poetry are run before committing. To install pre-commit, execute the following command in the root directory of the repository:
We recommend utilizing linters such as PyLint for static code analysis (but not doing everything it says blindly).
Usage Example
In examples an example script can be found that generates a report.
License
This project is licensed under the AGPLv3 license - see the LICENSE file for details.
Funding Notice
This code was developed as part of the project eBus2030+ funded by the Federal German Ministry for Digital and Transport (BMDV) under grant number 03EMF0402.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file eflips_eval-1.7.7.tar.gz.
File metadata
- Download URL: eflips_eval-1.7.7.tar.gz
- Upload date:
- Size: 29.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
150ec92d0ed2777f5f8ba912050032dd610111ac82000f33ab825fa9e76ddc3d
|
|
| MD5 |
8f566d287fea58a45b6c1f9a0d8bd337
|
|
| BLAKE2b-256 |
92652d6fc84aee5b5502af6f23c4725c471f2265a6959228b8f3e8c39eeeb414
|
Provenance
The following attestation bundles were made for eflips_eval-1.7.7.tar.gz:
Publisher:
release.yml on mpm-tu-berlin/eflips-eval
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
eflips_eval-1.7.7.tar.gz -
Subject digest:
150ec92d0ed2777f5f8ba912050032dd610111ac82000f33ab825fa9e76ddc3d - Sigstore transparency entry: 736918578
- Sigstore integration time:
-
Permalink:
mpm-tu-berlin/eflips-eval@e2257324a5a1cdd7d1bd46440139af6b3b237f56 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/mpm-tu-berlin
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@e2257324a5a1cdd7d1bd46440139af6b3b237f56 -
Trigger Event:
push
-
Statement type:
File details
Details for the file eflips_eval-1.7.7-py3-none-any.whl.
File metadata
- Download URL: eflips_eval-1.7.7-py3-none-any.whl
- Upload date:
- Size: 31.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a831e275cf0cef52a6ea2bc897d50d5a38691ba2bd4b18ef4b55b8e150088f28
|
|
| MD5 |
518f26980a8c3efafbcf7c679338e157
|
|
| BLAKE2b-256 |
b006c2e4381b0334d7ed7c324f9c664a7195d50fe329f59f9c7f17d02c3f4d1b
|
Provenance
The following attestation bundles were made for eflips_eval-1.7.7-py3-none-any.whl:
Publisher:
release.yml on mpm-tu-berlin/eflips-eval
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
eflips_eval-1.7.7-py3-none-any.whl -
Subject digest:
a831e275cf0cef52a6ea2bc897d50d5a38691ba2bd4b18ef4b55b8e150088f28 - Sigstore transparency entry: 736918606
- Sigstore integration time:
-
Permalink:
mpm-tu-berlin/eflips-eval@e2257324a5a1cdd7d1bd46440139af6b3b237f56 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/mpm-tu-berlin
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@e2257324a5a1cdd7d1bd46440139af6b3b237f56 -
Trigger Event:
push
-
Statement type: