Python application with nevergrad optimization model for calculating and simulating the least cost of an energy Mix under constraints.
Project description
MixSimulator
MixSimulator is an application with an optimization model for calculating and simulating the least cost of an energy mix under certain constraints. The optimizers used are based on the Nevergrad Python 3.6+ library.
The primary objective of the simulator is to study the relevance of an energy mix connected to each Inter-connected Grid through the coefficient of usage of each unit in the production cost.
Version 0.4
The current version is a multi-agent system (MAS) approach but keeps the previous classic optimization approach available. Check test_mas.py
for more details. (Available events are : powerplant shutdown and powerplant power_on)
Note
This project is a work in progress so it can not yet used in production (Many changes are on their way). Feedbacks are welcome!
Version 0.3.3
Specifications :
- Generic simulator, compatible with data from Madagascar and those from abroad (but may require data pre-processing beforehand);
- Optimization of duty cycle (or usage coefficient) under constraints ;
- Get the production cost and various performance indicators (CO2 emission, unsatisfied demand);
- Estimate of the costs of a mix or a power plant over the long term ;
- Comparison of the performance indicators on different optimizers.
Perspectives :
- Add other constraints ;
- Long-term Optimization ;
- Pair with a transmission and distribution power grid simulator (MixSimulator can provide input data).
Suggestions are welcome!
How to install
It can be installed with :
pip install mixsimulator
MixSimulator is written in Python 3.6 and requires the following Python packages : nevergrad, prophet, typing, numpy, pandas and matplotlib.
How to run
As MixSimulator is a python package, it can be called and used as we can see in test_classic.py
.
List of classes and directories :
- MixSimulator : System basis (Adaptation of the Nevergrad optimizers to the project and auto-parameterization) ;
- nevergradBased/Optimizer : Instance of the optimizer (Receives the indications on the optimizer to choose and the parameters);
- centrals/* : Gathers all the common specifications of the control units (central) ;
- Evaluation : Class for evaluating mix based on performance indicators on several optimizers ;
- data/ : Groups the available datasets.
- documentation/ : documents about the project.
Official documentation will accompany the first release version.
Datasets
Power plants dataset
The dataset "dataset_RI_Toamasina_v2.csv" is for the test and it comes from the Inter-connected energy mix of Toamasina Madagascar (2017) and Some information from the dataset is estimated.
Dataset features needed:
tuneable
(boolean): is the control unit controllable or not?green
(boolean): is it a renewable energy plant?hydro
(boolean): is it a hydro power plant?fuel
(boolean): is it a thermal power plant?centrals
: identificationfuel_consumption
(g/MWh): fuel consumption (in the case of a fossil fuel power plant)availability
(%): plant availabilityfuel_cost
($/g): price of fuel usedinit_value
($): initial investment in setting up the plantlifetime
(years): plant lifetimecarbon_production
(g/MWh): emission rate of CO2 from the power plantraw_power
(MW): nominal power of the plantnb_employees
: number of employees at the central levelmean_salary
($): average salary of plant employeesdemand
(MWh): electricity demandlost
(MWh): electrical loss at another level (ie: transport network)
Hydro specification :
height
(meter): height of the stream ;flow
: flow of the stream ;stock_available
: water reservoir ;capacity
: max water reservoir.
nb_employees * mean_salary
can be used as a variable cost of the plant if you want to directly use other informations as variable cost.
Demand and Variation datas
There is also "DIR-TOAMASINA_concat.csv" about Consumption data (in kwh, more details in Demand.py) and "dataset_RI_Toamasina_variation_template.csv" about limits in variation of power plants load following (WIP).
If you have datasets of any region in the world that can be used to evaluate our model, please contact us.
Contact
For questions and feedbacks related to the project, please send an email to r.andry.rasoanaivo@gmail.com or soloforahamefy@gmail.com or tokyandriaxel@gmail.com
Note
This project is a work in progress so it can not yet used in production (Many changes are on their way). Feedbacks are welcome!
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
File details
Details for the file mixsimulator-0.4.2.tar.gz
.
File metadata
- Download URL: mixsimulator-0.4.2.tar.gz
- Upload date:
- Size: 30.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/4.5.0 pkginfo/1.7.0 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.8.10
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e18118730891de1ed4540d8a4a34f1686d5b8c476838cd46ede640db9795c9d8 |
|
MD5 | 6bcabaadb518dd780003a8ee548056e8 |
|
BLAKE2b-256 | b470c0c17bb99e92e7035f0a69fb088fbb9ddb01f77ab1b53bfd74d206775e0d |
File details
Details for the file mixsimulator-0.4.2-py3-none-any.whl
.
File metadata
- Download URL: mixsimulator-0.4.2-py3-none-any.whl
- Upload date:
- Size: 56.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/4.5.0 pkginfo/1.7.0 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.8.10
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 83822efcf3c5700ee23bf21543e5ab7f53ed06b4b7cb6b2191cf042620aaf9b9 |
|
MD5 | 31628993f004d176bde235349090160b |
|
BLAKE2b-256 | 86b43a1e5fdcc55a9fd566d0af28fb1539d265ab5de62948322d4fa2a12db991 |