flixopt 2.1.9__tar.gz → 2.1.11__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.
Potentially problematic release.
This version of flixopt might be problematic. Click here for more details.
- flixopt-2.1.11/CHANGELOG.md +299 -0
- flixopt-2.1.11/MANIFEST.in +26 -0
- {flixopt-2.1.9/flixopt.egg-info → flixopt-2.1.11}/PKG-INFO +4 -5
- {flixopt-2.1.9 → flixopt-2.1.11}/flixopt/components.py +1 -1
- {flixopt-2.1.9 → flixopt-2.1.11}/flixopt/flow_system.py +2 -1
- {flixopt-2.1.9 → flixopt-2.1.11}/flixopt/io.py +6 -4
- {flixopt-2.1.9 → flixopt-2.1.11}/flixopt/results.py +1 -1
- {flixopt-2.1.9 → flixopt-2.1.11/flixopt.egg-info}/PKG-INFO +4 -5
- flixopt-2.1.11/flixopt.egg-info/SOURCES.txt +31 -0
- {flixopt-2.1.9 → flixopt-2.1.11}/flixopt.egg-info/requires.txt +2 -1
- flixopt-2.1.11/flixopt.egg-info/top_level.txt +1 -0
- {flixopt-2.1.9 → flixopt-2.1.11}/pyproject.toml +18 -5
- flixopt-2.1.9/.github/CONTRIBUTING.md +0 -85
- flixopt-2.1.9/.github/ISSUE_TEMPLATE/bug_report.yml +0 -111
- flixopt-2.1.9/.github/ISSUE_TEMPLATE/config.yml +0 -14
- flixopt-2.1.9/.github/ISSUE_TEMPLATE/feature_request.yml +0 -127
- flixopt-2.1.9/.github/ISSUE_TEMPLATE/general_issue.yml +0 -40
- flixopt-2.1.9/.github/pull_request_template.md +0 -20
- flixopt-2.1.9/.github/workflows/python-app.yaml +0 -385
- flixopt-2.1.9/.gitignore +0 -10
- flixopt-2.1.9/.pre-commit-config.yaml +0 -16
- flixopt-2.1.9/CHANGELOG.md +0 -188
- flixopt-2.1.9/docs/SUMMARY.md +0 -7
- flixopt-2.1.9/docs/contribute.md +0 -45
- flixopt-2.1.9/docs/examples/00-Minimal Example.md +0 -5
- flixopt-2.1.9/docs/examples/01-Basic Example.md +0 -5
- flixopt-2.1.9/docs/examples/02-Complex Example.md +0 -10
- flixopt-2.1.9/docs/examples/03-Calculation Modes.md +0 -5
- flixopt-2.1.9/docs/examples/index.md +0 -5
- flixopt-2.1.9/docs/faq/contribute.md +0 -61
- flixopt-2.1.9/docs/faq/index.md +0 -3
- flixopt-2.1.9/docs/getting-started.md +0 -42
- flixopt-2.1.9/docs/images/architecture_flixOpt-pre2.0.0.png +0 -0
- flixopt-2.1.9/docs/images/architecture_flixOpt.png +0 -0
- flixopt-2.1.9/docs/images/flixopt-icon.svg +0 -1
- flixopt-2.1.9/docs/index.md +0 -47
- flixopt-2.1.9/docs/javascripts/mathjax.js +0 -18
- flixopt-2.1.9/docs/user-guide/Mathematical Notation/Bus.md +0 -33
- flixopt-2.1.9/docs/user-guide/Mathematical Notation/Effects, Penalty & Objective.md +0 -132
- flixopt-2.1.9/docs/user-guide/Mathematical Notation/Flow.md +0 -26
- flixopt-2.1.9/docs/user-guide/Mathematical Notation/InvestParameters.md +0 -3
- flixopt-2.1.9/docs/user-guide/Mathematical Notation/LinearConverter.md +0 -21
- flixopt-2.1.9/docs/user-guide/Mathematical Notation/OnOffParameters.md +0 -3
- flixopt-2.1.9/docs/user-guide/Mathematical Notation/Piecewise.md +0 -49
- flixopt-2.1.9/docs/user-guide/Mathematical Notation/Storage.md +0 -44
- flixopt-2.1.9/docs/user-guide/Mathematical Notation/index.md +0 -22
- flixopt-2.1.9/docs/user-guide/Mathematical Notation/others.md +0 -3
- flixopt-2.1.9/docs/user-guide/index.md +0 -124
- flixopt-2.1.9/examples/00_Minmal/minimal_example.py +0 -71
- flixopt-2.1.9/examples/01_Simple/simple_example.py +0 -119
- flixopt-2.1.9/examples/02_Complex/complex_example.py +0 -201
- flixopt-2.1.9/examples/02_Complex/complex_example_results.py +0 -34
- flixopt-2.1.9/examples/03_Calculation_types/Zeitreihen2020.csv +0 -35137
- flixopt-2.1.9/examples/03_Calculation_types/example_calculation_types.py +0 -224
- flixopt-2.1.9/flixopt.egg-info/SOURCES.txt +0 -101
- flixopt-2.1.9/flixopt.egg-info/top_level.txt +0 -6
- flixopt-2.1.9/mkdocs.yml +0 -136
- flixopt-2.1.9/pics/architecture_flixOpt-pre2.0.0.png +0 -0
- flixopt-2.1.9/pics/architecture_flixOpt.png +0 -0
- flixopt-2.1.9/pics/flixOpt_plotting.jpg +0 -0
- flixopt-2.1.9/pics/flixopt-icon.svg +0 -1
- flixopt-2.1.9/pics/pics.pptx +0 -0
- flixopt-2.1.9/renovate.json +0 -23
- flixopt-2.1.9/scripts/extract_release_notes.py +0 -45
- flixopt-2.1.9/scripts/gen_ref_pages.py +0 -54
- flixopt-2.1.9/tests/__init__.py +0 -0
- flixopt-2.1.9/tests/conftest.py +0 -508
- flixopt-2.1.9/tests/ressources/Zeitreihen2020.csv +0 -35137
- flixopt-2.1.9/tests/run_all_tests.py +0 -10
- flixopt-2.1.9/tests/test_bus.py +0 -65
- flixopt-2.1.9/tests/test_component.py +0 -202
- flixopt-2.1.9/tests/test_dataconverter.py +0 -113
- flixopt-2.1.9/tests/test_effect.py +0 -163
- flixopt-2.1.9/tests/test_examples.py +0 -49
- flixopt-2.1.9/tests/test_flow.py +0 -1156
- flixopt-2.1.9/tests/test_functional.py +0 -787
- flixopt-2.1.9/tests/test_integration.py +0 -423
- flixopt-2.1.9/tests/test_io.py +0 -64
- flixopt-2.1.9/tests/test_linear_converter.py +0 -500
- flixopt-2.1.9/tests/test_network_app.py +0 -24
- flixopt-2.1.9/tests/test_on_hours_computation.py +0 -108
- flixopt-2.1.9/tests/test_plots.py +0 -134
- flixopt-2.1.9/tests/test_results_plots.py +0 -91
- flixopt-2.1.9/tests/test_storage.py +0 -390
- flixopt-2.1.9/tests/test_timeseries.py +0 -603
- flixopt-2.1.9/tests/todos.txt +0 -5
- {flixopt-2.1.9 → flixopt-2.1.11}/LICENSE +0 -0
- {flixopt-2.1.9 → flixopt-2.1.11}/README.md +0 -0
- {flixopt-2.1.9 → flixopt-2.1.11}/flixopt/__init__.py +0 -0
- {flixopt-2.1.9 → flixopt-2.1.11}/flixopt/aggregation.py +0 -0
- {flixopt-2.1.9 → flixopt-2.1.11}/flixopt/calculation.py +0 -0
- {flixopt-2.1.9 → flixopt-2.1.11}/flixopt/commons.py +0 -0
- {flixopt-2.1.9 → flixopt-2.1.11}/flixopt/config.py +0 -0
- {flixopt-2.1.9 → flixopt-2.1.11}/flixopt/config.yaml +0 -0
- {flixopt-2.1.9 → flixopt-2.1.11}/flixopt/core.py +0 -0
- {flixopt-2.1.9 → flixopt-2.1.11}/flixopt/effects.py +0 -0
- {flixopt-2.1.9 → flixopt-2.1.11}/flixopt/elements.py +0 -0
- {flixopt-2.1.9 → flixopt-2.1.11}/flixopt/features.py +0 -0
- {flixopt-2.1.9 → flixopt-2.1.11}/flixopt/interface.py +0 -0
- {flixopt-2.1.9 → flixopt-2.1.11}/flixopt/linear_converters.py +0 -0
- {flixopt-2.1.9 → flixopt-2.1.11}/flixopt/network_app.py +0 -0
- {flixopt-2.1.9 → flixopt-2.1.11}/flixopt/plotting.py +0 -0
- {flixopt-2.1.9 → flixopt-2.1.11}/flixopt/solvers.py +0 -0
- {flixopt-2.1.9 → flixopt-2.1.11}/flixopt/structure.py +0 -0
- {flixopt-2.1.9 → flixopt-2.1.11}/flixopt/utils.py +0 -0
- {flixopt-2.1.9 → flixopt-2.1.11}/flixopt.egg-info/dependency_links.txt +0 -0
- {flixopt-2.1.9 → flixopt-2.1.11}/setup.cfg +0 -0
|
@@ -0,0 +1,299 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
4
|
+
Formatting is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) & [Gitmoji](https://gitmoji.dev).
|
|
5
|
+
For more details regarding the individual PRs and contributors, please refer to our [GitHub releases](https://github.com/flixOpt/flixopt/releases).
|
|
6
|
+
|
|
7
|
+
<!-- This text won't be rendered
|
|
8
|
+
Note: The CI will automatically append a "What's Changed" section to the changelog for github releases.
|
|
9
|
+
This contains all commits, PRs, and contributors.
|
|
10
|
+
Therefore, the Changelog should focus on the user-facing changes.
|
|
11
|
+
|
|
12
|
+
Please remove all irrelevant sections before releasing.
|
|
13
|
+
Please keep the format of the changelog consistent with the other releases, so the extraction for mkdocs works.
|
|
14
|
+
---
|
|
15
|
+
|
|
16
|
+
## [Template] - ????-??-??
|
|
17
|
+
|
|
18
|
+
### ✨ Added
|
|
19
|
+
|
|
20
|
+
### 💥 Breaking Changes
|
|
21
|
+
|
|
22
|
+
### ♻️ Changed
|
|
23
|
+
|
|
24
|
+
### 🗑️ Deprecated
|
|
25
|
+
|
|
26
|
+
### 🔥 Removed
|
|
27
|
+
|
|
28
|
+
### 🐛 Fixed
|
|
29
|
+
|
|
30
|
+
### 🔒 Security
|
|
31
|
+
|
|
32
|
+
### 📦 Dependencies
|
|
33
|
+
|
|
34
|
+
### 📝 Docs
|
|
35
|
+
|
|
36
|
+
### 👷 Development
|
|
37
|
+
|
|
38
|
+
### 🚧 Known Issues
|
|
39
|
+
|
|
40
|
+
---
|
|
41
|
+
|
|
42
|
+
## [Unreleased] - ????-??-??
|
|
43
|
+
|
|
44
|
+
### ✨ Added
|
|
45
|
+
|
|
46
|
+
### 💥 Breaking Changes
|
|
47
|
+
|
|
48
|
+
### ♻️ Changed
|
|
49
|
+
- Using `h5netcdf` instead of `netCDF4` for dataset I/O operations. This follows the update in `xarray==2025.09.01`
|
|
50
|
+
|
|
51
|
+
### 🗑️ Deprecated
|
|
52
|
+
|
|
53
|
+
### 🔥 Removed
|
|
54
|
+
|
|
55
|
+
### 🐛 Fixed
|
|
56
|
+
|
|
57
|
+
### 🔒 Security
|
|
58
|
+
|
|
59
|
+
### 📦 Dependencies
|
|
60
|
+
|
|
61
|
+
### 📝 Docs
|
|
62
|
+
|
|
63
|
+
### 👷 Development
|
|
64
|
+
|
|
65
|
+
### 🚧 Known Issues
|
|
66
|
+
|
|
67
|
+
Until here -->
|
|
68
|
+
---
|
|
69
|
+
|
|
70
|
+
## [2.1.11] - 2025-10-05
|
|
71
|
+
**Summary:** Important bugfix in `Storage` leading to wrong results due to incorrect discharge losses.
|
|
72
|
+
|
|
73
|
+
### ♻️ Changed
|
|
74
|
+
- Using `h5netcdf` instead of `netCDF4` for dataset I/O operations. This follows the update in `xarray==2025.09.01`
|
|
75
|
+
|
|
76
|
+
### 🐛 Fixed
|
|
77
|
+
- Fix `charge_state` Constraint in `Storage` leading to incorrect losses in discharge and therefore incorrect charge states and discharge values.
|
|
78
|
+
|
|
79
|
+
### 📦 Dependencies
|
|
80
|
+
- Updated `renovate.config` to treat CalVer packages (xarray and dask) with more care
|
|
81
|
+
|
|
82
|
+
---
|
|
83
|
+
|
|
84
|
+
## [2.1.10] - 2025-09-29
|
|
85
|
+
**Summary:** This release is a Documentation and Development release.
|
|
86
|
+
|
|
87
|
+
### 📝 Docs
|
|
88
|
+
- Improved CHANGELOG.md formatting by adding better categories and formating by Gitmoji.
|
|
89
|
+
- Added a script to extract the release notes from the CHANGELOG.md file for better organized documentation.
|
|
90
|
+
|
|
91
|
+
### 👷 Development
|
|
92
|
+
- Improved `renovate.config`
|
|
93
|
+
- Sped up CI by not running examples in every run and using `pytest-xdist`
|
|
94
|
+
|
|
95
|
+
---
|
|
96
|
+
|
|
97
|
+
## [2.1.9] - 2025-09-23
|
|
98
|
+
|
|
99
|
+
**Summary:** Small bugfix release addressing network visualization error handling.
|
|
100
|
+
|
|
101
|
+
### 🐛 Fixed
|
|
102
|
+
- Fix error handling in network visualization if `networkx` is not installed
|
|
103
|
+
|
|
104
|
+
---
|
|
105
|
+
|
|
106
|
+
## [2.1.8] - 2025-09-22
|
|
107
|
+
|
|
108
|
+
**Summary:** Code quality improvements, enhanced documentation, and bug fixes for heat pump components and visualization features.
|
|
109
|
+
|
|
110
|
+
### ✨ Added
|
|
111
|
+
- Extra Check for HeatPumpWithSource.COP to be strictly > 1 to avoid division by zero
|
|
112
|
+
- Apply deterministic color assignment by using sorted() in `plotting.py`
|
|
113
|
+
- Add missing args in docstrings in `plotting.py`, `solvers.py`, and `core.py`.
|
|
114
|
+
|
|
115
|
+
### ♻️ Changed
|
|
116
|
+
- Greatly improved docstrings and documentation of all public classes
|
|
117
|
+
- Make path handling to be gentle about missing .html suffix in `plotting.py`
|
|
118
|
+
- Default for `relative_losses` in `Transmission` is now 0 instead of None
|
|
119
|
+
- Setter of COP in `HeatPumpWithSource` now completely overwrites the conversion factors, which is safer.
|
|
120
|
+
- Fix some docstrings in plotting.py
|
|
121
|
+
- Change assertions to raise Exceptions in `plotting.py`
|
|
122
|
+
|
|
123
|
+
### 🐛 Fixed
|
|
124
|
+
|
|
125
|
+
**Core Components:**
|
|
126
|
+
- Fix COP getter and setter of `HeatPumpWithSource` returning and setting wrong conversion factors
|
|
127
|
+
- Fix custom compression levels in `io.save_dataset_to_netcdf`
|
|
128
|
+
- Fix `total_max` did not work when total min was not used
|
|
129
|
+
|
|
130
|
+
**Visualization:**
|
|
131
|
+
- Fix color scheme selection in network_app; color pickers now update when a scheme is selected
|
|
132
|
+
|
|
133
|
+
### 📝 Docs
|
|
134
|
+
- Fix broken links in docs
|
|
135
|
+
- Fix some docstrings in plotting.py
|
|
136
|
+
|
|
137
|
+
### 👷 Development
|
|
138
|
+
- Pin dev dependencies to specific versions
|
|
139
|
+
- Improve CI workflows to run faster and smarter
|
|
140
|
+
|
|
141
|
+
---
|
|
142
|
+
|
|
143
|
+
## [2.1.7] - 2025-09-13
|
|
144
|
+
|
|
145
|
+
**Summary:** Maintenance release to improve Code Quality, CI and update the dependencies. There are no changes or new features.
|
|
146
|
+
|
|
147
|
+
### ✨ Added
|
|
148
|
+
- Added `__version__` to flixopt
|
|
149
|
+
|
|
150
|
+
### 👷 Development
|
|
151
|
+
- ruff format the whole Codebase
|
|
152
|
+
- Added renovate config
|
|
153
|
+
- Added pre-commit
|
|
154
|
+
- lint and format in CI
|
|
155
|
+
- improved CI
|
|
156
|
+
- Updated Dependencies
|
|
157
|
+
- Updated Issue Templates
|
|
158
|
+
|
|
159
|
+
---
|
|
160
|
+
|
|
161
|
+
## [2.1.6] - 2025-09-02
|
|
162
|
+
|
|
163
|
+
**Summary:** Enhanced Sink/Source components with multi-flow support and new interactive network visualization.
|
|
164
|
+
|
|
165
|
+
### ✨ Added
|
|
166
|
+
- **Network Visualization**: Added `FlowSystem.start_network_app()` and `FlowSystem.stop_network_app()` to easily visualize the network structure of a flow system in an interactive Dash web app
|
|
167
|
+
- *Note: This is still experimental and might change in the future*
|
|
168
|
+
|
|
169
|
+
### ♻️ Changed
|
|
170
|
+
- **Multi-Flow Support**: `Sink`, `Source`, and `SourceAndSink` now accept multiple `flows` as `inputs` and `outputs` instead of just one. This enables modeling more use cases with these classes
|
|
171
|
+
- **Flow Control**: Both `Sink` and `Source` now have a `prevent_simultaneous_flow_rates` argument to prevent simultaneous flow rates of more than one of their flows
|
|
172
|
+
|
|
173
|
+
### 🗑️ Deprecated
|
|
174
|
+
- For the classes `Sink`, `Source` and `SourceAndSink`: `.sink`, `.source` and `.prevent_simultaneous_sink_and_source` are deprecated in favor of the new arguments `inputs`, `outputs` and `prevent_simultaneous_flow_rates`
|
|
175
|
+
|
|
176
|
+
### 🐛 Fixed
|
|
177
|
+
- Fixed testing issue with new `linopy` version 0.5.6
|
|
178
|
+
|
|
179
|
+
### 👷 Development
|
|
180
|
+
- Added dependency "nbformat>=4.2.0" to dev dependencies to resolve issue with plotly CI
|
|
181
|
+
|
|
182
|
+
---
|
|
183
|
+
|
|
184
|
+
## [2.1.5] - 2025-07-08
|
|
185
|
+
|
|
186
|
+
### 🐛 Fixed
|
|
187
|
+
- Fixed Docs deployment
|
|
188
|
+
|
|
189
|
+
---
|
|
190
|
+
|
|
191
|
+
## [2.1.4] - 2025-07-08
|
|
192
|
+
|
|
193
|
+
### 🐛 Fixed
|
|
194
|
+
- Fixing release notes of 2.1.3, as well as documentation build.
|
|
195
|
+
|
|
196
|
+
---
|
|
197
|
+
|
|
198
|
+
## [2.1.3] - 2025-07-08
|
|
199
|
+
|
|
200
|
+
### 🐛 Fixed
|
|
201
|
+
- Using `Effect.maximum_operation_per_hour` raised an error, needing an extra timestep. This has been fixed thanks to @PRse4.
|
|
202
|
+
|
|
203
|
+
---
|
|
204
|
+
|
|
205
|
+
## [2.1.2] - 2025-06-14
|
|
206
|
+
|
|
207
|
+
### 🐛 Fixed
|
|
208
|
+
- Storage losses per hour were not calculated correctly, as mentioned by @brokenwings01. This might have led to issues when modeling large losses and long timesteps.
|
|
209
|
+
- Old implementation: $c(\text{t}_{i}) \cdot (1-\dot{\text{c}}_\text{rel,loss}(\text{t}_i)) \cdot \Delta \text{t}_{i}$
|
|
210
|
+
- Correct implementation: $c(\text{t}_{i}) \cdot (1-\dot{\text{c}}_\text{rel,loss}(\text{t}_i)) ^{\Delta \text{t}_{i}}$
|
|
211
|
+
|
|
212
|
+
### 🚧 Known Issues
|
|
213
|
+
- Just to mention: Plotly >= 6 may raise errors if "nbformat" is not installed. We pinned plotly to <6, but this may be fixed in the future.
|
|
214
|
+
|
|
215
|
+
---
|
|
216
|
+
|
|
217
|
+
## [2.1.1] - 2025-05-08
|
|
218
|
+
|
|
219
|
+
### ♻️ Changed
|
|
220
|
+
- Improved docstring and tests
|
|
221
|
+
|
|
222
|
+
### 🐛 Fixed
|
|
223
|
+
- Fixed bug in the `_ElementResults.constraints` not returning the constraints but rather the variables
|
|
224
|
+
|
|
225
|
+
---
|
|
226
|
+
## [2.1.0] - 2025-04-11
|
|
227
|
+
|
|
228
|
+
### ✨ Added
|
|
229
|
+
- Python 3.13 support added
|
|
230
|
+
- Logger warning if relative_minimum is used without on_off_parameters in Flow
|
|
231
|
+
- Greatly improved internal testing infrastructure by leveraging linopy's testing framework
|
|
232
|
+
|
|
233
|
+
### 💥 Breaking Changes
|
|
234
|
+
- Restructured the modeling of the On/Off state of Flows or Components
|
|
235
|
+
- Variable renaming: `...|consecutive_on_hours` → `...|ConsecutiveOn|hours`
|
|
236
|
+
- Variable renaming: `...|consecutive_off_hours` → `...|ConsecutiveOff|hours`
|
|
237
|
+
- Constraint renaming: `...|consecutive_on_hours_con1` → `...|ConsecutiveOn|con1`
|
|
238
|
+
- Similar pattern for all consecutive on/off constraints
|
|
239
|
+
|
|
240
|
+
### 🐛 Fixed
|
|
241
|
+
- Fixed the lower bound of `flow_rate` when using optional investments without OnOffParameters
|
|
242
|
+
- Fixed bug that prevented divest effects from working
|
|
243
|
+
- Added lower bounds of 0 to two unbounded vars (numerical improvement)
|
|
244
|
+
|
|
245
|
+
---
|
|
246
|
+
|
|
247
|
+
## [2.0.1] - 2025-04-10
|
|
248
|
+
|
|
249
|
+
### ✨ Added
|
|
250
|
+
- Logger warning if relative_minimum is used without on_off_parameters in Flow
|
|
251
|
+
|
|
252
|
+
### 🐛 Fixed
|
|
253
|
+
- Replace "|" with "__" in filenames when saving figures (Windows compatibility)
|
|
254
|
+
- Fixed bug that prevented the load factor from working without InvestmentParameters
|
|
255
|
+
|
|
256
|
+
## [2.0.0] - 2025-03-29
|
|
257
|
+
|
|
258
|
+
**Summary:** 💥 **MAJOR RELEASE** - Complete framework migration from Pyomo to Linopy with redesigned architecture.
|
|
259
|
+
|
|
260
|
+
### ✨ Added
|
|
261
|
+
|
|
262
|
+
**Model Capabilities:**
|
|
263
|
+
- Full model serialization support - save and restore unsolved Models
|
|
264
|
+
- Enhanced model documentation with YAML export containing human-readable mathematical formulations
|
|
265
|
+
- Extend flixopt models with native linopy language support
|
|
266
|
+
- Full Model Export/Import capabilities via linopy.Model
|
|
267
|
+
|
|
268
|
+
**Results & Data:**
|
|
269
|
+
- Unified solution exploration through `Calculation.results` attribute
|
|
270
|
+
- Compression support for result files
|
|
271
|
+
- `to_netcdf/from_netcdf` methods for FlowSystem and core components
|
|
272
|
+
- xarray integration for TimeSeries with improved datatypes support
|
|
273
|
+
|
|
274
|
+
### 💥 Breaking Changes
|
|
275
|
+
|
|
276
|
+
**Framework Migration:**
|
|
277
|
+
- **Optimization Engine**: Complete migration from Pyomo to Linopy optimization framework
|
|
278
|
+
- **Package Import**: Framework renamed from flixOpt to flixopt (`import flixopt as fx`)
|
|
279
|
+
- **Data Architecture**: Redesigned data handling to rely on xarray.Dataset throughout the package
|
|
280
|
+
- **Results System**: Results handling completely redesigned with new `CalculationResults` class
|
|
281
|
+
|
|
282
|
+
**Variable Structure:**
|
|
283
|
+
- Restructured the modeling of the On/Off state of Flows or Components
|
|
284
|
+
- Variable renaming: `...|consecutive_on_hours` → `...|ConsecutiveOn|hours`
|
|
285
|
+
- Variable renaming: `...|consecutive_off_hours` → `...|ConsecutiveOff|hours`
|
|
286
|
+
- Constraint renaming: `...|consecutive_on_hours_con1` → `...|ConsecutiveOn|con1`
|
|
287
|
+
- Similar pattern for all consecutive on/off constraints
|
|
288
|
+
|
|
289
|
+
### 🔥 Removed
|
|
290
|
+
- **Pyomo dependency** (replaced by linopy)
|
|
291
|
+
- **Period concepts** in time management (simplified to timesteps)
|
|
292
|
+
|
|
293
|
+
### 🐛 Fixed
|
|
294
|
+
- Improved infeasible model detection and reporting
|
|
295
|
+
- Enhanced time series management and serialization
|
|
296
|
+
- Reduced file size through improved compression
|
|
297
|
+
|
|
298
|
+
### 📝 Docs
|
|
299
|
+
- Google Style Docstrings throughout the codebase
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
# Include essential files from source distribution
|
|
2
|
+
include LICENSE
|
|
3
|
+
include README.md
|
|
4
|
+
include CHANGELOG.md
|
|
5
|
+
include pyproject.toml
|
|
6
|
+
|
|
7
|
+
# Include package source and data
|
|
8
|
+
recursive-include flixopt *.py *.yaml
|
|
9
|
+
|
|
10
|
+
# Exclude everything else
|
|
11
|
+
global-exclude *.pyc *.pyo __pycache__
|
|
12
|
+
prune .github
|
|
13
|
+
prune docs
|
|
14
|
+
prune examples
|
|
15
|
+
prune tests
|
|
16
|
+
prune pics
|
|
17
|
+
prune scripts
|
|
18
|
+
prune build
|
|
19
|
+
prune dist
|
|
20
|
+
prune .venv
|
|
21
|
+
prune venv
|
|
22
|
+
exclude .gitignore
|
|
23
|
+
exclude .pre-commit-config.yaml
|
|
24
|
+
exclude renovate.json
|
|
25
|
+
exclude mkdocs.yml
|
|
26
|
+
exclude test_package.sh
|
|
@@ -1,16 +1,15 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: flixopt
|
|
3
|
-
Version: 2.1.
|
|
3
|
+
Version: 2.1.11
|
|
4
4
|
Summary: Vector based energy and material flow optimization framework in Python.
|
|
5
5
|
Author-email: "Chair of Building Energy Systems and Heat Supply, TU Dresden" <peter.stange@tu-dresden.de>, Felix Bumann <felixbumann387@gmail.com>, Felix Panitz <baumbude@googlemail.com>, Peter Stange <peter.stange@tu-dresden.de>
|
|
6
6
|
Maintainer-email: Felix Bumann <felixbumann387@gmail.com>, Peter Stange <peter.stange@tu-dresden.de>
|
|
7
|
-
License: MIT
|
|
7
|
+
License-Expression: MIT
|
|
8
8
|
Project-URL: homepage, https://tu-dresden.de/ing/maschinenwesen/iet/gewv/forschung/forschungsprojekte/flixopt
|
|
9
9
|
Project-URL: repository, https://github.com/flixOpt/flixopt
|
|
10
10
|
Project-URL: documentation, https://flixopt.github.io/flixopt/
|
|
11
11
|
Keywords: optimization,energy systems,numerical analysis
|
|
12
12
|
Classifier: Development Status :: 3 - Alpha
|
|
13
|
-
Classifier: License :: OSI Approved :: MIT License
|
|
14
13
|
Classifier: Programming Language :: Python :: 3.10
|
|
15
14
|
Classifier: Programming Language :: Python :: 3.11
|
|
16
15
|
Classifier: Programming Language :: Python :: 3.12
|
|
@@ -18,7 +17,6 @@ Classifier: Programming Language :: Python :: 3.13
|
|
|
18
17
|
Classifier: Intended Audience :: Developers
|
|
19
18
|
Classifier: Intended Audience :: Science/Research
|
|
20
19
|
Classifier: Topic :: Scientific/Engineering
|
|
21
|
-
Classifier: License :: OSI Approved :: MIT License
|
|
22
20
|
Requires-Python: >=3.10
|
|
23
21
|
Description-Content-Type: text/markdown
|
|
24
22
|
License-File: LICENSE
|
|
@@ -26,7 +24,7 @@ Requires-Dist: numpy<3,>=1.21.5
|
|
|
26
24
|
Requires-Dist: pandas<3,>=2.0.0
|
|
27
25
|
Requires-Dist: xarray<2026.0,>=2024.2.0
|
|
28
26
|
Requires-Dist: linopy<0.6,>=0.5.1
|
|
29
|
-
Requires-Dist:
|
|
27
|
+
Requires-Dist: h5netcdf<2,>=1.0.0
|
|
30
28
|
Requires-Dist: pyyaml<7,>=6.0.0
|
|
31
29
|
Requires-Dist: rich<15,>=13.0.0
|
|
32
30
|
Requires-Dist: tomli<3,>=2.0.1; python_version < "3.11"
|
|
@@ -53,6 +51,7 @@ Requires-Dist: werkzeug<4,>=3.0.0; extra == "full"
|
|
|
53
51
|
Requires-Dist: flask<4,>=3.0.0; extra == "full"
|
|
54
52
|
Provides-Extra: dev
|
|
55
53
|
Requires-Dist: pytest==8.4.2; extra == "dev"
|
|
54
|
+
Requires-Dist: pytest-xdist==3.8.0; extra == "dev"
|
|
56
55
|
Requires-Dist: nbformat==5.10.4; extra == "dev"
|
|
57
56
|
Requires-Dist: ruff==0.13.0; extra == "dev"
|
|
58
57
|
Requires-Dist: pre-commit==4.3.0; extra == "dev"
|
|
@@ -791,7 +791,7 @@ class StorageModel(ComponentModel):
|
|
|
791
791
|
charge_state.isel(time=slice(1, None))
|
|
792
792
|
== charge_state.isel(time=slice(None, -1)) * ((1 - rel_loss) ** hours_per_step)
|
|
793
793
|
+ charge_rate * eff_charge * hours_per_step
|
|
794
|
-
- discharge_rate *
|
|
794
|
+
- discharge_rate * hours_per_step / eff_discharge,
|
|
795
795
|
name=f'{self.label_full}|charge_state',
|
|
796
796
|
),
|
|
797
797
|
'charge_state',
|
|
@@ -211,9 +211,10 @@ class FlowSystem:
|
|
|
211
211
|
ds.attrs = self.as_dict(data_mode='name')
|
|
212
212
|
return ds
|
|
213
213
|
|
|
214
|
-
def to_netcdf(self, path: str | pathlib.Path, compression: int = 0, constants_in_dataset: bool = True):
|
|
214
|
+
def to_netcdf(self, path: str | pathlib.Path, compression: int = 0, constants_in_dataset: bool = True) -> None:
|
|
215
215
|
"""
|
|
216
216
|
Saves the FlowSystem to a netCDF file.
|
|
217
|
+
|
|
217
218
|
Args:
|
|
218
219
|
path: The path to the netCDF file.
|
|
219
220
|
compression: The compression level to use when saving the file.
|
|
@@ -208,6 +208,7 @@ def save_dataset_to_netcdf(
|
|
|
208
208
|
ds: xr.Dataset,
|
|
209
209
|
path: str | pathlib.Path,
|
|
210
210
|
compression: int = 0,
|
|
211
|
+
engine: Literal['netcdf4', 'scipy', 'h5netcdf'] = 'h5netcdf',
|
|
211
212
|
) -> None:
|
|
212
213
|
"""
|
|
213
214
|
Save a dataset to a netcdf file. Store the attrs as a json string in the 'attrs' attribute.
|
|
@@ -226,12 +227,12 @@ def save_dataset_to_netcdf(
|
|
|
226
227
|
|
|
227
228
|
apply_encoding = False
|
|
228
229
|
if compression != 0:
|
|
229
|
-
if importlib.util.find_spec(
|
|
230
|
+
if importlib.util.find_spec(engine) is not None:
|
|
230
231
|
apply_encoding = True
|
|
231
232
|
else:
|
|
232
233
|
logger.warning(
|
|
233
|
-
'Dataset was exported without compression due to missing dependency "
|
|
234
|
-
'Install
|
|
234
|
+
f'Dataset was exported without compression due to missing dependency "{engine}".'
|
|
235
|
+
f'Install {engine} via `pip install {engine}`.'
|
|
235
236
|
)
|
|
236
237
|
ds = ds.copy(deep=True)
|
|
237
238
|
ds.attrs = {'attrs': json.dumps(ds.attrs)}
|
|
@@ -240,6 +241,7 @@ def save_dataset_to_netcdf(
|
|
|
240
241
|
encoding=None
|
|
241
242
|
if not apply_encoding
|
|
242
243
|
else {data_var: {'zlib': True, 'complevel': compression} for data_var in ds.data_vars},
|
|
244
|
+
engine=engine,
|
|
243
245
|
)
|
|
244
246
|
|
|
245
247
|
|
|
@@ -253,7 +255,7 @@ def load_dataset_from_netcdf(path: str | pathlib.Path) -> xr.Dataset:
|
|
|
253
255
|
Returns:
|
|
254
256
|
Dataset: Loaded dataset.
|
|
255
257
|
"""
|
|
256
|
-
ds = xr.load_dataset(str(path))
|
|
258
|
+
ds = xr.load_dataset(str(path), engine='h5netcdf')
|
|
257
259
|
ds.attrs = json.loads(ds.attrs['attrs'])
|
|
258
260
|
return ds
|
|
259
261
|
|
|
@@ -338,7 +338,7 @@ class CalculationResults:
|
|
|
338
338
|
if self.model is None:
|
|
339
339
|
logger.critical('No model in the CalculationResults. Saving the model is not possible.')
|
|
340
340
|
else:
|
|
341
|
-
self.model.to_netcdf(paths.linopy_model)
|
|
341
|
+
self.model.to_netcdf(paths.linopy_model, engine='h5netcdf')
|
|
342
342
|
|
|
343
343
|
if document_model:
|
|
344
344
|
if self.model is None:
|
|
@@ -1,16 +1,15 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: flixopt
|
|
3
|
-
Version: 2.1.
|
|
3
|
+
Version: 2.1.11
|
|
4
4
|
Summary: Vector based energy and material flow optimization framework in Python.
|
|
5
5
|
Author-email: "Chair of Building Energy Systems and Heat Supply, TU Dresden" <peter.stange@tu-dresden.de>, Felix Bumann <felixbumann387@gmail.com>, Felix Panitz <baumbude@googlemail.com>, Peter Stange <peter.stange@tu-dresden.de>
|
|
6
6
|
Maintainer-email: Felix Bumann <felixbumann387@gmail.com>, Peter Stange <peter.stange@tu-dresden.de>
|
|
7
|
-
License: MIT
|
|
7
|
+
License-Expression: MIT
|
|
8
8
|
Project-URL: homepage, https://tu-dresden.de/ing/maschinenwesen/iet/gewv/forschung/forschungsprojekte/flixopt
|
|
9
9
|
Project-URL: repository, https://github.com/flixOpt/flixopt
|
|
10
10
|
Project-URL: documentation, https://flixopt.github.io/flixopt/
|
|
11
11
|
Keywords: optimization,energy systems,numerical analysis
|
|
12
12
|
Classifier: Development Status :: 3 - Alpha
|
|
13
|
-
Classifier: License :: OSI Approved :: MIT License
|
|
14
13
|
Classifier: Programming Language :: Python :: 3.10
|
|
15
14
|
Classifier: Programming Language :: Python :: 3.11
|
|
16
15
|
Classifier: Programming Language :: Python :: 3.12
|
|
@@ -18,7 +17,6 @@ Classifier: Programming Language :: Python :: 3.13
|
|
|
18
17
|
Classifier: Intended Audience :: Developers
|
|
19
18
|
Classifier: Intended Audience :: Science/Research
|
|
20
19
|
Classifier: Topic :: Scientific/Engineering
|
|
21
|
-
Classifier: License :: OSI Approved :: MIT License
|
|
22
20
|
Requires-Python: >=3.10
|
|
23
21
|
Description-Content-Type: text/markdown
|
|
24
22
|
License-File: LICENSE
|
|
@@ -26,7 +24,7 @@ Requires-Dist: numpy<3,>=1.21.5
|
|
|
26
24
|
Requires-Dist: pandas<3,>=2.0.0
|
|
27
25
|
Requires-Dist: xarray<2026.0,>=2024.2.0
|
|
28
26
|
Requires-Dist: linopy<0.6,>=0.5.1
|
|
29
|
-
Requires-Dist:
|
|
27
|
+
Requires-Dist: h5netcdf<2,>=1.0.0
|
|
30
28
|
Requires-Dist: pyyaml<7,>=6.0.0
|
|
31
29
|
Requires-Dist: rich<15,>=13.0.0
|
|
32
30
|
Requires-Dist: tomli<3,>=2.0.1; python_version < "3.11"
|
|
@@ -53,6 +51,7 @@ Requires-Dist: werkzeug<4,>=3.0.0; extra == "full"
|
|
|
53
51
|
Requires-Dist: flask<4,>=3.0.0; extra == "full"
|
|
54
52
|
Provides-Extra: dev
|
|
55
53
|
Requires-Dist: pytest==8.4.2; extra == "dev"
|
|
54
|
+
Requires-Dist: pytest-xdist==3.8.0; extra == "dev"
|
|
56
55
|
Requires-Dist: nbformat==5.10.4; extra == "dev"
|
|
57
56
|
Requires-Dist: ruff==0.13.0; extra == "dev"
|
|
58
57
|
Requires-Dist: pre-commit==4.3.0; extra == "dev"
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
CHANGELOG.md
|
|
2
|
+
LICENSE
|
|
3
|
+
MANIFEST.in
|
|
4
|
+
README.md
|
|
5
|
+
pyproject.toml
|
|
6
|
+
flixopt/__init__.py
|
|
7
|
+
flixopt/aggregation.py
|
|
8
|
+
flixopt/calculation.py
|
|
9
|
+
flixopt/commons.py
|
|
10
|
+
flixopt/components.py
|
|
11
|
+
flixopt/config.py
|
|
12
|
+
flixopt/config.yaml
|
|
13
|
+
flixopt/core.py
|
|
14
|
+
flixopt/effects.py
|
|
15
|
+
flixopt/elements.py
|
|
16
|
+
flixopt/features.py
|
|
17
|
+
flixopt/flow_system.py
|
|
18
|
+
flixopt/interface.py
|
|
19
|
+
flixopt/io.py
|
|
20
|
+
flixopt/linear_converters.py
|
|
21
|
+
flixopt/network_app.py
|
|
22
|
+
flixopt/plotting.py
|
|
23
|
+
flixopt/results.py
|
|
24
|
+
flixopt/solvers.py
|
|
25
|
+
flixopt/structure.py
|
|
26
|
+
flixopt/utils.py
|
|
27
|
+
flixopt.egg-info/PKG-INFO
|
|
28
|
+
flixopt.egg-info/SOURCES.txt
|
|
29
|
+
flixopt.egg-info/dependency_links.txt
|
|
30
|
+
flixopt.egg-info/requires.txt
|
|
31
|
+
flixopt.egg-info/top_level.txt
|
|
@@ -2,7 +2,7 @@ numpy<3,>=1.21.5
|
|
|
2
2
|
pandas<3,>=2.0.0
|
|
3
3
|
xarray<2026.0,>=2024.2.0
|
|
4
4
|
linopy<0.6,>=0.5.1
|
|
5
|
-
|
|
5
|
+
h5netcdf<2,>=1.0.0
|
|
6
6
|
pyyaml<7,>=6.0.0
|
|
7
7
|
rich<15,>=13.0.0
|
|
8
8
|
highspy<2,>=1.5.3
|
|
@@ -14,6 +14,7 @@ tomli<3,>=2.0.1
|
|
|
14
14
|
|
|
15
15
|
[dev]
|
|
16
16
|
pytest==8.4.2
|
|
17
|
+
pytest-xdist==3.8.0
|
|
17
18
|
nbformat==5.10.4
|
|
18
19
|
ruff==0.13.0
|
|
19
20
|
pre-commit==4.3.0
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
flixopt
|
|
@@ -8,7 +8,7 @@ dynamic = ["version"]
|
|
|
8
8
|
description = "Vector based energy and material flow optimization framework in Python."
|
|
9
9
|
readme = "README.md"
|
|
10
10
|
requires-python = ">=3.10"
|
|
11
|
-
license =
|
|
11
|
+
license = "MIT"
|
|
12
12
|
authors = [
|
|
13
13
|
{ name = "Chair of Building Energy Systems and Heat Supply, TU Dresden", email = "peter.stange@tu-dresden.de" },
|
|
14
14
|
{ name = "Felix Bumann", email = "felixbumann387@gmail.com" },
|
|
@@ -22,7 +22,6 @@ maintainers = [
|
|
|
22
22
|
keywords = ["optimization", "energy systems", "numerical analysis"]
|
|
23
23
|
classifiers = [
|
|
24
24
|
"Development Status :: 3 - Alpha",
|
|
25
|
-
"License :: OSI Approved :: MIT License",
|
|
26
25
|
"Programming Language :: Python :: 3.10",
|
|
27
26
|
"Programming Language :: Python :: 3.11",
|
|
28
27
|
"Programming Language :: Python :: 3.12",
|
|
@@ -30,7 +29,6 @@ classifiers = [
|
|
|
30
29
|
"Intended Audience :: Developers",
|
|
31
30
|
"Intended Audience :: Science/Research",
|
|
32
31
|
"Topic :: Scientific/Engineering",
|
|
33
|
-
"License :: OSI Approved :: MIT License",
|
|
34
32
|
]
|
|
35
33
|
dependencies = [
|
|
36
34
|
# Core scientific computing
|
|
@@ -39,7 +37,7 @@ dependencies = [
|
|
|
39
37
|
"xarray >= 2024.2.0, < 2026.0", # CalVer: allow through next calendar year
|
|
40
38
|
# Optimization and data handling
|
|
41
39
|
"linopy >= 0.5.1, < 0.6", # Widened from patch pin to minor range
|
|
42
|
-
"
|
|
40
|
+
"h5netcdf>=1.0.0, < 2",
|
|
43
41
|
# Utilities
|
|
44
42
|
"pyyaml >= 6.0.0, < 7",
|
|
45
43
|
"rich >= 13.0.0, < 15",
|
|
@@ -80,6 +78,7 @@ full = [
|
|
|
80
78
|
# Development tools and testing
|
|
81
79
|
dev = [
|
|
82
80
|
"pytest==8.4.2",
|
|
81
|
+
"pytest-xdist==3.8.0",
|
|
83
82
|
"nbformat==5.10.4",
|
|
84
83
|
"ruff==0.13.0",
|
|
85
84
|
"pre-commit==4.3.0",
|
|
@@ -115,11 +114,18 @@ documentation = "https://flixopt.github.io/flixopt/"
|
|
|
115
114
|
|
|
116
115
|
[tool.setuptools.packages.find]
|
|
117
116
|
where = ["."]
|
|
118
|
-
|
|
117
|
+
include = ["flixopt*"]
|
|
118
|
+
exclude = ["tests*", "docs*", "examples*", "Tutorials*"]
|
|
119
119
|
|
|
120
120
|
[tool.setuptools.package-data]
|
|
121
121
|
"flixopt" = ["config.yaml"]
|
|
122
122
|
|
|
123
|
+
[tool.setuptools]
|
|
124
|
+
include-package-data = true
|
|
125
|
+
|
|
126
|
+
[tool.setuptools.exclude-package-data]
|
|
127
|
+
"*" = ["*.md", ".git*", "*.ipynb", "renovate.json"]
|
|
128
|
+
|
|
123
129
|
[tool.setuptools_scm]
|
|
124
130
|
version_scheme = "post-release"
|
|
125
131
|
|
|
@@ -176,6 +182,13 @@ docstring-code-format = true
|
|
|
176
182
|
[tool.ruff.lint.pyupgrade]
|
|
177
183
|
keep-runtime-typing = false # Allow pyupgrade to drop runtime typing; prefer postponed annotations
|
|
178
184
|
|
|
185
|
+
[tool.pytest.ini_options]
|
|
186
|
+
markers = [
|
|
187
|
+
"slow: marks tests as slow",
|
|
188
|
+
"examples: marks example tests (run only on releases)",
|
|
189
|
+
]
|
|
190
|
+
addopts = "-m 'not examples'" # Skip examples by default
|
|
191
|
+
|
|
179
192
|
[tool.bandit]
|
|
180
193
|
skips = ["B101", "B506"] # assert_used and yaml_load
|
|
181
194
|
exclude_dirs = ["tests/"]
|