ntnuiotenergy / openempire Goto Github PK
View Code? Open in Web Editor NEWStochastic linear program for investments in the European power system
Home Page: https://openempire.readthedocs.io/en/latest/
License: MIT License
Stochastic linear program for investments in the European power system
Home Page: https://openempire.readthedocs.io/en/latest/
License: MIT License
The current documentation practice, writing the documentation in a MS word file and converting to a pdf, does not allow for proper source control and may prohibit (or at least complicate) community contributions.
The documentation should be moved to a system that better allows source control, such as sphinx or readthedocs.
Describe the Bug
Reading an excel file where the values are computed by a formula does not provide NaN values when running on Solstorm.
To Reproduce
Steps to reproduce the behavior:
scripts/copy_and_run_empire_on_hpc.sh
.df = EmpireInputClient(dataset_path).generator.get_max_installed_capacity()
df[df["GeneratorTechnology"]=="Solar"]
Line 14 in 8008ee0
This is the current mapping of months to seasons, that follow the astronomical seasons:
if season == "winter":
return [1, 2, 3]
if season == "spring":
return [4, 5, 6]
if season == "summer":
return [7, 8, 9]
if season == "fall":
return [10, 11, 12]
Wouldn't it make more sense to use the meteorological seasons instead? I.e.
if season == "winter":
return [1, 2, 12]
if season == "spring":
return [3, 4, 5]
if season == "summer":
return [6, 7, 8]
if season == "fall":
return [9, 10, 11]
According to OECD NEA A the ramp rate of nuclear reactors are 3-5% per min. So why is the ramp rate for nuclear defined as 30% per hour in the europe_v51 dataset?
Suggest updating this to 85%, comparable to Gas CCGT or extend Empire to handle minimum production level for thermal plants and set it to 100%.
Additional resource:
Factsheet Load following capabilities of nuclear power plants
Currently, there is no guarantee that we start a representative week on midnight Monday. This should be included to make operational analysis more consistent. Requires smaller modifications in 'scenario_random.py'.
To enhance software quality and rule out problems with commits to the master branch the project should be setup with a continuous integration system to test changes that are push to the central repository,
A prerequisite would be to setup an optimization instance that can be run smoothly without the use of a commercial solver as this would be difficult to use with the relevant CI services due to licensing. The instance "test" can be a good candidate for this.
Possible CI options are either Github Actions or Travis
Describe the Bug
Make the streamlit authentication optional and fix issue with config.txt not being written for test run.
To Reproduce
Steps to reproduce the behavior:
In the current version of OpenEMPIRE the config_run.yaml
file only includes a hand-full of the possible configurations one can imagine using for optimization runs. As of now the user has to interact with the model through the excel input files to run sensitivity analysis, however, some configurations (e.g. enabling/disabling technologies for investment and level of transmission expansion permitted) could easily be changed upon run-time if the configuration file allowed.
Also, more general settings could be added to config_run.yaml,
, e.g. optimization solver settings and log level which are currently hardcoded in Empire.py
.
We should review and restructure the files config_run.yaml
, run.py
and Empire.py
to improve flexibility in model run.
The environment.yaml on the master branch is outdated, several dependencies are missing. Can be fixed easily by copying the one in the development branch.
Now: Peak sample 1 is the aggregated highest load for Europe (all nodes). Peak sample 2 is the highest load for a single node. It is likely that Peak sample 1 and 2 overlaps.
We should revise the logic for sampling peak seasons to ensure that peak seasons are different to avoid redundancy of decision variables.
Currently the full EMPIRE model setup and solution is handled in a single function run_empire
in Empire.py
. There are a number of ways to split it up into several more specialized functions which can be called from the main run_empire
function. The advantage would firstly be improved code readability as it would be clearer which parts are sort of self-contained. Secondly, it would be possible to write unit tests for the individual functions which can be run in a continuous integration framework.
Several generation technologies (Wave, Waste, Hydro regulated, and Hydro run-of-the-river) don't have ScaleFactorInitialCap set in the europe_v51 dataset. They are thus never retired.
Also, Wave has a lifetime of 80. Seems unreasonable?
8): 68422.0, ('France', 719, 'scenario5', 8): 67613.0, ('France',
720, 'scenario5', 8): 69987.0} failed: RuntimeError: Failed to set value for
param=sloadRaw, index=('Germany', 1, 'scenario1', 4), value=57195.1825.
source error message="Index '('Germany', 1, 'scenario1', 4)' is not
valid for indexed component 'sloadRaw'"
Traceback (most recent call last):
File ~\anaconda3\lib\site-packages\pyomo\core\base\param.py:808 in construct
self._setitem_when_not_present(self._validate_index(key), val)
File ~\anaconda3\lib\site-packages\pyomo\core\base\indexed_component.py:874 in _validate_index
raise KeyError(
KeyError: "Index '('Germany', 1, 'scenario1', 4)' is not valid for indexed component 'sloadRaw'"
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File ~\anaconda3\lib\site-packages\spyder_kernels\py3compat.py:356 in compat_exec
exec(code, globals, locals)
File c:\users\lothar\documents\github\openempire\run.py:122
run_empire(name = name,
File ~\Documents\GitHub\OpenEMPIRE\Empire.py:755 in run_empire
instance = model.create_instance(data) #, report_timing=True)
File ~\anaconda3\lib\site-packages\pyomo\core\base\PyomoModel.py:734 in create_instance
instance.load(data, namespaces=_namespaces, profile_memory=profile_memory)
File ~\anaconda3\lib\site-packages\pyomo\core\base\PyomoModel.py:771 in load
self._load_model_data(dp, namespaces, profile_memory=profile_memory)
File ~\anaconda3\lib\site-packages\pyomo\core\base\PyomoModel.py:823 in _load_model_data
self._initialize_component(
File ~\anaconda3\lib\site-packages\pyomo\core\base\PyomoModel.py:871 in _initialize_component
declaration.construct(data)
File ~\anaconda3\lib\site-packages\pyomo\core\base\param.py:811 in construct
raise RuntimeError(
RuntimeError: Failed to set value for param=sloadRaw, index=('Germany', 1, 'scenario1', 4), value=57195.1825.
source error message="Index '('Germany', 1, 'scenario1', 4)' is not valid for indexed component 'sloadRaw'"
If the generator is not referenced in Generator.xlsx, sheet GeneratorTypeAvailability, the generator is given a availability of 1 and hence the stochastic data is not used (even if it is available)). Better to set default to 0, to avoid this silent bug?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.