Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
170 commits
Select commit Hold shift + click to select a range
f8f44d5
refactor: separate classes for flow and stock commitments
Flix6x Dec 27, 2024
96f040c
feat: set up stock commitment for breaching soc-minima and soc-maxima
Flix6x Dec 27, 2024
e893cfe
fix: remove hard constraints when moving to soft constraint
Flix6x Dec 27, 2024
67921dd
feat: take into account StockCommitment
Flix6x Dec 28, 2024
aae0bbf
fix: apply StockCommitment to device 0
Flix6x Dec 28, 2024
9eb4a36
fix: comparison and skipping of constraint
Flix6x Dec 28, 2024
0957f16
assign deviations from stock position to variable
Tammevesky Dec 31, 2024
19d6406
fix: minor fixes to StockCommitment handling
Tammevesky Jan 3, 2025
9819cc4
Merge remote-tracking branch 'refs/remotes/origin/main' into feature/…
Flix6x Jan 13, 2025
6edaac5
feat: expose new field flex-model fields
Flix6x Jan 13, 2025
1be3431
feat: move price fields to flex-context
Flix6x Jan 13, 2025
e87a1dc
feat: check compatibility of price units
Flix6x Jan 13, 2025
25d21e0
fix: param explanation
Flix6x Jan 13, 2025
b17ca05
docs: add note regarding how the SoC breach price depends on the sens…
Flix6x Jan 13, 2025
e619a96
docs: add documentation for new fields
Flix6x Jan 13, 2025
569e2e5
fix: example calculation
Flix6x Jan 14, 2025
92318a1
fix: wrong indentation
Flix6x Jan 18, 2025
c191a77
fix: return NaN quantity in the correct units in case of a missing fa…
Flix6x Jan 21, 2025
2af3660
Merge remote-tracking branch 'refs/remotes/origin/main' into feature/…
Flix6x Feb 7, 2025
2343a59
Merge remote-tracking branch 'refs/remotes/origin/main' into feature/…
Flix6x Feb 25, 2025
3f213dc
Merge remote-tracking branch 'refs/remotes/origin/main' into feature/…
Flix6x Feb 25, 2025
c60b808
dev: test StockCommitment in simultaneous scheduling
Flix6x Feb 25, 2025
8f747da
Merge remote-tracking branch 'refs/remotes/origin/main' into feature/…
Flix6x Mar 4, 2025
5eafcf2
Merge remote-tracking branch 'refs/remotes/origin/main' into feature/…
Flix6x Mar 5, 2025
ec63bb6
fix: merge conflicts relating to soc_maxima/minima for multiple devices
Flix6x Mar 6, 2025
6f8e689
fix: failing test (also due to a mistake in resolving merge conflicts)
Flix6x Mar 6, 2025
875e953
docs: note cheap times relevant in test
Flix6x Mar 6, 2025
cec2966
feat: test SoC relaxation in sequential scheduling
Flix6x Mar 6, 2025
200b598
refactor: enumerate using d rather than i
Flix6x Mar 6, 2025
3d1c999
docs: clarifying comment
Flix6x Mar 6, 2025
8830b8d
refactor: move reused functions to utils
Flix6x Mar 6, 2025
10d46c6
fix: Pyomo deprecation
Flix6x Mar 6, 2025
ad100be
fix: Pandas FutureWarning
Flix6x Mar 6, 2025
79172a1
refactor: util function to compute stock change
Flix6x Mar 6, 2025
cc72bf8
refactor: move reused functions to utils
Flix6x Mar 6, 2025
bbeba98
fix: ensure type of commitment is known
Flix6x Mar 6, 2025
9c38cbf
fix: test case
Flix6x Mar 6, 2025
118b759
refactor: use loc
Flix6x Mar 6, 2025
852cced
docs: clarifying comment
Flix6x Mar 6, 2025
7fa10cb
feat: check termination condition of solver
Flix6x Mar 6, 2025
fb05ba1
fix(docs): correct docstring
Flix6x Mar 6, 2025
6ad0a4e
fix: pass the right commitments
Flix6x Mar 6, 2025
2a2e649
Merge remote-tracking branch 'refs/remotes/origin/main' into feature/…
Flix6x Mar 7, 2025
2ff191f
fix: correct device number in case of sequential scheduling
Flix6x Mar 7, 2025
82d0a40
dev: ugly fix
Flix6x Mar 7, 2025
debf61a
fix: revise tests
Flix6x Mar 7, 2025
88b7e4d
fix: use temporary variables
Flix6x Mar 7, 2025
d6f9c1b
feat: swap assert statements to check total costs first and distribut…
Flix6x Mar 10, 2025
df46542
Merge remote-tracking branch 'refs/remotes/origin/main' into feature/…
Flix6x Mar 11, 2025
34eb6e9
dev: fix broken downgrade
Flix6x Feb 20, 2025
8c54094
fix: only add storage constraints in case we know a soc_at_start (som…
Flix6x Mar 12, 2025
1d0471d
feat: optional soc-at-start
Flix6x Mar 12, 2025
5571805
dev: add todo
Flix6x Mar 12, 2025
f9758fe
refactor: prefer kwargs
Flix6x Mar 12, 2025
21b17ec
feat: allow passing capacity sensors with negative values, which we'l…
Flix6x Mar 12, 2025
7026eee
refactor: field guaranteed to exist at this point
Flix6x Mar 16, 2025
8cdf2c8
refactor: get unit from variable quantity
Flix6x Mar 16, 2025
ac784e8
feat: add test case for a time series specification of prices with di…
Flix6x Mar 16, 2025
127b701
refactor: let NotImplementedError reference field name rather than va…
Flix6x Mar 16, 2025
ebc07db
refactor: move util function from schema to field
Flix6x Mar 16, 2025
3272963
refactor: remove redundant function argument
Flix6x Mar 16, 2025
597c36d
refactor: spell correct util function
Flix6x Mar 16, 2025
42d9c86
refactor: reuse existing superior util function to get the unit from …
Flix6x Mar 16, 2025
a73b32c
fix: remove dev comment
Flix6x Mar 16, 2025
e6b4e8f
refactor: vectorize operation
Flix6x Mar 17, 2025
7779f8b
refactor: compare class rather than name
Flix6x Mar 17, 2025
499ef7e
docs: API changelog entry
Flix6x Mar 17, 2025
51f72b0
docs: main changelog entry
Flix6x Mar 17, 2025
8952242
feat: add support for device flow commitment in device_scheduler
Flix6x Mar 17, 2025
9a2a1a7
feat: prefer curtailing later
Flix6x Mar 17, 2025
381d617
fix: support for device flow commitments in StorageScheduler
Flix6x Mar 17, 2025
28f5606
docs: document new flex-model field
Flix6x Mar 17, 2025
e4bd6b1
Merge remote-tracking branch 'refs/remotes/origin/main' into feature/…
Flix6x Mar 19, 2025
1839647
refactor: simplify get arguments
Flix6x Mar 19, 2025
837a9f4
revert: revisions accidentally committed in 8952242e43233cca8b87e6eb9…
Flix6x Mar 19, 2025
c90c3fd
docs: comment another section of flex-context prices
Flix6x Mar 19, 2025
0e2651d
dev: add undocumented relax-soc-constraints field
Flix6x Mar 19, 2025
c187f81
fix: use of temporary variables started in 88b7e4dfe396dd6d9031b78aa7…
Flix6x Mar 19, 2025
7c164b2
Revert "fix: use of temporary variables started in 88b7e4dfe396dd6d90…
Flix6x Mar 19, 2025
5c0c02d
fix: make util function robust against redundancy
Flix6x Mar 19, 2025
fd617d9
fix: apply soc-breach commitments to each timeslot
Flix6x Mar 19, 2025
96e3c8f
refactor: split up lines (yielding smaller git diffs, which are faste…
Flix6x Mar 20, 2025
727d1f3
docs: clarify comment
Flix6x Mar 20, 2025
3feed8e
fix: remove outdated comment
Flix6x Mar 20, 2025
58f5bba
docs: improve legibility (and split lines)
Flix6x Mar 20, 2025
b4cc42e
docs: no over-capitalization in titles
Flix6x Mar 20, 2025
37db627
docs: missing space
Flix6x Mar 20, 2025
f92ccdd
fix: missing column in commitment frame for device flow commitments
Flix6x Mar 20, 2025
c793705
fix: stock commitment quantities are with respect to soc at start
Flix6x Mar 20, 2025
361b3e7
fix: shift commitment quantities
Flix6x Mar 21, 2025
a61cc22
fix: skip setup of device stock commitment in case of no commitment q…
Flix6x Mar 21, 2025
7211d0a
fix: take into account difference between commitment resolution and a…
Flix6x Mar 21, 2025
124fc3d
fix: avoid adjusting the timing of SoC time series segments
Flix6x Mar 21, 2025
960de3f
Merge remote-tracking branch 'refs/remotes/origin/main' into feature/…
Flix6x Mar 25, 2025
036f54d
feat: move to a price unit that make costs independent of sensor reso…
Flix6x Mar 25, 2025
af8b57b
docs: update note on soc breach prices
Flix6x Mar 25, 2025
3d3af94
docs: fix punctuation
Flix6x Mar 26, 2025
41ecc75
style: improve IDE tooltip hints with changing to a different docstri…
Flix6x Mar 26, 2025
b6b2ce3
docs: clarify semantics of index in FlowCommitment and StockCommitment
Flix6x Mar 26, 2025
f446ee6
fix: EUR/MWh/h should be interpreted as EUR/(MWh*h)
Flix6x Mar 26, 2025
ddfeb97
fix: deal with soc constraints set at the end of the scheduling horizon
Flix6x Mar 26, 2025
10418ce
feat: test soc-minima-breach-price field
Flix6x Mar 26, 2025
c7110be
feat: scheduler also returns the units of schedules (better safe than…
Flix6x Mar 26, 2025
a3263dd
refactor: clarify purpose of variable by renaming
Flix6x Mar 26, 2025
75f5007
feat: return costs unit
Flix6x Mar 26, 2025
0e574b1
fix: alignment of SoC constraints
Flix6x Mar 27, 2025
9e7fa45
fix: compute currency unit by dividing over (1 over) the expected den…
Flix6x Mar 28, 2025
b0e2b45
fix: adapt test
Flix6x Mar 28, 2025
60a773c
feat: expand test
Flix6x Mar 28, 2025
999d76a
fix: previous expansion of test (still required a shift, which became…
Flix6x Mar 28, 2025
d3f9f1a
Merge remote-tracking branch 'refs/remotes/origin/main' into feature/…
Flix6x Mar 28, 2025
252f1a5
Merge remote-tracking branch 'refs/remotes/origin/main' into feature/…
Flix6x Mar 31, 2025
ca45058
fix: resolve pet peeve: -0.0 after integration
Flix6x Mar 31, 2025
2fe1b1d
feat: relax consumption-capacity and production-capacity using a Flow…
Flix6x Mar 31, 2025
fd217c6
Merge remote-tracking branch 'refs/remotes/origin/main' into feature/…
Flix6x Apr 3, 2025
4ffe55c
Merge branch 'refs/heads/main' into feature/relax-device-power-constr…
Flix6x Apr 7, 2025
3f442e9
fix: correct inline comment
Flix6x Apr 8, 2025
bddf629
dev: field to switch on device capacity constraint relaxation
Flix6x Apr 8, 2025
a1169a2
fix: default prices should use the same denominator as defined in the…
Flix6x Apr 8, 2025
fd139dd
fix: implement todos to not rely on a currency assumption
Flix6x Apr 8, 2025
2e28fca
Merge remote-tracking branch 'refs/remotes/origin/main' into feature/…
Flix6x Apr 8, 2025
bd4b35d
fix: last 3 prices were NaN after resampling from 1 hour to 15 minutes
Flix6x Apr 2, 2025
22ac6a7
refactor: check total costs first, then its breakdown
Flix6x Apr 2, 2025
1ce9253
fix: update expected costs
Flix6x Apr 2, 2025
b515203
fix: grammar
Flix6x Apr 2, 2025
f142322
fix: € currency symbols preceeds the value
Flix6x Apr 2, 2025
0f53763
fix: downsample rather than upsample to compute costs
Flix6x Apr 2, 2025
67b5d80
docs: main changelog entry
Flix6x Apr 8, 2025
40d309c
docs: API changelog entry
Flix6x Apr 8, 2025
6fae804
fix: correct units in changelog documentation of soc-breach-prices
Flix6x Apr 8, 2025
7fe0455
fix: correct units in changelog documentation of device-level power-b…
Flix6x Apr 8, 2025
f84d150
Merge remote-tracking branch 'refs/remotes/origin/main' into feature/…
Flix6x Apr 10, 2025
b5a9764
docs: fix typo
Flix6x Apr 10, 2025
7cf7dda
feat: apply breach prices to both breach capacity and breach effort
Flix6x Apr 11, 2025
c274089
feat: apply breach prices to both SoC breach capacity and SoC breach …
Flix6x Apr 11, 2025
b3dc2c9
docs: add hint at explanation
Flix6x Apr 11, 2025
bcfb357
feat: apply breach prices to both site breach capacity and site breac…
Flix6x Apr 11, 2025
12e5cd6
docs: update explanation of breach prices
Flix6x Apr 11, 2025
0d1e032
docs: add documentation for the two new breach-prices
Flix6x Apr 11, 2025
2a14a92
fix: check on costs of "all consumption breaches"
Flix6x Apr 11, 2025
b04ae93
fix: move changelog item for SoC relaxation to the correct release ve…
Flix6x Apr 11, 2025
4a9d131
Merge remote-tracking branch 'refs/remotes/origin/main' into feature/…
Flix6x Apr 16, 2025
a7bb880
Merge remote-tracking branch 'refs/remotes/origin/main' into feature/…
Flix6x Apr 18, 2025
0369bec
docs: fix sign explanation in comments
Flix6x Apr 18, 2025
1275fdb
refactor: simplify default price declarations
Flix6x Apr 18, 2025
23e25b4
refactor: merge logic using for-loop
Flix6x Apr 18, 2025
7faf8a0
refactor: move setting default prices into a single function
Flix6x Apr 18, 2025
8aee391
refactor: series_to_ts_specs util function
Flix6x Apr 18, 2025
1d25d2e
docs: add clarifying note to docstring of new util function
Flix6x Apr 18, 2025
e9cf3d0
refactor: prepare to use new FlexContextTimeSeriesSchema for loading …
Flix6x Apr 21, 2025
ea79830
refactor: move consumption_breach_price loading to schema
Flix6x Apr 21, 2025
df24453
refactor: move production_breach_price loading to schema
Flix6x Apr 21, 2025
3ba3af0
refactor: move soc_maxima_breach_price loading to schema
Flix6x Apr 21, 2025
e3c4a51
refactor: move soc_minima_breach_price loading to schema
Flix6x Apr 21, 2025
1e01ee3
refactor: move ems_consumption_breach_price and ems_production_breach…
Flix6x Apr 21, 2025
e521c7b
refactor: move ems_peak_consumption_price and ems_peak_production_pri…
Flix6x Apr 21, 2025
de936c7
refactor: move consumption_price and production_price loading to schema
Flix6x Apr 21, 2025
f09bd7f
fix: type annotation
Flix6x Apr 22, 2025
0284f39
fix: compatibility with deprecated flex-context fields
Flix6x Apr 22, 2025
15520c0
fix: don't override field, just override field attribute to load the …
Flix6x Apr 22, 2025
a3b9811
refactor: move ems_power_capacity_in_mw, ems_consumption_capacity_in_…
Flix6x Apr 22, 2025
a7a5e75
fix: determine resolution for loading time series data after deserial…
Flix6x Apr 22, 2025
28389ce
Revert "refactor: move ems_power_capacity_in_mw, ems_consumption_capa…
Flix6x Apr 22, 2025
512e754
refactor: move ems_power_capacity_in_mw, ems_consumption_capacity_in_…
Flix6x Apr 22, 2025
bb33411
refactor: use walrus operator
Flix6x Apr 22, 2025
380623d
refactor: move ems_peak_consumption_in_mw and ems_peak_production_in_…
Flix6x Apr 22, 2025
c0acafe
refactor: clean up after moving every VariableQuantityField in the fl…
Flix6x Apr 22, 2025
2093a0b
fix: bug resolved in https://github.com/FlexMeasures/flexmeasures/pul…
Flix6x Apr 22, 2025
d7fd925
Merge remote-tracking branch 'refs/remotes/origin/main' into refactor…
Flix6x Apr 22, 2025
fbd971c
style: black
Flix6x Apr 22, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions flexmeasures/data/models/planning/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ class Scheduler:
start: datetime
end: datetime
resolution: timedelta
load_resolution: timedelta
belief_time: datetime

round_to_decimals: int
Expand Down Expand Up @@ -74,6 +75,7 @@ def __init__(
flex_model: dict | None = None,
flex_context: dict | None = None,
return_multiple: bool = False,
load_time_series: bool = True,
):
"""
Initialize a new Scheduler.
Expand Down Expand Up @@ -113,6 +115,7 @@ def __init__(
self.start = start
self.end = end
self.resolution = resolution
self.load_resolution = resolution
self.belief_time = belief_time
self.round_to_decimals = round_to_decimals
if flex_model is None:
Expand All @@ -126,6 +129,7 @@ def __init__(
self.info = dict(scheduler=self.__class__.__name__)

self.return_multiple = return_multiple
self.load_time_series = load_time_series

def compute_schedule(self) -> pd.Series | None:
"""
Expand Down
Loading
Loading