ChaProEV 1.1.2__tar.gz → 1.1.4__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {chaproev-1.1.2 → chaproev-1.1.4}/.gitignore +1 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/ChaProEV.toml +2 -3
- {chaproev-1.1.2/src/ChaProEV.egg-info → chaproev-1.1.4}/PKG-INFO +1 -1
- {chaproev-1.1.2 → chaproev-1.1.4}/pyproject.toml +1 -1
- {chaproev-1.1.2 → chaproev-1.1.4}/scenarios/Mopo/XX_bus.toml +25 -7
- {chaproev-1.1.2 → chaproev-1.1.4}/scenarios/Mopo/XX_car.toml +27 -9
- {chaproev-1.1.2 → chaproev-1.1.4}/scenarios/Mopo/XX_truck.toml +24 -6
- {chaproev-1.1.2 → chaproev-1.1.4}/scenarios/Mopo/XX_van.toml +24 -6
- {chaproev-1.1.2 → chaproev-1.1.4}/src/ChaProEV/ChaProEV.py +79 -79
- {chaproev-1.1.2 → chaproev-1.1.4}/src/ChaProEV/charging.py +61 -70
- {chaproev-1.1.2 → chaproev-1.1.4}/src/ChaProEV/consumption.py +66 -50
- {chaproev-1.1.2 → chaproev-1.1.4}/src/ChaProEV/define.py +118 -127
- {chaproev-1.1.2 → chaproev-1.1.4}/src/ChaProEV/make_variants.py +6 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/src/ChaProEV/mobility.py +165 -170
- {chaproev-1.1.2 → chaproev-1.1.4}/src/ChaProEV/run_time.py +118 -69
- {chaproev-1.1.2 → chaproev-1.1.4}/src/ChaProEV/writing.py +19 -17
- {chaproev-1.1.2 → chaproev-1.1.4/src/ChaProEV.egg-info}/PKG-INFO +1 -1
- chaproev-1.1.4/tests/test_battery_space.py +59 -0
- chaproev-1.1.2/tests/test_battery_space.py +0 -50
- {chaproev-1.1.2 → chaproev-1.1.4}/.flake8 +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/.vscode/ltex.dictionary.en-US.txt +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/.vscode/settings.json +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/ChaProEV.pptx +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/Gemfile +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/LICENCE +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/MOPO_logo_chaproev on wht.svg +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/MOPO_logo_chaproev.png +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/MOPO_logo_chaproev.svg +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/MOPO_logo_main.svg +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/MOPO_logo_main_onwhite.svg +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/README.md +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/comparisons/comparison_template.toml +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/ChaProEV_workflow.png +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/Legs.png +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/Locations.png +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/Makefile +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/README.md +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/Trips.png +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/Vehicle_Temperature_correction_factor.svg +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/_config.yml +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/build/doctrees/environment.pickle +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/build/doctrees/index.doctree +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/build/html/.buildinfo +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/build/html/_sources/index.rst.txt +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/build/html/_static/alabaster.css +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/build/html/_static/basic.css +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/build/html/_static/custom.css +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/build/html/_static/doctools.js +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/build/html/_static/documentation_options.js +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/build/html/_static/file.png +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/build/html/_static/language_data.js +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/build/html/_static/minus.png +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/build/html/_static/plus.png +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/build/html/_static/pygments.css +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/build/html/_static/searchtools.js +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/build/html/_static/sphinx_highlight.js +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/build/html/genindex.html +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/build/html/index.html +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/build/html/objects.inv +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/build/html/search.html +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/build/html/searchindex.js +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/charging.md +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/consumption.md +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/define.md +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/index.md +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/make.bat +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/mobility.md +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/running_model,md +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/scenario.md +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/source/index.rst +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/using.md +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/docs/weather.md +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/eu-emblem-low-res.jpg +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/mkdocs.yml +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/requirements.txt +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/scenarios/local_impact_BEVs/baseline.toml +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/setup.cfg +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/src/ChaProEV/__init__.py +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/src/ChaProEV/py.typed +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/src/ChaProEV/weather.py +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/src/ChaProEV.egg-info/PKG-INFO-PC-28624 +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/src/ChaProEV.egg-info/PKG-INFO-PC-28624-2 +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/src/ChaProEV.egg-info/SOURCES-PC-28624-2.txt +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/src/ChaProEV.egg-info/SOURCES-PC-28624.txt +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/src/ChaProEV.egg-info/SOURCES.txt +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/src/ChaProEV.egg-info/dependency_links.txt +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/src/ChaProEV.egg-info/requires-PC-28624-2.txt +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/src/ChaProEV.egg-info/requires-PC-28624.txt +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/src/ChaProEV.egg-info/top_level.txt +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/tests/test_empty_values.py +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/tests/test_same_output.py +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/todo.txt +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/variants/Mopo/XX_car.csv +0 -0
- {chaproev-1.1.2 → chaproev-1.1.4}/variants/Mopo.toml +0 -0
|
@@ -5,10 +5,9 @@ csv_version = true
|
|
|
5
5
|
use_years_in_profiles = true
|
|
6
6
|
|
|
7
7
|
[parallel_processing]
|
|
8
|
-
[parallel_processing.number_of_parallel_processes]
|
|
9
8
|
set_amount_of_processes = false
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
amount_for_scenarios = 4
|
|
10
|
+
amount_for_pickle_saves = 4
|
|
12
11
|
|
|
13
12
|
[interim_files]
|
|
14
13
|
pickle = false
|
|
@@ -11,13 +11,25 @@
|
|
|
11
11
|
[run]
|
|
12
12
|
use_day_types_in_charge_computing = true
|
|
13
13
|
[run.start]
|
|
14
|
-
year =
|
|
15
|
-
month =
|
|
16
|
-
day =
|
|
14
|
+
year = 2017
|
|
15
|
+
month = 12
|
|
16
|
+
day = 31
|
|
17
17
|
hour = 5
|
|
18
18
|
minute = 0
|
|
19
19
|
[run.end] # This is is not included in the run time
|
|
20
|
-
year =
|
|
20
|
+
year = 2019
|
|
21
|
+
month = 1
|
|
22
|
+
day = 1
|
|
23
|
+
hour = 0
|
|
24
|
+
minute = 0
|
|
25
|
+
[run.display_start]
|
|
26
|
+
year = 2018
|
|
27
|
+
month = 1
|
|
28
|
+
day = 1
|
|
29
|
+
hour = 0
|
|
30
|
+
minute = 0
|
|
31
|
+
[run.display_end] # This is is not included in the display time
|
|
32
|
+
year = 2019
|
|
21
33
|
month = 1
|
|
22
34
|
day = 1
|
|
23
35
|
hour = 0
|
|
@@ -28,6 +40,12 @@ type = 'h' # 'min'
|
|
|
28
40
|
# Put the interval type here, use 'H' for hours, 'min' for minutes,
|
|
29
41
|
# 'S' for seconds, 'D' for days. For more info and other types, see here:
|
|
30
42
|
# https://pandas.pydata.org/docs/user_guide/timeseries.html#timeseries-offset-aliases
|
|
43
|
+
[run.display_frequency]
|
|
44
|
+
size = 1 # Put the size of the interval here
|
|
45
|
+
type = 'h' # 'min'
|
|
46
|
+
# Put the interval type here, use 'H' for hours, 'min' for minutes,
|
|
47
|
+
# 'S' for seconds, 'D' for days. For more info and other types, see here:
|
|
48
|
+
# https://pandas.pydata.org/docs/user_guide/timeseries.html#timeseries-offset-aliases
|
|
31
49
|
[run.get_extra_downloads]
|
|
32
50
|
download_weather_data = false
|
|
33
51
|
# Put true if you want to download the weather data. In principle,
|
|
@@ -59,7 +77,7 @@ percentage_in_location_at_run_start = 1
|
|
|
59
77
|
# If filling it directly instead of computing it (controlled by
|
|
60
78
|
# compute_start_location_split in mobility_module below)
|
|
61
79
|
vehicle_discharge_power = 400 # kW
|
|
62
|
-
|
|
80
|
+
proportion_of_discharge_to_network = 0.9
|
|
63
81
|
[locations.bus_route_start]
|
|
64
82
|
vehicle = 'bus'
|
|
65
83
|
connectivity = 1
|
|
@@ -74,7 +92,7 @@ percentage_in_location_at_run_start = 1
|
|
|
74
92
|
# If filling it directly instead of computing it (controlled by
|
|
75
93
|
# compute_start_location_split in mobility_module below)
|
|
76
94
|
vehicle_discharge_power = 0 # kW
|
|
77
|
-
|
|
95
|
+
proportion_of_discharge_to_network = 0.9
|
|
78
96
|
[locations.bus_route_end]
|
|
79
97
|
vehicle = 'bus'
|
|
80
98
|
connectivity = 1
|
|
@@ -89,7 +107,7 @@ percentage_in_location_at_run_start = 1
|
|
|
89
107
|
# If filling it directly instead of computing it (controlled by
|
|
90
108
|
# compute_start_location_split in mobility_module below)
|
|
91
109
|
vehicle_discharge_power = 0 # kW
|
|
92
|
-
|
|
110
|
+
proportion_of_discharge_to_network = 0.9
|
|
93
111
|
|
|
94
112
|
[legs]
|
|
95
113
|
# You can add legs here by copying existing legs,
|
|
@@ -11,13 +11,25 @@
|
|
|
11
11
|
[run]
|
|
12
12
|
use_day_types_in_charge_computing = true
|
|
13
13
|
[run.start]
|
|
14
|
-
year =
|
|
15
|
-
month =
|
|
16
|
-
day =
|
|
14
|
+
year = 2017
|
|
15
|
+
month = 12
|
|
16
|
+
day = 31
|
|
17
17
|
hour = 5
|
|
18
18
|
minute = 0
|
|
19
19
|
[run.end] # This is is not included in the run time
|
|
20
|
-
year =
|
|
20
|
+
year = 2019
|
|
21
|
+
month = 1
|
|
22
|
+
day = 1
|
|
23
|
+
hour = 0
|
|
24
|
+
minute = 0
|
|
25
|
+
[run.display_start]
|
|
26
|
+
year = 2018
|
|
27
|
+
month = 1
|
|
28
|
+
day = 1
|
|
29
|
+
hour = 0
|
|
30
|
+
minute = 0
|
|
31
|
+
[run.display_end] # This is is not included in the display time
|
|
32
|
+
year = 2019
|
|
21
33
|
month = 1
|
|
22
34
|
day = 1
|
|
23
35
|
hour = 0
|
|
@@ -28,6 +40,12 @@ type = 'h' # 'min'
|
|
|
28
40
|
# Put the interval type here, use 'H' for hours, 'min' for minutes,
|
|
29
41
|
# 'S' for seconds, 'D' for days. For more info and other types, see here:
|
|
30
42
|
# https://pandas.pydata.org/docs/user_guide/timeseries.html#timeseries-offset-aliases
|
|
43
|
+
[run.display_frequency]
|
|
44
|
+
size = 1 # Put the size of the interval here
|
|
45
|
+
type = 'h' # 'min'
|
|
46
|
+
# Put the interval type here, use 'H' for hours, 'min' for minutes,
|
|
47
|
+
# 'S' for seconds, 'D' for days. For more info and other types, see here:
|
|
48
|
+
# https://pandas.pydata.org/docs/user_guide/timeseries.html#timeseries-offset-aliases
|
|
31
49
|
[run.get_extra_downloads]
|
|
32
50
|
download_weather_data = false
|
|
33
51
|
# Put true if you want to download the weather data. In principle,
|
|
@@ -59,7 +77,7 @@ percentage_in_location_at_run_start = 1
|
|
|
59
77
|
# If filling it directly instead of computing it (controlled by
|
|
60
78
|
# compute_start_location_split in mobility_module below)
|
|
61
79
|
vehicle_discharge_power = 4.2 # kW
|
|
62
|
-
|
|
80
|
+
proportion_of_discharge_to_network = 0.9
|
|
63
81
|
[locations.work]
|
|
64
82
|
vehicle = 'car'
|
|
65
83
|
connectivity = 0.25
|
|
@@ -74,7 +92,7 @@ percentage_in_location_at_run_start = 0
|
|
|
74
92
|
# If filling it directly instead of computing it (controlled by
|
|
75
93
|
# compute_start_location_split in mobility_module below)
|
|
76
94
|
vehicle_discharge_power = 6.6 # kW
|
|
77
|
-
|
|
95
|
+
proportion_of_discharge_to_network = 0.9
|
|
78
96
|
[locations.leisure]
|
|
79
97
|
vehicle = 'car'
|
|
80
98
|
connectivity = 0.25
|
|
@@ -89,7 +107,7 @@ percentage_in_location_at_run_start = 0
|
|
|
89
107
|
# If filling it directly instead of computing it (controlled by
|
|
90
108
|
# compute_start_location_split in mobility_module below)
|
|
91
109
|
vehicle_discharge_power = 0 # kW
|
|
92
|
-
|
|
110
|
+
proportion_of_discharge_to_network = 0.9
|
|
93
111
|
[locations.weekend]
|
|
94
112
|
vehicle = 'car'
|
|
95
113
|
connectivity = 0.1
|
|
@@ -104,7 +122,7 @@ percentage_in_location_at_run_start = 0
|
|
|
104
122
|
# If filling it directly instead of computing it (controlled by
|
|
105
123
|
# compute_start_location_split in mobility_module below)
|
|
106
124
|
vehicle_discharge_power = 0 # kW
|
|
107
|
-
|
|
125
|
+
proportion_of_discharge_to_network = 0.9
|
|
108
126
|
[locations.holiday]
|
|
109
127
|
vehicle = 'car'
|
|
110
128
|
connectivity = 1
|
|
@@ -119,7 +137,7 @@ percentage_in_location_at_run_start = 0
|
|
|
119
137
|
# If filling it directly instead of computing it (controlled by
|
|
120
138
|
# compute_start_location_split in mobility_module below)
|
|
121
139
|
vehicle_discharge_power = 11 # kW
|
|
122
|
-
|
|
140
|
+
proportion_of_discharge_to_network = 0.9
|
|
123
141
|
|
|
124
142
|
[legs]
|
|
125
143
|
# You can add legs here by copying existing legs,
|
|
@@ -11,13 +11,25 @@
|
|
|
11
11
|
[run]
|
|
12
12
|
use_day_types_in_charge_computing = true
|
|
13
13
|
[run.start]
|
|
14
|
-
year =
|
|
15
|
-
month =
|
|
16
|
-
day =
|
|
14
|
+
year = 2017
|
|
15
|
+
month = 12
|
|
16
|
+
day = 31
|
|
17
17
|
hour = 5
|
|
18
18
|
minute = 0
|
|
19
19
|
[run.end] # This is is not included in the run time
|
|
20
|
-
year =
|
|
20
|
+
year = 2019
|
|
21
|
+
month = 1
|
|
22
|
+
day = 1
|
|
23
|
+
hour = 0
|
|
24
|
+
minute = 0
|
|
25
|
+
[run.display_start]
|
|
26
|
+
year = 2018
|
|
27
|
+
month = 1
|
|
28
|
+
day = 1
|
|
29
|
+
hour = 0
|
|
30
|
+
minute = 0
|
|
31
|
+
[run.display_end] # This is is not included in the display time
|
|
32
|
+
year = 2019
|
|
21
33
|
month = 1
|
|
22
34
|
day = 1
|
|
23
35
|
hour = 0
|
|
@@ -28,6 +40,12 @@ type = 'h' # 'min'
|
|
|
28
40
|
# Put the interval type here, use 'H' for hours, 'min' for minutes,
|
|
29
41
|
# 'S' for seconds, 'D' for days. For more info and other types, see here:
|
|
30
42
|
# https://pandas.pydata.org/docs/user_guide/timeseries.html#timeseries-offset-aliases
|
|
43
|
+
[run.display_frequency]
|
|
44
|
+
size = 1 # Put the size of the interval here
|
|
45
|
+
type = 'h' # 'min'
|
|
46
|
+
# Put the interval type here, use 'H' for hours, 'min' for minutes,
|
|
47
|
+
# 'S' for seconds, 'D' for days. For more info and other types, see here:
|
|
48
|
+
# https://pandas.pydata.org/docs/user_guide/timeseries.html#timeseries-offset-aliases
|
|
31
49
|
[run.get_extra_downloads]
|
|
32
50
|
download_weather_data = false
|
|
33
51
|
# Put true if you want to download the weather data. In principle,
|
|
@@ -59,7 +77,7 @@ percentage_in_location_at_run_start = 1
|
|
|
59
77
|
# If filling it directly instead of computing it (controlled by
|
|
60
78
|
# compute_start_location_split in mobility_module below)
|
|
61
79
|
vehicle_discharge_power = 150 # kW
|
|
62
|
-
|
|
80
|
+
proportion_of_discharge_to_network = 0.9
|
|
63
81
|
[locations.truck_customer]
|
|
64
82
|
vehicle = 'truck'
|
|
65
83
|
connectivity = 0.1
|
|
@@ -74,7 +92,7 @@ percentage_in_location_at_run_start = 1
|
|
|
74
92
|
# If filling it directly instead of computing it (controlled by
|
|
75
93
|
# compute_start_location_split in mobility_module below)
|
|
76
94
|
vehicle_discharge_power = 0 # kW
|
|
77
|
-
|
|
95
|
+
proportion_of_discharge_to_network = 0.9
|
|
78
96
|
|
|
79
97
|
[legs]
|
|
80
98
|
# You can add legs here by copying existing legs,
|
|
@@ -11,13 +11,25 @@
|
|
|
11
11
|
[run]
|
|
12
12
|
use_day_types_in_charge_computing = true
|
|
13
13
|
[run.start]
|
|
14
|
-
year =
|
|
15
|
-
month =
|
|
16
|
-
day =
|
|
14
|
+
year = 2017
|
|
15
|
+
month = 12
|
|
16
|
+
day = 31
|
|
17
17
|
hour = 5
|
|
18
18
|
minute = 0
|
|
19
19
|
[run.end] # This is is not included in the run time
|
|
20
|
-
year =
|
|
20
|
+
year = 2019
|
|
21
|
+
month = 1
|
|
22
|
+
day = 1
|
|
23
|
+
hour = 0
|
|
24
|
+
minute = 0
|
|
25
|
+
[run.display_start]
|
|
26
|
+
year = 2018
|
|
27
|
+
month = 1
|
|
28
|
+
day = 1
|
|
29
|
+
hour = 0
|
|
30
|
+
minute = 0
|
|
31
|
+
[run.display_end] # This is is not included in the display time
|
|
32
|
+
year = 2019
|
|
21
33
|
month = 1
|
|
22
34
|
day = 1
|
|
23
35
|
hour = 0
|
|
@@ -28,6 +40,12 @@ type = 'h' # 'min'
|
|
|
28
40
|
# Put the interval type here, use 'H' for hours, 'min' for minutes,
|
|
29
41
|
# 'S' for seconds, 'D' for days. For more info and other types, see here:
|
|
30
42
|
# https://pandas.pydata.org/docs/user_guide/timeseries.html#timeseries-offset-aliases
|
|
43
|
+
[run.display_frequency]
|
|
44
|
+
size = 1 # Put the size of the interval here
|
|
45
|
+
type = 'h' # 'min'
|
|
46
|
+
# Put the interval type here, use 'H' for hours, 'min' for minutes,
|
|
47
|
+
# 'S' for seconds, 'D' for days. For more info and other types, see here:
|
|
48
|
+
# https://pandas.pydata.org/docs/user_guide/timeseries.html#timeseries-offset-aliases
|
|
31
49
|
[run.get_extra_downloads]
|
|
32
50
|
download_weather_data = false
|
|
33
51
|
# Put true if you want to download the weather data. In principle,
|
|
@@ -59,7 +77,7 @@ percentage_in_location_at_run_start = 1
|
|
|
59
77
|
# If filling it directly instead of computing it (controlled by
|
|
60
78
|
# compute_start_location_split in mobility_module below)
|
|
61
79
|
vehicle_discharge_power = 100 # kW
|
|
62
|
-
|
|
80
|
+
proportion_of_discharge_to_network = 0.9
|
|
63
81
|
[locations.van_customer]
|
|
64
82
|
vehicle = 'van'
|
|
65
83
|
connectivity = 0.1
|
|
@@ -74,7 +92,7 @@ percentage_in_location_at_run_start = 1
|
|
|
74
92
|
# If filling it directly instead of computing it (controlled by
|
|
75
93
|
# compute_start_location_split in mobility_module below)
|
|
76
94
|
vehicle_discharge_power = 0 # kW
|
|
77
|
-
|
|
95
|
+
proportion_of_discharge_to_network = 0.9
|
|
78
96
|
|
|
79
97
|
|
|
80
98
|
[legs]
|
|
@@ -11,6 +11,7 @@ from multiprocessing import Pool
|
|
|
11
11
|
|
|
12
12
|
import numpy as np
|
|
13
13
|
import pandas as pd
|
|
14
|
+
from box import Box
|
|
14
15
|
from ETS_CookBook import ETS_CookBook as cook
|
|
15
16
|
|
|
16
17
|
try:
|
|
@@ -106,29 +107,27 @@ except ModuleNotFoundError:
|
|
|
106
107
|
# we are importing again
|
|
107
108
|
|
|
108
109
|
|
|
109
|
-
def car_home_parking(case_name: str, general_parameters:
|
|
110
|
-
home_type_parameters:
|
|
111
|
-
input_root: str = general_parameters
|
|
110
|
+
def car_home_parking(case_name: str, general_parameters: Box) -> None:
|
|
111
|
+
home_type_parameters: Box = general_parameters.home_type
|
|
112
|
+
input_root: str = general_parameters.files.input_root
|
|
112
113
|
input_folder: str = f'{input_root}/{case_name}'
|
|
113
|
-
percentages_file_name: str = home_type_parameters
|
|
114
|
+
percentages_file_name: str = home_type_parameters.percentages_file
|
|
114
115
|
car_drivewway_percentages: pd.DataFrame = pd.read_csv(
|
|
115
116
|
f'{input_folder}/{percentages_file_name}'
|
|
116
|
-
).set_index(home_type_parameters
|
|
117
|
+
).set_index(home_type_parameters.index_name)
|
|
117
118
|
|
|
118
|
-
profiles_index: ty.List[str] = home_type_parameters
|
|
119
|
-
own_driveway_name: str = home_type_parameters
|
|
120
|
-
on_street_name: str = home_type_parameters
|
|
119
|
+
profiles_index: ty.List[str] = home_type_parameters.profiles_index
|
|
120
|
+
own_driveway_name: str = home_type_parameters.own_driveway_name
|
|
121
|
+
on_street_name: str = home_type_parameters.on_street_name
|
|
121
122
|
|
|
122
|
-
output_root:
|
|
123
|
+
output_root: str = general_parameters.files.output_root
|
|
123
124
|
output_folder: str = f'{output_root}/{case_name}'
|
|
124
125
|
|
|
125
|
-
consumption_parameters:
|
|
126
|
-
consumption_table_name: str = consumption_parameters
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
'use_years_in_profiles'
|
|
131
|
-
]
|
|
126
|
+
consumption_parameters: Box = general_parameters.consumption
|
|
127
|
+
consumption_table_name: str = consumption_parameters.consumption_table_name
|
|
128
|
+
use_years_in_profiles: bool = (
|
|
129
|
+
general_parameters.variants.use_years_in_profiles
|
|
130
|
+
)
|
|
132
131
|
|
|
133
132
|
variant_names: ty.List[str] = list(car_drivewway_percentages.index)
|
|
134
133
|
for variant_name in variant_names:
|
|
@@ -191,47 +190,40 @@ def car_home_parking(case_name: str, general_parameters: ty.Dict) -> None:
|
|
|
191
190
|
f'{output_folder}/{variant_name}_{consumption_table_name}.pkl'
|
|
192
191
|
)
|
|
193
192
|
|
|
194
|
-
do_fleet_tables: float =
|
|
195
|
-
|
|
196
|
-
|
|
193
|
+
do_fleet_tables: float = (
|
|
194
|
+
general_parameters.profile_dataframe.do_fleet_tables
|
|
195
|
+
)
|
|
197
196
|
if do_fleet_tables:
|
|
198
197
|
fleet_profiles(case_name, variant_name, general_parameters)
|
|
199
198
|
|
|
200
199
|
|
|
201
200
|
def fleet_profiles(
|
|
202
|
-
case_name: str, scenario_name: str, general_parameters:
|
|
201
|
+
case_name: str, scenario_name: str, general_parameters: Box
|
|
203
202
|
) -> None:
|
|
204
|
-
home_type_parameters:
|
|
205
|
-
consumption_parameters:
|
|
206
|
-
consumption_table_name: str = consumption_parameters
|
|
207
|
-
|
|
208
|
-
|
|
203
|
+
home_type_parameters: Box = general_parameters.home_type
|
|
204
|
+
consumption_parameters: Box = general_parameters.consumption
|
|
205
|
+
consumption_table_name: str = consumption_parameters.consumption_table_name
|
|
206
|
+
|
|
207
|
+
distance_header: str = consumption_parameters.distance_header
|
|
208
|
+
fleet_distance_header: str = consumption_parameters.fleet_distance_header
|
|
209
|
+
|
|
210
|
+
energy_carriers_consumption_names: ty.List[str] = (
|
|
211
|
+
consumption_parameters.energy_carriers_consumption_names
|
|
212
|
+
)
|
|
209
213
|
|
|
210
|
-
distance_header: str = consumption_parameters['distance_header']
|
|
211
|
-
fleet_distance_header: str = consumption_parameters[
|
|
212
|
-
'fleet_distance_header'
|
|
213
|
-
]
|
|
214
|
-
energy_carriers_consumption_names: ty.List[str] = consumption_parameters[
|
|
215
|
-
'energy_carriers_consumption_names'
|
|
216
|
-
]
|
|
217
214
|
fleet_energy_carriers_consumption_names: ty.List[str] = (
|
|
218
|
-
consumption_parameters
|
|
215
|
+
consumption_parameters.fleet_energy_carriers_consumption_names
|
|
219
216
|
)
|
|
220
|
-
energy_carriers: ty.List[str] = consumption_parameters
|
|
221
|
-
output_root:
|
|
217
|
+
energy_carriers: ty.List[str] = consumption_parameters.energy_carriers
|
|
218
|
+
output_root: str = general_parameters.files.output_root
|
|
222
219
|
output_folder: str = f'{output_root}/{case_name}'
|
|
223
|
-
profiles_index: ty.List[str] = home_type_parameters
|
|
224
|
-
profile_headers: ty.List = general_parameters
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
'fleet_headers'
|
|
229
|
-
]
|
|
230
|
-
input_root: str = general_parameters['files']['input_root']
|
|
220
|
+
profiles_index: ty.List[str] = home_type_parameters.profiles_index
|
|
221
|
+
profile_headers: ty.List = general_parameters.profile_dataframe.headers
|
|
222
|
+
fleet_headers: ty.List = general_parameters.profile_dataframe.fleet_headers
|
|
223
|
+
|
|
224
|
+
input_root: str = general_parameters.files.input_root
|
|
231
225
|
input_folder: str = f'{input_root}/{case_name}'
|
|
232
|
-
fleet_file_name: str = general_parameters
|
|
233
|
-
'fleet_file_name'
|
|
234
|
-
]
|
|
226
|
+
fleet_file_name: str = general_parameters.profile_dataframe.fleet_file_name
|
|
235
227
|
|
|
236
228
|
fleet_split: pd.DataFrame = pd.read_csv(
|
|
237
229
|
f'{input_folder}/{fleet_file_name}'
|
|
@@ -241,7 +233,7 @@ def fleet_profiles(
|
|
|
241
233
|
fleet_split.loc[scenario_name]['Total Fleet (thousands)']
|
|
242
234
|
)
|
|
243
235
|
consumption_table: pd.DataFrame = pd.read_pickle(
|
|
244
|
-
f'{output_folder}/{scenario_name}_
|
|
236
|
+
f'{output_folder}/{scenario_name}_{consumption_table_name}.pkl'
|
|
245
237
|
)
|
|
246
238
|
fleet_consumption_table: pd.DataFrame = pd.DataFrame(
|
|
247
239
|
index=consumption_table.index
|
|
@@ -294,9 +286,9 @@ def fleet_profiles(
|
|
|
294
286
|
|
|
295
287
|
|
|
296
288
|
def run_scenario(
|
|
297
|
-
scenario:
|
|
289
|
+
scenario: Box, case_name: str, general_parameters: Box
|
|
298
290
|
) -> None:
|
|
299
|
-
scenario_name: str = scenario
|
|
291
|
+
scenario_name: str = scenario.name
|
|
300
292
|
print(scenario_name)
|
|
301
293
|
decla_start: datetime.datetime = datetime.datetime.now()
|
|
302
294
|
location_connections, legs, locations, trips = (
|
|
@@ -367,7 +359,7 @@ def run_scenario(
|
|
|
367
359
|
(datetime.datetime.now() - charge_start).total_seconds(),
|
|
368
360
|
)
|
|
369
361
|
|
|
370
|
-
battery_capacity: float = scenario
|
|
362
|
+
battery_capacity: float = scenario.vehicle.battery_capacity
|
|
371
363
|
battery_capacity_dataframe: pd.DataFrame = (
|
|
372
364
|
battery_capacity * location_split
|
|
373
365
|
)
|
|
@@ -377,7 +369,7 @@ def run_scenario(
|
|
|
377
369
|
|
|
378
370
|
connectivities: np.ndarray = np.array(
|
|
379
371
|
[
|
|
380
|
-
scenario
|
|
372
|
+
scenario.locations[dataframe_location].connectivity
|
|
381
373
|
for dataframe_location in battery_capacity_dataframe.columns
|
|
382
374
|
]
|
|
383
375
|
)
|
|
@@ -404,9 +396,9 @@ def run_scenario(
|
|
|
404
396
|
vehicle_discharge_power_per_location,
|
|
405
397
|
discharge_power_to_network_per_location,
|
|
406
398
|
]
|
|
407
|
-
profile_dataframe_headers: ty.List[str] =
|
|
408
|
-
|
|
409
|
-
|
|
399
|
+
profile_dataframe_headers: ty.List[str] = (
|
|
400
|
+
general_parameters.profile_dataframe.headers
|
|
401
|
+
)
|
|
410
402
|
profile_dataframe: pd.DataFrame = run_time.get_time_stamped_dataframe(
|
|
411
403
|
scenario, general_parameters, locations_as_columns=False
|
|
412
404
|
)
|
|
@@ -416,18 +408,24 @@ def run_scenario(
|
|
|
416
408
|
|
|
417
409
|
profile_dataframe[dataframe_header] = dataframe_for_profile.sum(axis=1)
|
|
418
410
|
|
|
419
|
-
output_root: str = general_parameters
|
|
411
|
+
output_root: str = general_parameters.files.output_root
|
|
420
412
|
output_folder: str = f'{output_root}/{case_name}'
|
|
413
|
+
display_range: pd.DatetimeIndex = run_time.get_time_range(
|
|
414
|
+
scenario, general_parameters
|
|
415
|
+
)[2]
|
|
416
|
+
profile_dataframe = profile_dataframe.loc[display_range]
|
|
417
|
+
profile_dataframe.index.name = 'Time Tag'
|
|
421
418
|
profile_dataframe.to_pickle(f'{output_folder}/{scenario_name}_profile.pkl')
|
|
422
419
|
|
|
423
|
-
do_fleet_tables: float =
|
|
424
|
-
|
|
425
|
-
|
|
420
|
+
do_fleet_tables: float = (
|
|
421
|
+
general_parameters.profile_dataframe.do_fleet_tables
|
|
422
|
+
)
|
|
423
|
+
|
|
426
424
|
if do_fleet_tables:
|
|
427
425
|
fleet_profiles(case_name, scenario_name, general_parameters)
|
|
428
426
|
|
|
429
427
|
|
|
430
|
-
def load_scenarios(case_name: str) -> ty.List[
|
|
428
|
+
def load_scenarios(case_name: str) -> ty.List[Box]:
|
|
431
429
|
scenario_folder_files: ty.List[str] = os.listdir(f'scenarios/{case_name}')
|
|
432
430
|
scenario_files: ty.List[str] = [
|
|
433
431
|
scenario_folder_file
|
|
@@ -438,49 +436,51 @@ def load_scenarios(case_name: str) -> ty.List[ty.Dict]:
|
|
|
438
436
|
f'scenarios/{case_name}/{scenario_file}'
|
|
439
437
|
for scenario_file in scenario_files
|
|
440
438
|
]
|
|
441
|
-
scenarios: ty.List[
|
|
442
|
-
cook.parameters_from_TOML(scenario_file_path)
|
|
439
|
+
scenarios: ty.List[Box] = [
|
|
440
|
+
Box(cook.parameters_from_TOML(scenario_file_path))
|
|
443
441
|
for scenario_file_path in scenario_file_paths
|
|
444
442
|
]
|
|
445
443
|
for scenario, scenario_file in zip(scenarios, scenario_files):
|
|
446
|
-
scenario
|
|
444
|
+
scenario.name = scenario_file.split('.')[0]
|
|
447
445
|
return scenarios
|
|
448
446
|
|
|
449
447
|
|
|
450
448
|
def run_ChaProEV(case_name: str) -> None:
|
|
451
449
|
start_: datetime.datetime = datetime.datetime.now()
|
|
452
450
|
general_parameters_file_name: str = 'ChaProEV.toml'
|
|
453
|
-
general_parameters:
|
|
454
|
-
general_parameters_file_name
|
|
451
|
+
general_parameters: Box = Box(
|
|
452
|
+
cook.parameters_from_TOML(general_parameters_file_name)
|
|
455
453
|
)
|
|
456
|
-
output_root: str = general_parameters
|
|
454
|
+
output_root: str = general_parameters.files.output_root
|
|
457
455
|
cook.check_if_folder_exists(f'{output_root}/{case_name}')
|
|
458
|
-
|
|
456
|
+
variant_parameters: Box = general_parameters.variants
|
|
457
|
+
use_variants: bool = variant_parameters.use_variants
|
|
459
458
|
if use_variants:
|
|
460
|
-
csv_version =
|
|
459
|
+
csv_version: bool = variant_parameters.csv_version
|
|
461
460
|
make_variants.make_variants(case_name, csv_version)
|
|
462
461
|
|
|
463
|
-
scenarios: ty.List[
|
|
462
|
+
scenarios: ty.List[Box] = load_scenarios(case_name)
|
|
464
463
|
|
|
465
|
-
set_amount_of_processes: bool =
|
|
466
|
-
|
|
467
|
-
|
|
464
|
+
set_amount_of_processes: bool = (
|
|
465
|
+
general_parameters.parallel_processing.set_amount_of_processes
|
|
466
|
+
)
|
|
468
467
|
if set_amount_of_processes:
|
|
469
|
-
|
|
468
|
+
amount_of_parallel_processes: int | None = None
|
|
470
469
|
else:
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
470
|
+
amount_of_parallel_processes = (
|
|
471
|
+
general_parameters.parallel_processing.amount_for_scenarios
|
|
472
|
+
)
|
|
474
473
|
|
|
475
|
-
with Pool(
|
|
474
|
+
with Pool(amount_of_parallel_processes) as scenarios_pool:
|
|
476
475
|
scenarios_pool.starmap(
|
|
477
476
|
run_scenario,
|
|
478
477
|
zip(scenarios, repeat(case_name), repeat(general_parameters)),
|
|
479
478
|
)
|
|
480
479
|
|
|
481
|
-
do_car_home_type_split: bool =
|
|
482
|
-
|
|
483
|
-
|
|
480
|
+
do_car_home_type_split: bool = (
|
|
481
|
+
general_parameters.home_type.do_car_home_type_split
|
|
482
|
+
)
|
|
483
|
+
|
|
484
484
|
if do_car_home_type_split:
|
|
485
485
|
car_home_parking(case_name, general_parameters)
|
|
486
486
|
|