Package: eflips-depot
eflips-depotPart of theeFLIPS/simBAlist of projects.eFLIPS has been developed within several research projects at the Department of Methods of Product Development and
Mechatronics at the Technische Universität Berlin (seehttps://www.tu.berlin/mpm/forschung/projekte/eflips).With eFLIPS, electric fleets and depots can be simulated, planned and designed.
This repository contains only the planning and design tool for depots.The repository contains an example for the simulation and planning of an elecric bus depot, which is based on the
dissertation by Dr.-Ing. Enrico Lauth (seehttps://depositonce.tu-berlin.de/items/f47662f7-c9ae-4fbf-9e9c-bcd307b73aa7).InstallationClone this git repository (ordownload a specific release)gitclonegit@github.com:mpm-tu-berlin/eflips-depot.gitInstall the packages listed inpoetry.lockandpyproject.tomlinto your Python environment. Notes:The suggested Python version os 3.11.*, it may work with other versions, but this is not tested.Using thepoetrypackage manager is recommended. It can be installed accoring to the
instructions listedhere.macOSpoetryenvuse3.11
poetryinstallWindowsIf you are using Windows, you have to provide the full path to the desired Python executable, e.g.:poetryenvuseC:\Users\user\AppData\Local\Programs\Python\Python311\python.exe
poetryinstallTo start a simulation, an existingeFLIPS-Modeldatabase is requires. Once you have that, you can run the scriptbus_depot/user_example.pyUsagePlease refer to theDocumentation sectionof this Readme for information
on how to use eFLIPS-Depot.The API of eFLIPS-Depot can be accessed viaeFLIPS.depot.api. A usage example can be found in the
scriptbus_depot/user_example.py.TestingNOTE: Be aware that the tests will clear the database specified in theDATABASE_URLenvironment variable. Make sure that you are not using a database that you want to keep.Testing is done using thepytestframework with tests located in thetestsdirectory. To run the tests, execute the following command in the root directory of the repository:exportPYTHONPATH=tests:.# To make sure that the tests can find the eflips packageexportDATABASE_URL=postgis://postgres:postgres@localhost:5432/postgres# Or whatever your database URL isexportDJANGO_SETTINGS_MODULE=tests.api.djangosettings# To make sure that the tests use the correct settingspytestDocumentationDocumentation is automatically created from the docstrings in the code usingsphinx-autoapi. If you have downloaded a specific release, the documentation is included in thedocsdirectory. If you have cloned the repository, you can create the documentation yourself by executing the following command in the root directory of the repository:cddocs/sphinx-build-bhtml._buildDevelopmentWe utilize theGitHub Flowbranching structure. This means
that themainbranch is always deployable and that all development happens in feature branches. The feature branches
are merged intomainvia pull requests.We useblackfor code formatting. You can usepre-committo ensure the code is formatted correctly before committing. You are also free to
use other methods to format the code, but please ensure that the code is formatted correctly before committing.Please make sure that yourpoetry.lockandpyproject.tomlfiles are consistent before committing. You can usepoetry checkto check this. This is also checked by pre-commit.LicenseThis project is licensed under the AGPLv3 license - see theLICENSEfile for details.Funding NoticeThis code was developed as part of the projecteBus2030+funded by the Federal German Ministry for Digital and Transport (BMDV) under grant number 03EMF0402.