Skip to content

Conversation

@FBumann
Copy link
Member

@FBumann FBumann commented Apr 10, 2025

Encapsulate Functionality of OnOffModel into smaller Models

The OnOffModel is split-up into 3 smaller Models:
**StateModel, SwitchStateModel and ConsecutiveStateModel
The OnOffModel now simply uses all of these Models.
This greatly improves both readability and modularity of the classes.
Further, **StateModel, SwitchStateModel and ConsecutiveStateModel are decoupled from OnOffParameters, so they can be used on other contexts as well.
This will become especially relevant with the upcoming scenarios update #212

@FBumann FBumann requested review from PStange and baumbude April 10, 2025 18:43
FBumann added 3 commits April 10, 2025 20:43
# Conflicts:
#	flixopt/features.py
#	tests/test_flow.py
#	tests/test_on_hours_computation.py
@FBumann FBumann marked this pull request as ready for review April 11, 2025 13:31
@FBumann FBumann merged commit 9ed6656 into main Apr 11, 2025
7 checks passed
@FBumann FBumann deleted the feature/binary-models branch April 11, 2025 14:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants