Skip to content

Commit

Permalink
refactor: change from rate_sm3_day to rate for dto
Browse files Browse the repository at this point in the history
  • Loading branch information
frodehk committed Sep 19, 2023
1 parent 3a8b9ec commit 9df244c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/libecalc/core/graph_result.py
Original file line number Diff line number Diff line change
Expand Up @@ -296,7 +296,7 @@ def get_asset_result(self) -> libecalc.dto.result.EcalcModelResult:
unit=Unit.BARA,
).for_period(period=period)

rate_sm3_day = TimeSeriesRate(
rate = TimeSeriesRate(
timesteps=model.timesteps,
values=model.rate_sm3_day,
unit=Unit.STANDARD_CUBIC_METER_PER_DAY,
Expand Down Expand Up @@ -413,7 +413,7 @@ def get_asset_result(self) -> libecalc.dto.result.EcalcModelResult:
energy_usage_unit=model.energy_usage_unit,
requested_inlet_pressure=requested_inlet_pressure,
requested_outlet_pressure=requested_outlet_pressure,
rate_sm3_day=rate_sm3_day,
rate=rate,
stage_results=model.stage_results,
failure_status=model.failure_status,
timesteps=model.timesteps,
Expand Down
3 changes: 1 addition & 2 deletions src/libecalc/dto/result/results.py
Original file line number Diff line number Diff line change
Expand Up @@ -143,11 +143,10 @@ class PumpModelResult(ConsumerModelResultBase):

class CompressorModelResult(ConsumerModelResultBase):
componentType: Literal[ComponentType.COMPRESSOR]
# max_standard_rate: Optional[Union[List[Optional[float]], List[List[Optional[float]]]]]
failure_status: List[Optional[CompressorTrainCommonShaftFailureStatus]]
requested_inlet_pressure: TimeSeriesFloat
requested_outlet_pressure: TimeSeriesFloat
rate_sm3_day: TimeSeriesRate
rate: TimeSeriesRate
stage_results: List[CompressorStageResult]
turbine_result: Optional[TurbineResult] = None
energy_usage_unit: Unit
Expand Down

0 comments on commit 9df244c

Please sign in to comment.