eflips-opt 0.3.2__tar.gz → 0.3.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.
- {eflips_opt-0.3.2 → eflips_opt-0.3.4}/PKG-INFO +2 -2
- {eflips_opt-0.3.2 → eflips_opt-0.3.4}/eflips/opt/depot_rotation_matching.py +5 -3
- {eflips_opt-0.3.2 → eflips_opt-0.3.4}/eflips/opt/smart_charging.py +6 -0
- {eflips_opt-0.3.2 → eflips_opt-0.3.4}/pyproject.toml +2 -2
- {eflips_opt-0.3.2 → eflips_opt-0.3.4}/LICENSE +0 -0
- {eflips_opt-0.3.2 → eflips_opt-0.3.4}/README.md +0 -0
- {eflips_opt-0.3.2 → eflips_opt-0.3.4}/eflips/opt/__init__.py +0 -0
- {eflips_opt-0.3.2 → eflips_opt-0.3.4}/eflips/opt/scheduling/__init__.py +0 -0
- {eflips_opt-0.3.2 → eflips_opt-0.3.4}/eflips/opt/scheduling/util.py +0 -0
- {eflips_opt-0.3.2 → eflips_opt-0.3.4}/eflips/opt/util.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.3
|
|
2
2
|
Name: eflips-opt
|
|
3
|
-
Version: 0.3.
|
|
3
|
+
Version: 0.3.4
|
|
4
4
|
Summary: A collection of pre-simulation optimization algorithms for eFLIPS.
|
|
5
5
|
License: AGPLV3.md
|
|
6
6
|
Author: Ludger Heide
|
|
@@ -13,7 +13,7 @@ Classifier: Programming Language :: Python :: 3.11
|
|
|
13
13
|
Classifier: Programming Language :: Python :: 3.12
|
|
14
14
|
Classifier: Programming Language :: Python :: 3.13
|
|
15
15
|
Requires-Dist: dash-cytoscape (>=1.0.2,<2.0)
|
|
16
|
-
Requires-Dist: eflips-model (>=3.0.0,<
|
|
16
|
+
Requires-Dist: eflips-model (>=3.0.0,<11.0.0)
|
|
17
17
|
Requires-Dist: eflips-schedule-rust (>=2.0.1,<3.0)
|
|
18
18
|
Requires-Dist: gurobipy (>=12.0.1,<13.0)
|
|
19
19
|
Requires-Dist: kaleido (==0.2.1)
|
|
@@ -22,8 +22,9 @@ from eflips.model import (
|
|
|
22
22
|
Event,
|
|
23
23
|
Vehicle,
|
|
24
24
|
)
|
|
25
|
-
from geoalchemy2.shape import to_shape
|
|
25
|
+
from geoalchemy2.shape import to_shape, from_shape
|
|
26
26
|
from pyomo.common.timing import report_timing # type: ignore
|
|
27
|
+
from shapely import Point # type: ignore
|
|
27
28
|
|
|
28
29
|
from eflips.opt.util import (
|
|
29
30
|
get_vehicletype,
|
|
@@ -484,7 +485,9 @@ class DepotRotationOptimizer:
|
|
|
484
485
|
new_depot_station = Station(
|
|
485
486
|
name=depot["name"],
|
|
486
487
|
scenario_id=self.scenario_id,
|
|
487
|
-
geom=
|
|
488
|
+
geom=from_shape(
|
|
489
|
+
Point(depot["depot_station"][0], depot["depot_station"][1])
|
|
490
|
+
),
|
|
488
491
|
is_electrified=False, # TODO Hardcoded for now
|
|
489
492
|
)
|
|
490
493
|
self.session.add(new_depot_station)
|
|
@@ -499,7 +502,6 @@ class DepotRotationOptimizer:
|
|
|
499
502
|
|
|
500
503
|
assert isinstance(new_assign, pd.DataFrame), "Result data should be a DataFrame"
|
|
501
504
|
for row in new_assign.itertuples():
|
|
502
|
-
|
|
503
505
|
# Add depot if it is a new depot, else get the depot station id
|
|
504
506
|
if isinstance(depot_from_user[row.new_depot_id]["depot_station"], Tuple): # type: ignore
|
|
505
507
|
# newly added depot
|
|
@@ -208,6 +208,12 @@ class SmartChargingEvent:
|
|
|
208
208
|
socs_list = list(socs)
|
|
209
209
|
socs_float_list = [float(s) for s in socs]
|
|
210
210
|
|
|
211
|
+
# Handling rounding errors
|
|
212
|
+
|
|
213
|
+
for soc in socs_float_list:
|
|
214
|
+
if soc > 1.0 and soc - 1.0 < 1e-6:
|
|
215
|
+
socs_float_list[socs_float_list.index(soc)] = 1.0
|
|
216
|
+
|
|
211
217
|
# Create timeseries dictionary and update event
|
|
212
218
|
tz = time_step_starts[0].tzinfo
|
|
213
219
|
times_datetime = [datetime.fromtimestamp(t, tz) for t in times]
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "eflips-opt"
|
|
3
|
-
version = "0.3.
|
|
3
|
+
version = "0.3.4"
|
|
4
4
|
description = "A collection of pre-simulation optimization algorithms for eFLIPS."
|
|
5
5
|
authors = [
|
|
6
6
|
{ name = "Ludger Heide", email = "ludger.heide@tu-berlin.de" },
|
|
@@ -10,7 +10,7 @@ readme = "README.md"
|
|
|
10
10
|
license = "AGPLV3.md"
|
|
11
11
|
requires-python = ">=3.10, <3.14"
|
|
12
12
|
dependencies = [
|
|
13
|
-
"eflips-model (>=3.0.0, <
|
|
13
|
+
"eflips-model (>=3.0.0, <11.0.0)",
|
|
14
14
|
"pandas (>=2.1, <3.0)",
|
|
15
15
|
"shapely (>=2.0.3, <3.0)",
|
|
16
16
|
"openrouteservice (>=2.3.3, <3.0)",
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|