Skip to content

Commit

Permalink
Merge branch 'dev' into release/v0.0.4
Browse files Browse the repository at this point in the history
  • Loading branch information
MaGering committed Mar 11, 2024
2 parents e5b74a4 + 0708468 commit 5e07952
Show file tree
Hide file tree
Showing 13 changed files with 1,394 additions and 1,644 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: [ '3.8', '3.9', '3.10']
python-version: ['3.10']

# Steps represent a sequence of tasks that will be executed as part of the job
steps:
Expand Down
2 changes: 1 addition & 1 deletion docs/getting_started.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ Using oemof-B3
Installation
------------

Currently, oemof-B3 needs python 3.8, 3.9 or 3.10 (newer versions may be supported, but installation can take very long).
Currently, oemof-B3 needs python 3.10 (newer versions may be supported, but installation can take very long).

Additionally, you need to install the python dependency manager `poetry <https://python-poetry.org/>`_.
It is recommended to install poetry system-wide via the command below or
Expand Down
2,893 changes: 1,321 additions & 1,572 deletions poetry.lock

Large diffs are not rendered by default.

5 changes: 3 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,13 @@ requires = ["poetry_core>=1.0.0"]
build-backend = "poetry.core.masonry.api"

[tool.poetry.dependencies]
python = ">=3.8, <3.11"
python = ">=3.10, <3.11"
numpy = ">=1.21.0"
rtree = ">=0.9.7"
pyyaml = ">=6.0"
dynaconf = "^3.1.7"
snakemake = ">=5"
oemoflex = { git = "https://git@github.com/rl-institut/oemoflex", tag = "0.0.2a"}
oemoflex = {git = "https://github.com/rl-institut/oemoflex.git", rev = "0.0.3"}
Sphinx = {version = "^4.3.2", optional = true}
sphinx-rtd-theme = {version = "^1.0.0", optional = true}
sphinxcontrib-bibtex = {version = "^2.4.1", optional = true}
Expand All @@ -35,6 +35,7 @@ demandlib = "^0.1.8"
pandas = ">=1.1.0"
boto3 = "1.26.125"
oem2orm = "^0.3.2"
pulp = ">=2.0.0,<2.8.0" # Todo: Delete with higher version. pulp==2.8.0 is error prone

[tool.poetry.dev-dependencies]
black = "20.8b1"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
id_ts;scenario_key;region;var_name;timeindex_start;timeindex_stop;timeindex_resolution;series;var_unit;source;comment
0;ALL;BB;electricity-bev_charging-profile;2019-01-01 00:00:00;2019-01-01 02:00:00;H;"[0.36641573208006967, 0.33080598089020347, 0.30277828702972687]";None;https://github.com/rl-institut/simbev;created with simBEV. contains a mix of hourly simBEV and a constant profile
1;ALL;B;electricity-bev_charging-profile;2015-01-01 00:00:00;2015-01-01 02:00:00;H;"[0.3709718013655691, 0.3303502017829303, 0.2986779968515006]";None;https://github.com/rl-institut/simbev;created with simBEV. contains a mix of hourly simBEV and a constant profile
0;ALL;BB;electricity-bev_charging-profile;2019-01-01 00:00:00;2019-01-01 02:00:00;h;"[0.36641573208006967, 0.33080598089020347, 0.30277828702972687]";None;https://github.com/rl-institut/simbev;created with simBEV. contains a mix of hourly simBEV and a constant profile
1;ALL;B;electricity-bev_charging-profile;2015-01-01 00:00:00;2015-01-01 02:00:00;h;"[0.3709718013655691, 0.3303502017829303, 0.2986779968515006]";None;https://github.com/rl-institut/simbev;created with simBEV. contains a mix of hourly simBEV and a constant profile
8 changes: 4 additions & 4 deletions tests/_files/oemof_b3_resources_timeseries_feedin.csv
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
id_ts;scenario_key;region;var_name;timeindex_start;timeindex_stop;timeindex_resolution;series;var_unit;source;comment
0;ALL;B;wind-profile;2012-01-01 10:00:00;2012-01-01 12:00:00;H;"[0.1593, 0.2175, 0.2113]";None;https://www.renewables.ninja/;navigate to country Germany
1;ALL;BB;wind-profile;2012-01-01 10:00:00;2012-01-01 12:00:00;H;"[0.2299, 0.2635, 0.2866]";None;https://www.renewables.ninja/;navigate to country Germany
0;ALL;B;pv-profile;2012-01-01 10:00:00;2012-01-01 12:00:00;H;"[0.013, 0.018, 0.011]";None;https://www.renewables.ninja/;navigate to country Germany
1;ALL;BB;pv-profile;2012-01-01 10:00:00;2012-01-01 12:00:00;H;"[0.015, 0.019, 0.012]";None;https://www.renewables.ninja/;navigate to country Germany
0;ALL;B;wind-profile;2012-01-01 10:00:00;2012-01-01 12:00:00;h;"[0.1593, 0.2175, 0.2113]";None;https://www.renewables.ninja/;navigate to country Germany
1;ALL;BB;wind-profile;2012-01-01 10:00:00;2012-01-01 12:00:00;h;"[0.2299, 0.2635, 0.2866]";None;https://www.renewables.ninja/;navigate to country Germany
0;ALL;B;pv-profile;2012-01-01 10:00:00;2012-01-01 12:00:00;h;"[0.013, 0.018, 0.011]";None;https://www.renewables.ninja/;navigate to country Germany
1;ALL;BB;pv-profile;2012-01-01 10:00:00;2012-01-01 12:00:00;h;"[0.015, 0.019, 0.012]";None;https://www.renewables.ninja/;navigate to country Germany
36 changes: 18 additions & 18 deletions tests/_files/oemof_b3_resources_timeseries_stacked.csv
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
id_ts;region;var_name;timeindex_start;timeindex_stop;timeindex_resolution;series;var_unit;source;comment
0;BB;biomass-st_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;
1;BB;ch4-gt_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;
2;BB;electricity-curtailment_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;
3;BB;electricity-demand_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[1889794.8071409904, 1870448.7801216468, 1803840.2010708163];;;
4;BB;electricity-liion-battery_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;
5;BB;electricity-liion-battery_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[882505.2, 1194379.0, 1289504.5];;;
6;BB;electricity-shortage_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;
7;BB;solar-pv_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;
8;BB;wind-onshore_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[1145114.0, 801141.1, 595497.8];;;
9;BE;biomass-st_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;
10;BE;ch4-gt_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;
11;BE;electricity-curtailment_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;
12;BE;electricity-demand_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[1889794.8071409904, 1870448.7801216468, 1803840.2010708163];;;
13;BE;electricity-liion-battery_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;
14;BE;electricity-liion-battery_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[882505.2, 1194379.0, 1289504.5];;;
15;BE;electricity-shortage_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;
16;BE;solar-pv_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;
17;BE;wind-onshore_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[1145114.0, 801141.1, 595497.8];;;
0;BB;biomass-st_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;
1;BB;ch4-gt_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;
2;BB;electricity-curtailment_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;
3;BB;electricity-demand_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[1889794.8071409904, 1870448.7801216468, 1803840.2010708163];;;
4;BB;electricity-liion-battery_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;
5;BB;electricity-liion-battery_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[882505.2, 1194379.0, 1289504.5];;;
6;BB;electricity-shortage_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;
7;BB;solar-pv_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;
8;BB;wind-onshore_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[1145114.0, 801141.1, 595497.8];;;
9;BE;biomass-st_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;
10;BE;ch4-gt_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;
11;BE;electricity-curtailment_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;
12;BE;electricity-demand_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[1889794.8071409904, 1870448.7801216468, 1803840.2010708163];;;
13;BE;electricity-liion-battery_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;
14;BE;electricity-liion-battery_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[882505.2, 1194379.0, 1289504.5];;;
15;BE;electricity-shortage_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;
16;BE;solar-pv_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;
17;BE;wind-onshore_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[1145114.0, 801141.1, 595497.8];;;
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
id_ts;region;var_name;timeindex_start;timeindex_stop;timeindex_resolution;series;var_unit;source;comment
0;All;biomass-st_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;
1;All;ch4-gt_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;
2;All;electricity-curtailment_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;
3;All;electricity-demand_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[3779589.614281981, 3740897.5602432936, 3607680.4021416325];;;
4;All;electricity-liion-battery_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;
5;All;electricity-liion-battery_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[1765010.4, 2388758.0, 2579009.0];;;
6;All;electricity-shortage_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;
7;All;solar-pv_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;
8;All;wind-onshore_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[2290228.0, 1602282.2, 1190995.6];;;
0;All;biomass-st_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;
1;All;ch4-gt_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;
2;All;electricity-curtailment_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;
3;All;electricity-demand_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[3779589.614281981, 3740897.5602432936, 3607680.4021416325];;;
4;All;electricity-liion-battery_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;
5;All;electricity-liion-battery_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[1765010.4, 2388758.0, 2579009.0];;;
6;All;electricity-shortage_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;
7;All;solar-pv_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;
8;All;wind-onshore_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[2290228.0, 1602282.2, 1190995.6];;;
36 changes: 18 additions & 18 deletions tests/_files/oemof_b3_resources_timeseries_stacked_comments.csv
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
id_ts;region;var_name;timeindex_start;timeindex_stop;timeindex_resolution;series;var_unit;source;comment
0;BB;biomass-st_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;We have a comment here.
1;BB;ch4-gt_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;We have a comment here.
2;BB;electricity-curtailment_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;We have a comment here.
3;BB;electricity-demand_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[1889794.8071409904, 1870448.7801216468, 1803840.2010708163];;;We have a comment here.
4;BB;electricity-liion-battery_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;We have a comment here.
5;BB;electricity-liion-battery_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[882505.2, 1194379.0, 1289504.5];;;We have a comment here.
6;BB;electricity-shortage_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;We have a comment here.
7;BB;solar-pv_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;We have a comment here.
8;BB;wind-onshore_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[1145114.0, 801141.1, 595497.8];;;We have a comment here.
9;BE;biomass-st_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;We have a comment here.
10;BE;ch4-gt_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;We have a comment here.
11;BE;electricity-curtailment_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;We have a comment here.
12;BE;electricity-demand_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[1889794.8071409904, 1870448.7801216468, 1803840.2010708163];;;We have a comment here.
13;BE;electricity-liion-battery_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;We have a comment here.
14;BE;electricity-liion-battery_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[882505.2, 1194379.0, 1289504.5];;;We have a comment here.
15;BE;electricity-shortage_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;We have a comment here.
16;BE;solar-pv_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;We have a comment here.
17;BE;wind-onshore_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[1145114.0, 801141.1, 595497.8];;;We have a comment here.
0;BB;biomass-st_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;We have a comment here.
1;BB;ch4-gt_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;We have a comment here.
2;BB;electricity-curtailment_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;We have a comment here.
3;BB;electricity-demand_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[1889794.8071409904, 1870448.7801216468, 1803840.2010708163];;;We have a comment here.
4;BB;electricity-liion-battery_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;We have a comment here.
5;BB;electricity-liion-battery_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[882505.2, 1194379.0, 1289504.5];;;We have a comment here.
6;BB;electricity-shortage_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;We have a comment here.
7;BB;solar-pv_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;We have a comment here.
8;BB;wind-onshore_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[1145114.0, 801141.1, 595497.8];;;We have a comment here.
9;BE;biomass-st_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;We have a comment here.
10;BE;ch4-gt_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;We have a comment here.
11;BE;electricity-curtailment_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;We have a comment here.
12;BE;electricity-demand_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[1889794.8071409904, 1870448.7801216468, 1803840.2010708163];;;We have a comment here.
13;BE;electricity-liion-battery_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;We have a comment here.
14;BE;electricity-liion-battery_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[882505.2, 1194379.0, 1289504.5];;;We have a comment here.
15;BE;electricity-shortage_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;We have a comment here.
16;BE;solar-pv_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;We have a comment here.
17;BE;wind-onshore_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[1145114.0, 801141.1, 595497.8];;;We have a comment here.
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
id_ts;region;var_name;timeindex_start;timeindex_stop;timeindex_resolution;series;var_unit;source;comment
9;BE;biomass-st_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;
10;BE;ch4-gt_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;
11;BE;electricity-curtailment_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;
12;BE;electricity-demand_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[1889794.8071409904, 1870448.7801216468, 1803840.2010708163];;;
13;BE;electricity-liion-battery_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;
14;BE;electricity-liion-battery_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[882505.2, 1194379.0, 1289504.5];;;
15;BE;electricity-shortage_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;
16;BE;solar-pv_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[0.0, 0.0, 0.0];;;
17;BE;wind-onshore_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;H;[1145114.0, 801141.1, 595497.8];;;
9;BE;biomass-st_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;
10;BE;ch4-gt_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;
11;BE;electricity-curtailment_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;
12;BE;electricity-demand_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[1889794.8071409904, 1870448.7801216468, 1803840.2010708163];;;
13;BE;electricity-liion-battery_in_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;
14;BE;electricity-liion-battery_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[882505.2, 1194379.0, 1289504.5];;;
15;BE;electricity-shortage_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;
16;BE;solar-pv_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[0.0, 0.0, 0.0];;;
17;BE;wind-onshore_out_electricity;2019-01-01 00:00:00;2019-01-01 02:00:00;h;[1145114.0, 801141.1, 595497.8];;;
4 changes: 2 additions & 2 deletions tests/_files/oemof_b3_results_timeseries_flows.csv
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
id_ts;scenario_key;name;var_name;carrier;region;tech;type;timeindex_start;timeindex_stop;timeindex_resolution;series;var_unit;source;comment
0;;B-electricity-demand;flow_in;electricity;B;demand;;2017-01-01 00:00:00;2017-01-01 02:00:00;H;[675, 666, 634];;;
1;;B-h2-gt;flow_out;h2;B;gt;;2017-01-01 00:00:00;2017-01-01 02:00:00;H;[675, 666, 634];;;
0;;B-electricity-demand;flow_in;electricity;B;demand;;2017-01-01 00:00:00;2017-01-01 02:00:00;h;[675, 666, 634];;;
1;;B-h2-gt;flow_out;h2;B;gt;;2017-01-01 00:00:00;2017-01-01 02:00:00;h;[675, 666, 634];;;
4 changes: 2 additions & 2 deletions tests/_files/oemof_b3_results_timeseries_storage_content.csv
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
id_ts;scenario_key;name;var_name;carrier;region;tech;type;timeindex_start;timeindex_stop;timeindex_resolution;series;var_unit;source;comment
0;;B-electricity-liion_battery;storage_content;electricity;B;liion_battery;;2017-01-01 00:00:00;2017-01-01 02:00:00;H;[120, 40, 0];;;
1;;B-h2-cavern;storage_content;h2;B;cavern;;2017-01-01 00:00:00;2017-01-01 02:00:00;H;[2000, 2200, 2500];;;
0;;B-electricity-liion_battery;storage_content;electricity;B;liion_battery;;2017-01-01 00:00:00;2017-01-01 02:00:00;h;[120, 40, 0];;;
1;;B-h2-cavern;storage_content;h2;B;cavern;;2017-01-01 00:00:00;2017-01-01 02:00:00;h;[2000, 2200, 2500];;;
8 changes: 4 additions & 4 deletions tests/test_data_processing.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,13 +69,13 @@ def full_path(filename):
ts_column_wise = pd.DataFrame(
np.random.randint(0, 10, size=(25, 3)),
columns=list("ABC"),
index=pd.date_range("2021-01-01", "2021-01-02", freq="H"),
index=pd.date_range("2021-01-01", "2021-01-02", freq="h"),
)

ts_column_wise_different = pd.DataFrame(
np.random.randint(0, 5, size=(25, 3)),
columns=list("ABC"),
index=pd.date_range("2021-01-01", "2021-01-02", freq="H"),
index=pd.date_range("2021-01-01", "2021-01-02", freq="h"),
)


Expand Down Expand Up @@ -407,7 +407,7 @@ def test_check_consistency():

assert timeindex_start == pd.to_datetime("2021-01-01 00:00:00")
assert timeindex_stop == pd.to_datetime("2021-01-02 00:00:00")
assert frequency == "H"
assert frequency == "h"

df_stacked_modified = df_stacked.copy()
df_stacked_modified.at["timeindex_resolution", 1] = "M"
Expand Down Expand Up @@ -464,7 +464,7 @@ def test_stack_unstack_timeseries_on_example_data():

df = pd.read_csv(file_path, index_col=0, sep=";")
df.index = pd.to_datetime(df.index)
df = df.asfreq("H")
df = df.asfreq("h")

df_stacked = stack_timeseries(df)
df_unstacked = unstack_timeseries(df_stacked)
Expand Down

0 comments on commit 5e07952

Please sign in to comment.