Skip to content

Commit

Permalink
refactor: move inline todo remark
Browse files Browse the repository at this point in the history
Signed-off-by: F.N. Claessen <felix@seita.nl>
  • Loading branch information
Flix6x committed Jun 17, 2024
1 parent 4279e54 commit d8e1676
Showing 1 changed file with 3 additions and 7 deletions.
10 changes: 3 additions & 7 deletions flexmeasures/data/models/planning/linear_optimization.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ def device_scheduler( # noqa C901
commitment_upwards_deviation_price: list[pd.Series] | list[float],
initial_stock: float = 0,
relaxed: bool = False,
relaxation_cost: float = 20000,
relaxation_cost: float = 20000, # TODO: compute this value based on input data
) -> tuple[list[pd.Series], float, SolverResults, ConcreteModel]:
"""This generic device scheduler is able to handle an EMS with multiple devices,
with various types of constraints on the EMS level and on the device level,
Expand Down Expand Up @@ -408,12 +408,8 @@ def cost_function(m):
costs += m.commitment_upwards_deviation[c, j] * m.up_price[c, j]

if relaxed:
costs += (
m.ems_power_slack_upper * relaxation_cost
) # TODO: compute this value based on input dat
costs += (
m.ems_power_slack_lower * relaxation_cost
) # TODO: compute this value based on input dat
costs += m.ems_power_slack_upper * relaxation_cost
costs += m.ems_power_slack_lower * relaxation_cost

return costs

Expand Down

0 comments on commit d8e1676

Please sign in to comment.