eflips-depot 4.1.6__tar.gz → 4.2.1__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.
Potentially problematic release.
This version of eflips-depot might be problematic. Click here for more details.
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/PKG-INFO +1 -1
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/api/__init__.py +47 -2
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/pyproject.toml +1 -1
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/LICENSE.md +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/README.md +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/__init__.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/api/defaults/default_settings.json +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/api/private/__init__.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/api/private/depot.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/api/private/smart_charging.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/api/private/util.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/configuration.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/depot.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/evaluation.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/filters.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/input_epex_power_price.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/layout_opt/__init__.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/layout_opt/doc/__init__.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/layout_opt/doc/direct_details.pdf +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/layout_opt/evaluation.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/layout_opt/opt_tools/__init__.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/layout_opt/opt_tools/crossover.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/layout_opt/opt_tools/fitness_c_urfd.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/layout_opt/opt_tools/fitness_util.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/layout_opt/opt_tools/init.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/layout_opt/opt_tools/mutation.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/layout_opt/optimize_c_urfd.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/layout_opt/packing.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/layout_opt/settings.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/layout_opt/template_creation.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/layout_opt/util.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/plots.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/processes.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/rating.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/resources.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/settings_config.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/simple_vehicle.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/simulation.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/smart_charging.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/standalone.py +0 -0
- {eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/validation.py +0 -0
|
@@ -101,6 +101,7 @@ def simple_consumption_simulation(
|
|
|
101
101
|
initialize_vehicles: bool,
|
|
102
102
|
database_url: Optional[str] = None,
|
|
103
103
|
calculate_timeseries: bool = False,
|
|
104
|
+
terminus_deadtime: timedelta = timedelta(minutes=1),
|
|
104
105
|
) -> None:
|
|
105
106
|
"""
|
|
106
107
|
A simple consumption simulation and vehicle initialization.
|
|
@@ -131,6 +132,10 @@ def simple_consumption_simulation(
|
|
|
131
132
|
is set to False, the "timeseries" column of the Event table will be set to ``None``. Setting this to false
|
|
132
133
|
may significantly speed up the simulation.
|
|
133
134
|
|
|
135
|
+
:param terminus_deadtime: The total deadtime taken to both attach and detach the charging cable at the terminus.
|
|
136
|
+
If the total deadtime is greater than the time between the arrival and departure of the
|
|
137
|
+
vehicle at the terminus, the vehicle will not be able to charge at the terminus.
|
|
138
|
+
|
|
134
139
|
:return: Nothing. The results are added to the database.
|
|
135
140
|
"""
|
|
136
141
|
logger = logging.getLogger(__name__)
|
|
@@ -273,7 +278,7 @@ def simple_consumption_simulation(
|
|
|
273
278
|
timeseries = None
|
|
274
279
|
energy_used = consumption * trip.route.distance / 1000 # kWh
|
|
275
280
|
current_soc = soc_start - energy_used / vehicle_type.battery_capacity
|
|
276
|
-
|
|
281
|
+
session.flush() # TODO
|
|
277
282
|
# Create a driving event
|
|
278
283
|
current_event = Event(
|
|
279
284
|
scenario_id=scenario.id,
|
|
@@ -289,6 +294,7 @@ def simple_consumption_simulation(
|
|
|
289
294
|
timeseries=timeseries,
|
|
290
295
|
)
|
|
291
296
|
session.add(current_event)
|
|
297
|
+
session.flush() # TODO
|
|
292
298
|
|
|
293
299
|
# If the vehicle is
|
|
294
300
|
# - Capable of opportunity charging
|
|
@@ -314,7 +320,10 @@ def simple_consumption_simulation(
|
|
|
314
320
|
# How much energy can be charged in this time?
|
|
315
321
|
energy_charged = (
|
|
316
322
|
max([v[1] for v in vehicle_type.charging_curve])
|
|
317
|
-
*
|
|
323
|
+
* (
|
|
324
|
+
break_time.total_seconds()
|
|
325
|
+
- terminus_deadtime.total_seconds()
|
|
326
|
+
)
|
|
318
327
|
/ 3600
|
|
319
328
|
)
|
|
320
329
|
|
|
@@ -326,6 +335,24 @@ def simple_consumption_simulation(
|
|
|
326
335
|
1,
|
|
327
336
|
)
|
|
328
337
|
|
|
338
|
+
# Create a simple timeseries for the charging event
|
|
339
|
+
timeseries = {
|
|
340
|
+
"time": [
|
|
341
|
+
trip.arrival_time.isoformat(),
|
|
342
|
+
(trip.arrival_time + terminus_deadtime / 2).isoformat(),
|
|
343
|
+
(
|
|
344
|
+
next_trip.departure_time - terminus_deadtime / 2
|
|
345
|
+
).isoformat(),
|
|
346
|
+
next_trip.departure_time.isoformat(),
|
|
347
|
+
],
|
|
348
|
+
"soc": [
|
|
349
|
+
current_soc,
|
|
350
|
+
current_soc,
|
|
351
|
+
post_charge_soc,
|
|
352
|
+
post_charge_soc,
|
|
353
|
+
],
|
|
354
|
+
}
|
|
355
|
+
|
|
329
356
|
# Create the charging event
|
|
330
357
|
current_event = Event(
|
|
331
358
|
scenario_id=scenario.id,
|
|
@@ -1162,6 +1189,24 @@ def _generate_vehicle_events(
|
|
|
1162
1189
|
and "end" in dict_of_events[time_stamp].keys()
|
|
1163
1190
|
):
|
|
1164
1191
|
start_this_event = dict_of_events[time_stamp]["end"]
|
|
1192
|
+
if start_this_event in dict_of_events.keys():
|
|
1193
|
+
if (
|
|
1194
|
+
dict_of_events[start_this_event]["type"]
|
|
1195
|
+
== "Trip"
|
|
1196
|
+
):
|
|
1197
|
+
print(
|
|
1198
|
+
f"Vehicle {current_vehicle.ID} must depart immediately after charged. "
|
|
1199
|
+
f"Thus there will be no STANDBY_DEPARTURE event."
|
|
1200
|
+
)
|
|
1201
|
+
|
|
1202
|
+
else:
|
|
1203
|
+
raise ValueError(
|
|
1204
|
+
f"There is already an event "
|
|
1205
|
+
f"{dict_of_events[start_this_event]} at {start_this_event}."
|
|
1206
|
+
)
|
|
1207
|
+
|
|
1208
|
+
continue
|
|
1209
|
+
|
|
1165
1210
|
dict_of_events[start_this_event] = {
|
|
1166
1211
|
"type": type(process).__name__,
|
|
1167
1212
|
"area": current_area.ID,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{eflips_depot-4.1.6 → eflips_depot-4.2.1}/eflips/depot/layout_opt/opt_tools/fitness_c_urfd.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|