ahuora-builder 0.1.0__py3-none-any.whl

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.
Files changed (167) hide show
  1. ahuora_builder/__init__.py +0 -0
  2. ahuora_builder/arc_manager.py +33 -0
  3. ahuora_builder/build_state.py +57 -0
  4. ahuora_builder/custom/PIDController.py +494 -0
  5. ahuora_builder/custom/PySMOModel.py +178 -0
  6. ahuora_builder/custom/SimpleEffectivenessHX_DH.py +727 -0
  7. ahuora_builder/custom/__init__.py +0 -0
  8. ahuora_builder/custom/add_initial_dynamics.py +35 -0
  9. ahuora_builder/custom/custom_compressor.py +107 -0
  10. ahuora_builder/custom/custom_cooler.py +33 -0
  11. ahuora_builder/custom/custom_heat_exchanger.py +183 -0
  12. ahuora_builder/custom/custom_heat_exchanger_1d.py +258 -0
  13. ahuora_builder/custom/custom_heater.py +41 -0
  14. ahuora_builder/custom/custom_pressure_changer.py +34 -0
  15. ahuora_builder/custom/custom_pump.py +107 -0
  16. ahuora_builder/custom/custom_separator.py +371 -0
  17. ahuora_builder/custom/custom_tank.py +133 -0
  18. ahuora_builder/custom/custom_turbine.py +132 -0
  19. ahuora_builder/custom/custom_valve.py +300 -0
  20. ahuora_builder/custom/custom_variable.py +29 -0
  21. ahuora_builder/custom/direct_steam_injection.py +371 -0
  22. ahuora_builder/custom/energy/__init__.py +0 -0
  23. ahuora_builder/custom/energy/acBus.py +280 -0
  24. ahuora_builder/custom/energy/ac_property_package.py +279 -0
  25. ahuora_builder/custom/energy/battery.py +170 -0
  26. ahuora_builder/custom/energy/bus.py +182 -0
  27. ahuora_builder/custom/energy/energy_mixer.py +195 -0
  28. ahuora_builder/custom/energy/energy_splitter.py +228 -0
  29. ahuora_builder/custom/energy/grid.py +173 -0
  30. ahuora_builder/custom/energy/hydro.py +169 -0
  31. ahuora_builder/custom/energy/link.py +137 -0
  32. ahuora_builder/custom/energy/load.py +155 -0
  33. ahuora_builder/custom/energy/mainDistributionBoard.py +257 -0
  34. ahuora_builder/custom/energy/power_property_package.py +253 -0
  35. ahuora_builder/custom/energy/solar.py +176 -0
  36. ahuora_builder/custom/energy/storage.py +230 -0
  37. ahuora_builder/custom/energy/storage_wrapper +0 -0
  38. ahuora_builder/custom/energy/tests/__init__.py +0 -0
  39. ahuora_builder/custom/energy/tests/test_bus.py +44 -0
  40. ahuora_builder/custom/energy/tests/test_energy_mixer.py +46 -0
  41. ahuora_builder/custom/energy/tests/test_mdb.py +49 -0
  42. ahuora_builder/custom/energy/transformer.py +187 -0
  43. ahuora_builder/custom/energy/transformer_property_package.py +267 -0
  44. ahuora_builder/custom/energy/transmissionLine.py +228 -0
  45. ahuora_builder/custom/energy/wind.py +206 -0
  46. ahuora_builder/custom/hda_ideal_VLE.py +1341 -0
  47. ahuora_builder/custom/hda_reaction.py +182 -0
  48. ahuora_builder/custom/heat_exchanger_1d_wrapper.py +31 -0
  49. ahuora_builder/custom/integration_block.py +106 -0
  50. ahuora_builder/custom/inverted.py +81 -0
  51. ahuora_builder/custom/performance_curves.py +1 -0
  52. ahuora_builder/custom/reactions/__init__.py +0 -0
  53. ahuora_builder/custom/reactions/hda_stoich.py +10 -0
  54. ahuora_builder/custom/simple_separator.py +680 -0
  55. ahuora_builder/custom/tests/__init__.py +0 -0
  56. ahuora_builder/custom/tests/test_SimpleEffectivenessHX_DH.py +91 -0
  57. ahuora_builder/custom/tests/test_custom_tank.py +70 -0
  58. ahuora_builder/custom/tests/test_direct_steam_injection.py +41 -0
  59. ahuora_builder/custom/tests/test_simple_separator.py +46 -0
  60. ahuora_builder/custom/tests/test_waterpipe.py +46 -0
  61. ahuora_builder/custom/thermal_utility_systems/desuperheater.py +624 -0
  62. ahuora_builder/custom/thermal_utility_systems/header.py +889 -0
  63. ahuora_builder/custom/thermal_utility_systems/simple_heat_pump.py +567 -0
  64. ahuora_builder/custom/thermal_utility_systems/steam_header.py +353 -0
  65. ahuora_builder/custom/thermal_utility_systems/steam_user.py +944 -0
  66. ahuora_builder/custom/thermal_utility_systems/temp.py +349 -0
  67. ahuora_builder/custom/thermal_utility_systems/tests/test_desuperheater.py +142 -0
  68. ahuora_builder/custom/thermal_utility_systems/tests/test_header.py +998 -0
  69. ahuora_builder/custom/thermal_utility_systems/tests/test_ntu_hx.py +129 -0
  70. ahuora_builder/custom/thermal_utility_systems/tests/test_simple_heat_pump.py +120 -0
  71. ahuora_builder/custom/thermal_utility_systems/tests/test_steam_header.py +703 -0
  72. ahuora_builder/custom/thermal_utility_systems/tests/test_steam_user.py +277 -0
  73. ahuora_builder/custom/thermal_utility_systems/tests/test_waterpipe.py +36 -0
  74. ahuora_builder/custom/thermal_utility_systems/tests/test_willans_turbine.py +253 -0
  75. ahuora_builder/custom/thermal_utility_systems/willans_turbine.py +804 -0
  76. ahuora_builder/custom/translator.py +129 -0
  77. ahuora_builder/custom/updated_pressure_changer.py +1404 -0
  78. ahuora_builder/custom/valve_wrapper.py +38 -0
  79. ahuora_builder/custom/water_tank_with_units.py +456 -0
  80. ahuora_builder/diagnostics/__init__.py +0 -0
  81. ahuora_builder/diagnostics/infeasibilities.py +40 -0
  82. ahuora_builder/diagnostics/tests/__init__.py +0 -0
  83. ahuora_builder/diagnostics/tests/test_infeasibilities.py +28 -0
  84. ahuora_builder/flowsheet_manager.py +542 -0
  85. ahuora_builder/flowsheet_manager_type.py +20 -0
  86. ahuora_builder/generate_python_file.py +440 -0
  87. ahuora_builder/methods/BlockContext.py +84 -0
  88. ahuora_builder/methods/__init__.py +0 -0
  89. ahuora_builder/methods/adapter.py +355 -0
  90. ahuora_builder/methods/adapter_library.py +549 -0
  91. ahuora_builder/methods/adapter_methods.py +80 -0
  92. ahuora_builder/methods/expression_parsing.py +105 -0
  93. ahuora_builder/methods/load_unit_model.py +147 -0
  94. ahuora_builder/methods/slice_manipulation.py +7 -0
  95. ahuora_builder/methods/tests/__init__.py +0 -0
  96. ahuora_builder/methods/tests/test_expression_parsing.py +15 -0
  97. ahuora_builder/methods/units_handler.py +129 -0
  98. ahuora_builder/ml_wizard.py +101 -0
  99. ahuora_builder/port_manager.py +20 -0
  100. ahuora_builder/properties_manager.py +44 -0
  101. ahuora_builder/property_package_manager.py +78 -0
  102. ahuora_builder/solver.py +38 -0
  103. ahuora_builder/tear_manager.py +98 -0
  104. ahuora_builder/tests/__init__.py +0 -0
  105. ahuora_builder/tests/test_generate_python_file/__init__.py +0 -0
  106. ahuora_builder/tests/test_generate_python_file/configurations/compressor_generated.py +63 -0
  107. ahuora_builder/tests/test_generate_python_file/configurations/heat_exchanger_generated.py +70 -0
  108. ahuora_builder/tests/test_generate_python_file/configurations/pump_generated.py +84 -0
  109. ahuora_builder/tests/test_generate_python_file/configurations/recycle_generated.py +73 -0
  110. ahuora_builder/tests/test_generate_python_file/test_generate_python_file.py +108 -0
  111. ahuora_builder/tests/test_solver/__init__.py +0 -0
  112. ahuora_builder/tests/test_solver/configurations/BT_PR.json +59 -0
  113. ahuora_builder/tests/test_solver/configurations/BT_PR_solved.json +59 -0
  114. ahuora_builder/tests/test_solver/configurations/bus.json +99 -0
  115. ahuora_builder/tests/test_solver/configurations/bus_solved.json +50 -0
  116. ahuora_builder/tests/test_solver/configurations/compound_separator.json +377 -0
  117. ahuora_builder/tests/test_solver/configurations/compound_separator_solved.json +374 -0
  118. ahuora_builder/tests/test_solver/configurations/compressor.json +38 -0
  119. ahuora_builder/tests/test_solver/configurations/compressor_solved.json +68 -0
  120. ahuora_builder/tests/test_solver/configurations/constraints.json +44 -0
  121. ahuora_builder/tests/test_solver/configurations/constraints_solved.json +59 -0
  122. ahuora_builder/tests/test_solver/configurations/control.json +39 -0
  123. ahuora_builder/tests/test_solver/configurations/control_solved.json +68 -0
  124. ahuora_builder/tests/test_solver/configurations/dynamic_tank.json +733 -0
  125. ahuora_builder/tests/test_solver/configurations/dynamic_tank_solved.json +846 -0
  126. ahuora_builder/tests/test_solver/configurations/elimination.json +39 -0
  127. ahuora_builder/tests/test_solver/configurations/elimination_solved.json +68 -0
  128. ahuora_builder/tests/test_solver/configurations/expressions.json +68 -0
  129. ahuora_builder/tests/test_solver/configurations/expressions_solved.json +104 -0
  130. ahuora_builder/tests/test_solver/configurations/header.json +1192 -0
  131. ahuora_builder/tests/test_solver/configurations/header_solved.json +761 -0
  132. ahuora_builder/tests/test_solver/configurations/heat_exchanger.json +63 -0
  133. ahuora_builder/tests/test_solver/configurations/heat_exchanger_solved.json +104 -0
  134. ahuora_builder/tests/test_solver/configurations/heat_pump.json +137 -0
  135. ahuora_builder/tests/test_solver/configurations/heat_pump_solved.json +104 -0
  136. ahuora_builder/tests/test_solver/configurations/machine_learning.json +2156 -0
  137. ahuora_builder/tests/test_solver/configurations/machine_learning_solved.json +266 -0
  138. ahuora_builder/tests/test_solver/configurations/mass_flow_tear.json +77 -0
  139. ahuora_builder/tests/test_solver/configurations/mass_flow_tear_solved.json +68 -0
  140. ahuora_builder/tests/test_solver/configurations/milk_heater.json +521 -0
  141. ahuora_builder/tests/test_solver/configurations/milk_heater_solved.json +311 -0
  142. ahuora_builder/tests/test_solver/configurations/mixer.json +44 -0
  143. ahuora_builder/tests/test_solver/configurations/mixer_solved.json +86 -0
  144. ahuora_builder/tests/test_solver/configurations/optimization.json +62 -0
  145. ahuora_builder/tests/test_solver/configurations/optimization_solved.json +59 -0
  146. ahuora_builder/tests/test_solver/configurations/propane_heat_pump.json +167 -0
  147. ahuora_builder/tests/test_solver/configurations/propane_heat_pump_solved.json +158 -0
  148. ahuora_builder/tests/test_solver/configurations/propane_recycle.json +141 -0
  149. ahuora_builder/tests/test_solver/configurations/propane_recycle_solved.json +104 -0
  150. ahuora_builder/tests/test_solver/configurations/pump.json +64 -0
  151. ahuora_builder/tests/test_solver/configurations/pump_solved.json +59 -0
  152. ahuora_builder/tests/test_solver/configurations/pump_unit_conversions.json +63 -0
  153. ahuora_builder/tests/test_solver/configurations/recycle.json +49 -0
  154. ahuora_builder/tests/test_solver/configurations/recycle_solved.json +50 -0
  155. ahuora_builder/tests/test_solver/configurations/sb_vapor_frac.json +29 -0
  156. ahuora_builder/tests/test_solver/configurations/sb_vapor_frac_solved.json +29 -0
  157. ahuora_builder/tests/test_solver/configurations/solar.json +67 -0
  158. ahuora_builder/tests/test_solver/configurations/solar_solved.json +50 -0
  159. ahuora_builder/tests/test_solver/configurations/vapor_frac_target.json +67 -0
  160. ahuora_builder/tests/test_solver/configurations/vapor_frac_target_solved.json +68 -0
  161. ahuora_builder/tests/test_solver/test_solve_models.py +250 -0
  162. ahuora_builder/timing.py +65 -0
  163. ahuora_builder/types/__init__.py +1 -0
  164. ahuora_builder/unit_model_manager.py +48 -0
  165. ahuora_builder-0.1.0.dist-info/METADATA +14 -0
  166. ahuora_builder-0.1.0.dist-info/RECORD +167 -0
  167. ahuora_builder-0.1.0.dist-info/WHEEL +4 -0
@@ -0,0 +1,250 @@
1
+ import os
2
+ import json
3
+ import io
4
+
5
+ from typing import Any
6
+
7
+ from ahuora_builder_types import FlowsheetSchema
8
+ from ahuora_builder_types.payloads import BuildStateRequestSchema
9
+ from ahuora_builder.flowsheet_manager import FlowsheetManager
10
+ from ahuora_builder.build_state import solve_state_block
11
+ from contextlib import redirect_stdout
12
+
13
+
14
+ # Set this to True to regenerate expected output files, if needed (e.g output file format changes.)
15
+ # Make sure to review the commit to ensure that only intended changes are made to expected output files.
16
+ GENERATE_TESTS = False
17
+
18
+ # Get current location (so that we can retrieve pump.json)
19
+ __location__ = os.path.realpath(os.path.join(os.getcwd(), os.path.dirname(__file__)))
20
+
21
+
22
+ def try_solve(input_file: str, expected_output_file: str, state_block=False) -> None:
23
+ """Tests that the model can be solved and that the answer returned is correct"""
24
+
25
+ with open(os.path.join(__location__, input_file), 'r') as file:
26
+
27
+ data = json.load(file)
28
+
29
+ if state_block:
30
+ build_state_schema = BuildStateRequestSchema.model_validate(data)
31
+ result = solve_state_block(build_state_schema)
32
+ result = [solved_value.model_dump() for solved_value in result]
33
+ else:
34
+ flowsheet_schema = FlowsheetSchema.model_validate(data)
35
+ flowsheet = FlowsheetManager(flowsheet_schema)
36
+ flowsheet.load()
37
+ flowsheet.initialise()
38
+ assert flowsheet.degrees_of_freedom() == 0, "Degrees of freedom is not 0: " + str(flowsheet.degrees_of_freedom())
39
+ flowsheet.report_statistics()
40
+ flowsheet.solve()
41
+ flowsheet.optimize()
42
+
43
+ result = flowsheet.serialise()
44
+ result = result.model_dump()
45
+
46
+ # ignore initial values
47
+ del result["initial_values"]
48
+
49
+ # # write result to a file for debugging - or to regenerate expected files
50
+ if GENERATE_TESTS:
51
+ with open(os.path.join(__location__, expected_output_file), 'w') as f:
52
+ f.write(json.dumps(result, indent=4))
53
+
54
+ print(result)
55
+
56
+ # Assert - Check if all the parameters are correct
57
+ with open(os.path.join(__location__, expected_output_file), 'r') as file:
58
+ # Load the result JSON file
59
+ expected_result = json.load(file)
60
+
61
+ # Check if the result is equal to the expected_result
62
+ try:
63
+ if state_block:
64
+ values_approximately_equal(result, expected_result, 1e-1)
65
+ else:
66
+ values_approximately_equal(result, expected_result, 1e-1)
67
+ except Exception as e:
68
+ print(e)
69
+ raise AssertionError(f"Did not solve the model correctly")
70
+
71
+
72
+ def values_approximately_equal(val1: Any, val2: Any, tolerance: float = 1e-3) -> bool:
73
+ """
74
+ Checks if two values are approximately equal
75
+ """
76
+ if isinstance(val1, (float, int)) and isinstance(val2, (float, int)):
77
+ if not abs(val1 - val2) < tolerance:
78
+ raise AssertionError(f"Value: {val1} is not equal to expected value: {val2} within tolerance {tolerance}")
79
+ elif isinstance(val1, list) and isinstance(val2, list):
80
+ if len(val1) != len(val2):
81
+ raise AssertionError(f"Lists have different lengths: {len(val1)} and {len(val2)}")
82
+ return all(values_approximately_equal(v1, v2, tolerance) for v1, v2 in zip(val1, val2))
83
+ elif isinstance(val1, dict) and isinstance(val2, dict):
84
+ if set(val1.keys()) != set(val2.keys()):
85
+ raise AssertionError(f"Keys: {val1.keys()} are not equal to expected keys: {val2.keys()}")
86
+ return all(values_approximately_equal(val1[key], val2[key], tolerance) for key in val1)
87
+ else:
88
+ if val1 != val2:
89
+ raise AssertionError(f"Value: {val1} is not equal to expected value: {val2}")
90
+ return True
91
+
92
+
93
+ def test_generate_is_false():
94
+ assert GENERATE_TESTS is False, "test_generate_python_file.py: GENERATE_TESTS should be False to avoid overriding test_solved.json files during tests."
95
+
96
+
97
+ def test_solve_pump_and_heater() -> None:
98
+ # Tests that the pump and heater model can be solved
99
+ try_solve('configurations/pump.json', 'configurations/pump_solved.json')
100
+
101
+
102
+ def test_solve_recycle() -> None:
103
+ # Tests that the recycle model can be solved (Recycle connected to itself)
104
+ try_solve('configurations/recycle.json', 'configurations/recycle_solved.json')
105
+
106
+
107
+ def test_solve_compressor() -> None:
108
+ # Tests that the compressor model can be solved
109
+ try_solve('configurations/compressor.json', 'configurations/compressor_solved.json')
110
+
111
+
112
+ def test_solve_mixer() -> None:
113
+ # Tests that the mixer model can be solved
114
+ try_solve('configurations/mixer.json', 'configurations/mixer_solved.json')
115
+
116
+
117
+ def test_solve_bt_pr() -> None:
118
+ # Peng-Robinson test with Benzene and Toluene
119
+ try_solve('configurations/BT_PR.json', 'configurations/BT_PR_solved.json')
120
+
121
+
122
+ def test_solve_heat_exchanger() -> None:
123
+ """Tests that the BT_PR model can be solved"""
124
+ try_solve('configurations/heat_exchanger.json','configurations/heat_exchanger_solved.json')
125
+
126
+
127
+ def test_solve_heat_pump() -> None:
128
+ """Tests that the turbine model can be solved"""
129
+ # TODO: fix this test case - the values specified are not very good
130
+ # and although the model solves, it doesn't really show anything useful
131
+ try_solve('configurations/heat_pump.json','configurations/heat_pump_solved.json')
132
+
133
+
134
+ def test_solve_unit_conversions() -> None:
135
+ """
136
+ Checks that unit conversions work as expected
137
+
138
+ To do this, we solve the pump model and check that everything works as expected
139
+ """
140
+ # the output file should stay the same since we are just changing the units
141
+ try_solve('configurations/pump_unit_conversions.json', 'configurations/pump_solved.json')
142
+
143
+
144
+ def test_solve_expressions() -> None:
145
+ """
146
+ Checks that expressions work as expected
147
+ """
148
+ try_solve('configurations/expressions.json', 'configurations/expressions_solved.json')
149
+
150
+
151
+ def test_solve_vapor_frac_target():
152
+ # compressor_test_with_vapor_fraction - targets an outlet vapor fraction of 1
153
+ try_solve('configurations/vapor_frac_target.json', 'configurations/vapor_frac_target_solved.json')
154
+
155
+
156
+ def test_solve_mass_flow_tear():
157
+ # recycle with mass flow constraint
158
+ try_solve('configurations/mass_flow_tear.json', 'configurations/mass_flow_tear_solved.json')
159
+
160
+
161
+ def test_solve_propane_recycle():
162
+ try_solve('configurations/propane_recycle.json', 'configurations/propane_recycle_solved.json')
163
+
164
+
165
+ def test_solve_propane_heat_pump():
166
+ try_solve('configurations/propane_heat_pump.json', 'configurations/propane_heat_pump_solved.json')
167
+
168
+
169
+ def test_solve_control():
170
+ # inlet enthalpy is controlled by the set point of the outlet enthalpy
171
+ try_solve('configurations/control.json', 'configurations/control_solved.json')
172
+
173
+ def test_solve_machine_learning():
174
+ try_solve('configurations/machine_learning.json', 'configurations/machine_learning_solved.json')
175
+
176
+
177
+ def test_solve_sb_vapor_frac() -> None:
178
+ # Tests that a state block with vapor_frac can be solved
179
+ try_solve('configurations/sb_vapor_frac.json', 'configurations/sb_vapor_frac_solved.json', state_block=True)
180
+
181
+
182
+ def test_solve_compound_separator() -> None:
183
+ # Tests that a compound separator model can be solved
184
+ try_solve('configurations/compound_separator.json', 'configurations/compound_separator_solved.json')
185
+
186
+
187
+ def test_solve_constraints() -> None:
188
+ # Tests that a model with constraints can be solved
189
+ # Tests for an equality constraint using an expression
190
+ try_solve('configurations/constraints.json', 'configurations/constraints_solved.json')
191
+
192
+
193
+ def test_solve_link() -> None:
194
+ # Tests that a bus model can be solved
195
+ try_solve('configurations/bus.json', 'configurations/bus_solved.json')
196
+
197
+
198
+ def test_solve_optimization() -> None:
199
+ # Tests optimizing an expression
200
+ try_solve('configurations/optimization.json', 'configurations/optimization_solved.json')
201
+
202
+ def test_solve_solar() -> None:
203
+ # Tests that a solar model can be solved
204
+ try_solve('configurations/solar.json', 'configurations/solar_solved.json')
205
+
206
+
207
+ def test_solve_milk_heater() -> None:
208
+ try_solve('configurations/milk_heater.json', 'configurations/milk_heater_solved.json')
209
+
210
+ def test_solve_dynamic_tank() -> None:
211
+ try_solve('configurations/dynamic_tank.json', 'configurations/dynamic_tank_solved.json')
212
+
213
+ def test_solve_elimination() -> None:
214
+ # more complex elimination, where there are choices to eliminate and the right pair has to be eliminated
215
+ # ie. because we can't have both enthalpy and temperature fixed at the same time, leaving
216
+ # both flow_mol and flow_mass unfixed (even this is still the correct degrees of freedom)
217
+ # in this specific test case, flow_mass should eliminate flow_mol and constrain at the state block level
218
+ try_solve('configurations/elimination.json', 'configurations/elimination_solved.json')
219
+
220
+ def test_solve_header() -> None:
221
+ # Tests that a compound separator model can be solved
222
+ try_solve('configurations/header.json', 'configurations/header_solved.json')
223
+
224
+ def test_initialisation_disabled_branch():
225
+ """
226
+ Test that FlowsheetManager.initialise() skips initialisation and prints the correct message
227
+ when disable_initialization is True.
228
+ """
229
+ schema = FlowsheetSchema(
230
+ id=999,
231
+ dynamic=False,
232
+ time_set=[0],
233
+ property_packages=[],
234
+ unit_models=[],
235
+ arcs=[],
236
+ expressions=[],
237
+ optimizations=[],
238
+ is_rating_mode=False,
239
+ disable_initialization=True, # Disable initialisation for this test
240
+ )
241
+ manager = FlowsheetManager(schema)
242
+ manager.load()
243
+
244
+ f = io.StringIO()
245
+ with redirect_stdout(f):
246
+ manager.initialise()
247
+ output = f.getvalue()
248
+
249
+ assert "Initialisation is disabled for this scenario." in output
250
+ assert "initialise_model" not in output
@@ -0,0 +1,65 @@
1
+ from contextvars import ContextVar
2
+ import time
3
+
4
+
5
+ class TimingDebugHandler:
6
+ def __init__(self, key: str = "root") -> None:
7
+ self.timing: dict[str, dict] = {}
8
+ self.pointer_stack = [self.timing]
9
+ self.step_into(key)
10
+
11
+ def current_item(self):
12
+ item = self.current_pointer()
13
+ if len(item) == 0:
14
+ return None
15
+ return item[list(item.keys())[-1]]
16
+
17
+ def current_pointer(self):
18
+ return self.pointer_stack[-1]
19
+
20
+ def update_last_timing(self):
21
+ if self.current_item():
22
+ # update the duration of the previous key
23
+ self.current_item()["duration"] = time.time() - self.current_item()["start_time"]
24
+
25
+ def add_timing(self, key: str):
26
+ self.update_last_timing()
27
+ self.current_pointer()[key] = {
28
+ "start_time": time.time(),
29
+ "duration": None, # calculated at the next timing
30
+ "children": {}
31
+ }
32
+
33
+ def step_into(self, key=None):
34
+ self.add_timing(key)
35
+ self.pointer_stack.append(self.current_item()["children"])
36
+
37
+ def step_out(self):
38
+ self.update_last_timing()
39
+ self.pointer_stack.pop()
40
+
41
+ def close(self):
42
+ # update root duration
43
+ self.step_out()
44
+ self.update_last_timing()
45
+ return self.timing
46
+
47
+
48
+ def start_timing(key: str = "root"):
49
+ """
50
+ start a new timing handler
51
+ """
52
+ handler = TimingDebugHandler(key)
53
+ timing.set(handler)
54
+ return handler
55
+
56
+
57
+ def get_timer():
58
+ """
59
+ get the current timing handler
60
+ """
61
+ return timing.get()
62
+
63
+
64
+ # Create a context variable to store the timing information
65
+ timing: ContextVar[TimingDebugHandler | None] = ContextVar("timing", default=None)
@@ -0,0 +1 @@
1
+
@@ -0,0 +1,48 @@
1
+ from .methods.load_unit_model import add_unit_model_to_flowsheet
2
+ from .methods.adapter_library import UnitModelConstructor, AdapterLibrary
3
+ from .flowsheet_manager_type import FlowsheetManager
4
+ from ahuora_builder_types import UnitModelId, UnitModelSchema
5
+ from idaes.core import UnitModelBlock
6
+
7
+
8
+
9
+ class UnitModelManager:
10
+ """
11
+ Manages the unit models in the flowsheet
12
+ """
13
+
14
+ def __init__(self, flowsheet_manager: FlowsheetManager) -> None:
15
+ """
16
+ Create a new unit model manager
17
+ """
18
+ self.flowsheet_manager = flowsheet_manager
19
+ self._unit_models: dict[UnitModelId, UnitModelBlock] = {}
20
+
21
+ def load(self) -> None:
22
+ """
23
+ load all unit models from the schema into the flowsheet
24
+ """
25
+ schema = self.flowsheet_manager.schema
26
+
27
+ for unit_model_def in schema.unit_models:
28
+ unit_model_type = unit_model_def.type
29
+ if unit_model_type not in AdapterLibrary:
30
+ raise Exception(
31
+ f"Unit model type '{unit_model_type}' is not in the adapter library."
32
+ )
33
+ adapter_constructor: UnitModelConstructor = AdapterLibrary[unit_model_type]
34
+ self.load_from_def(unit_model_def, adapter_constructor)
35
+
36
+ def load_from_def(
37
+ self, unit_model_def: UnitModelSchema, adapter_constructor: UnitModelConstructor
38
+ ) -> None:
39
+ """
40
+ Deserialise a unit model from a JSON object into a unit model adapter
41
+ """
42
+ # add the unit model to the flowsheet
43
+ unit_model = add_unit_model_to_flowsheet(
44
+ unit_model_def, adapter_constructor, self.flowsheet_manager
45
+ )
46
+
47
+ # store a reference to the adapter
48
+ self._unit_models[unit_model_def.id] = unit_model
@@ -0,0 +1,14 @@
1
+ Metadata-Version: 2.4
2
+ Name: ahuora-builder
3
+ Version: 0.1.0
4
+ Summary: Load a Ahuora .JSON file into a pyomo model.
5
+ Requires-Python: >=3.14
6
+ Requires-Dist: ahuora-builder-types
7
+ Requires-Dist: ahuora-compounds
8
+ Requires-Dist: common
9
+ Requires-Dist: coverage==7.11.3
10
+ Requires-Dist: idaes-pse==2.8.0
11
+ Requires-Dist: pyomo==6.9.2
12
+ Requires-Dist: scikit-learn==1.7.2
13
+ Requires-Dist: scipy==1.16.3
14
+ Requires-Dist: typing-validation==1.2.4
@@ -0,0 +1,167 @@
1
+ ahuora_builder/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
2
+ ahuora_builder/arc_manager.py,sha256=cPESu53L1wxYLNE3tpWNe4WJMe0umMUXDEsA24zHv-0,1048
3
+ ahuora_builder/build_state.py,sha256=WFlhJkL02gz860eAzyd3htRMj5UE9pHNOw0XyZCxXJA,3001
4
+ ahuora_builder/flowsheet_manager.py,sha256=sesW2Y68zkGjdpOGtkMREdrtBcsowRPN3y5aAeOSCh4,22973
5
+ ahuora_builder/flowsheet_manager_type.py,sha256=wDeEZB4nlNbRCdfIZ2-WS2Wx6NMO2IdXEocwSGSIhXM,778
6
+ ahuora_builder/generate_python_file.py,sha256=Pq-bAz-L8tDeTxi-tili663na03jT0RlJK-pW-1zpxg,18865
7
+ ahuora_builder/ml_wizard.py,sha256=s4D7i0q51NvQQnnfSB5Y5iruA31u9VOXVZpA1LGveTo,3338
8
+ ahuora_builder/port_manager.py,sha256=NtTtoT53UHQkS86xdr8UoYFf1x0aMYYhz9DIihO9fUU,541
9
+ ahuora_builder/properties_manager.py,sha256=JMpC1pYBE0o8V_ddTLfe1fLSMBA4OPIlMw1FfAph5TI,2013
10
+ ahuora_builder/property_package_manager.py,sha256=vBnwSPM2BXnX7uuYg7Q7w6QVvZpcyTcWi5kaGYayT2Q,2866
11
+ ahuora_builder/solver.py,sha256=u67Cdxpm-JhV-LAxVahEkxxIrg-oiglXd1QC4FPDlfI,1354
12
+ ahuora_builder/tear_manager.py,sha256=EpfM332VWRcA9FjqmpPIHDoknPoWKiNMQf5jVg7ZxRQ,3656
13
+ ahuora_builder/timing.py,sha256=l3g5sWF6U7grq3cDiWGwzjQcp0dJe-WeH8fhBdlhDWA,1723
14
+ ahuora_builder/unit_model_manager.py,sha256=M72WIoUNpJVgmb0SLJHMtN-yxM13yXPcEJI_ajLD99s,1766
15
+ ahuora_builder/custom/PIDController.py,sha256=cb5JjUOMIJmEYxOuO6hFzQendX9ch7GUxCEQw7u9LTQ,20441
16
+ ahuora_builder/custom/PySMOModel.py,sha256=dQmmRr7nDbk_i1FpfN6q2utxdQrW4kLZ0o0mrEZ5FPc,8086
17
+ ahuora_builder/custom/SimpleEffectivenessHX_DH.py,sha256=EXTXkhOACECg5LdWa2CxR-FrTFyjCQGTfuoGPEnHIXs,28745
18
+ ahuora_builder/custom/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
19
+ ahuora_builder/custom/add_initial_dynamics.py,sha256=vGIFBbWokXgXJh0j9IOL9MgcAsCosn285CFyGYupksA,1919
20
+ ahuora_builder/custom/custom_compressor.py,sha256=07sgI3naeHp7vVL50vJE-KLlxBYDDS1bIVPP76s6AOI,3706
21
+ ahuora_builder/custom/custom_cooler.py,sha256=T4-tkJWLdVpSpU8jD7T3jx3UzFV8G2KrqPvQJznEOvk,1071
22
+ ahuora_builder/custom/custom_heat_exchanger.py,sha256=mySe5zL7Ywm2ieRqckA1_gqFG7ahdlODRIr2wke2SDE,7346
23
+ ahuora_builder/custom/custom_heat_exchanger_1d.py,sha256=5APxiDRIx0MwkctUfU-Pa6XR2_y-mX-8EONz0-WRRu4,10100
24
+ ahuora_builder/custom/custom_heater.py,sha256=BPehWcjFrCzCWJMGHS8QMXprkJHaP9Rih6_zUGDjFRU,1449
25
+ ahuora_builder/custom/custom_pressure_changer.py,sha256=WElH4w8brHToCnVBXj9-eILfI5jM6X2jr2rmwPI74Pw,1155
26
+ ahuora_builder/custom/custom_pump.py,sha256=ARucJLTd1fnS6Ba2FL4-LfqPH4Jby94-LtNcJhEUpds,3676
27
+ ahuora_builder/custom/custom_separator.py,sha256=olwi5WlmYnLf2y-QjKPr-Ud6cceSAI6XkwMxrXIWo-w,18144
28
+ ahuora_builder/custom/custom_tank.py,sha256=b0eEfDX9JxEUqk0NptTwfZ-xZwtwmVwwkgw_reJJ6xI,5494
29
+ ahuora_builder/custom/custom_turbine.py,sha256=3VGHJk0dVo981iDv_sMH1b-NuIqv52LKJPheFpb2ETo,4459
30
+ ahuora_builder/custom/custom_valve.py,sha256=K4Bb6qEJ6XmRddfR0KMyuNjEA_mdwnSt1DIihxzZEqg,11457
31
+ ahuora_builder/custom/custom_variable.py,sha256=-ol4Wdulw56obnlBmjgzZNTH9RGVYtynYfk-Psfzauc,983
32
+ ahuora_builder/custom/direct_steam_injection.py,sha256=-TrsmgZ6OiyDsi7HWl_Vw-fI4nxE84T_EltSwbLLH1Q,14379
33
+ ahuora_builder/custom/hda_ideal_VLE.py,sha256=sVC4WVd_tSBnrEOJCfG3zjAt6cbtneEb_3OtruCELxs,49254
34
+ ahuora_builder/custom/hda_reaction.py,sha256=MTgZVejEBvmV05oJ1VWAtzrm59xXQHUGL8ycfDoumrw,5861
35
+ ahuora_builder/custom/heat_exchanger_1d_wrapper.py,sha256=qe0ksF0xtnAVvnVDzaRICB9dUFXEFzxCWyeJ-Dn2hWQ,1147
36
+ ahuora_builder/custom/integration_block.py,sha256=GP3zINfTIGC9xSf0Xo4nZ_rB8blabFu7cfKZuurbkD8,3413
37
+ ahuora_builder/custom/inverted.py,sha256=LkmntDDBdTHij8r084Xfzq1BTA23uoZQIUV5p955jsE,3173
38
+ ahuora_builder/custom/performance_curves.py,sha256=Nqnn8clbgv-5l0PgxcTOldg8mkMKrFn4TvPL-rYUUGg,1
39
+ ahuora_builder/custom/simple_separator.py,sha256=8QppHBMZW-BU8vUiroiBvEckBk8QmmPrUHwtVpZsiz0,25362
40
+ ahuora_builder/custom/translator.py,sha256=2gAEmDJkPxQngpEu1FoekefTRDB8jodF4jYG0hE0uJE,5051
41
+ ahuora_builder/custom/updated_pressure_changer.py,sha256=gZPe4imvB5a8jAY6lYa_WI-29NExWYej1FGK-VNMwcc,53894
42
+ ahuora_builder/custom/valve_wrapper.py,sha256=ZivFfKifXfJ4Obt12NC-b51os5004EJbtc8Vb5tnqVE,1557
43
+ ahuora_builder/custom/water_tank_with_units.py,sha256=Hx8w-nI2pRbgQe93iqx_qSOO04aSJrLitgsKFxNQpm8,17187
44
+ ahuora_builder/custom/energy/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
45
+ ahuora_builder/custom/energy/acBus.py,sha256=tswNtkNuTNRAV96102jXLWjshtWWeD037xiRByvzYWU,9514
46
+ ahuora_builder/custom/energy/ac_property_package.py,sha256=uXUi_9zCIClQG5xW8lcpzAjXcH7Qr-R8aH30MoIPnQA,10489
47
+ ahuora_builder/custom/energy/battery.py,sha256=ZK6yTe6QUshSJPXL7ycGjmyP4vQ2EbilUbSAHhC-Ieo,5632
48
+ ahuora_builder/custom/energy/bus.py,sha256=GrprJ91ROZlMnDwYPER0gcyZiObwBhgERaak5xGjdww,6198
49
+ ahuora_builder/custom/energy/energy_mixer.py,sha256=1ORJCT_8GqO2Ut8zjafOZy3vKjInxSvz-m_KgF8m_YU,6853
50
+ ahuora_builder/custom/energy/energy_splitter.py,sha256=PP6Wuu3VIedG9-9QFfDy82JLNfMjuspv1O0NfYhs2n0,7772
51
+ ahuora_builder/custom/energy/grid.py,sha256=kIlvkq0NfqfqfP5RvJ1hd7cyiV_6j0H0--njXgexg9M,6228
52
+ ahuora_builder/custom/energy/hydro.py,sha256=AePIB-moVvN743Jh9L9UJ47H212atpL-IUyvnAbHW6A,5695
53
+ ahuora_builder/custom/energy/link.py,sha256=ashRAbU2THnx7uhX_QndpygSzCvnZymd-72fXHzDlcY,4897
54
+ ahuora_builder/custom/energy/load.py,sha256=LjkClcRALQuRjFH8Qg29894gDvDj1d_gEunhiwhy-Pg,5611
55
+ ahuora_builder/custom/energy/mainDistributionBoard.py,sha256=9ljp2Ad8D5yoW8UohZPB3wZv-BFLIA1nuCd-sbqJxrA,8760
56
+ ahuora_builder/custom/energy/power_property_package.py,sha256=oJ-x1r1LJNowbnWsaAuEK6lncXDBGL9wdtEc-mBp4vA,9460
57
+ ahuora_builder/custom/energy/solar.py,sha256=QX2AOfJENjVkQWND7VtarNvMKoBRE8jBe2gybeF9Dpo,5664
58
+ ahuora_builder/custom/energy/storage.py,sha256=bOW7UkfAeXYuV4WezzDuc7cX_gboNjXF7nPkHSaaqVM,8352
59
+ ahuora_builder/custom/energy/storage_wrapper,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
60
+ ahuora_builder/custom/energy/transformer.py,sha256=hAvZ9ijR4bc2-Gn6mPxv9f-Rth64eIwaL7UZ-THMrGo,6696
61
+ ahuora_builder/custom/energy/transformer_property_package.py,sha256=YitSc8inONfqVfOf_duTBTX6e7B292ili8AJDhzrOVI,10011
62
+ ahuora_builder/custom/energy/transmissionLine.py,sha256=d_h2zcnduA0QUgmizIpMqMR_5Kg3xyhCo1VeyIuU5jE,7836
63
+ ahuora_builder/custom/energy/wind.py,sha256=Ncx9HaCjplSidr2_qZ3JsAXo-3irFi8veL7wdODAib4,6735
64
+ ahuora_builder/custom/energy/tests/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
65
+ ahuora_builder/custom/energy/tests/test_bus.py,sha256=DKlPVdDwHDx5rCb_cvJAZgLqFZFOgGD6lq-8Bof8pGI,1487
66
+ ahuora_builder/custom/energy/tests/test_energy_mixer.py,sha256=bWgKdO5FZRKLLC1vAAfM1qv06u90GOFq9Jz89ojEykA,1560
67
+ ahuora_builder/custom/energy/tests/test_mdb.py,sha256=022WZRVhXyNHC0jfaRIATMlYyhWW6k0mR5RCxO1hdB8,1990
68
+ ahuora_builder/custom/reactions/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
69
+ ahuora_builder/custom/reactions/hda_stoich.py,sha256=gZll6tzActEVjpWsVhfvQfwa3WiayPenIUrNLYTkVHs,592
70
+ ahuora_builder/custom/tests/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
71
+ ahuora_builder/custom/tests/test_SimpleEffectivenessHX_DH.py,sha256=TZZaJ2psa3t_EbHZFqS4PlKbRGgqPSI5h69GoUpG8Jk,4241
72
+ ahuora_builder/custom/tests/test_custom_tank.py,sha256=VEVQKr4z74iz6Twk6B1Ic7l6KZkR4L1v5Nz-vOQfz_M,2804
73
+ ahuora_builder/custom/tests/test_direct_steam_injection.py,sha256=-y8KahggUJIxNVkU-q8kjpNrOhm7uP8RLkfYSa4eWDo,1854
74
+ ahuora_builder/custom/tests/test_simple_separator.py,sha256=K43MmfAUdLMhN2Ld4IAYbHczvPNe0uhJSzUfWwDLEoU,1566
75
+ ahuora_builder/custom/tests/test_waterpipe.py,sha256=Jg4FodRBe6PyXMiWP56EUbX0txMEOwB0RGH2PKxvkdc,1658
76
+ ahuora_builder/custom/thermal_utility_systems/desuperheater.py,sha256=vQa6X7YUTj7KQX5Zzzjnhe834IrUjvehkyMHlHpM4M8,21749
77
+ ahuora_builder/custom/thermal_utility_systems/header.py,sha256=H3OuK7AKJnF4zezRrQzT8KLUXN_cOUlfdkgy21HztPg,33179
78
+ ahuora_builder/custom/thermal_utility_systems/simple_heat_pump.py,sha256=QkOyjJidU3-7LrIoTmnD4nDYH9Bc78UavTJzujGAJA8,22188
79
+ ahuora_builder/custom/thermal_utility_systems/steam_header.py,sha256=cAoh5g2hehont22ymtxupBzS8xBGubmdQYQmioHkV9E,13206
80
+ ahuora_builder/custom/thermal_utility_systems/steam_user.py,sha256=6Rn7IfjaacueMaVkVz4RAvq_TxfA0NLxztYsp397xCs,34674
81
+ ahuora_builder/custom/thermal_utility_systems/temp.py,sha256=XW4alQLQvwDVsngEf02J-LT0Jn5nFZDQSfy-zMeHSEA,13094
82
+ ahuora_builder/custom/thermal_utility_systems/willans_turbine.py,sha256=PnGpYNKB0Es8ncN48w7YC55dUiied61rfIpSWPc5LTU,33196
83
+ ahuora_builder/custom/thermal_utility_systems/tests/test_desuperheater.py,sha256=3jY7HA2GgZf4tkbfLpbr4vhZrhnnSYpCnXAWAQdGwio,5010
84
+ ahuora_builder/custom/thermal_utility_systems/tests/test_header.py,sha256=Ijxe22JiNS-WT2PXLtGvt5pcEsqZyClilQNlrz4O6GI,35277
85
+ ahuora_builder/custom/thermal_utility_systems/tests/test_ntu_hx.py,sha256=3sHOup357b-6qILOmrYba1UNq8Tu79Tq51zWYEXg56w,4500
86
+ ahuora_builder/custom/thermal_utility_systems/tests/test_simple_heat_pump.py,sha256=sq0yoTmMzf3QE36zHXX-1dj0CI33uityvGkR0mqhrZQ,4545
87
+ ahuora_builder/custom/thermal_utility_systems/tests/test_steam_header.py,sha256=sUuemMmdenA0SmHLgXu2N59CaiIaZ_oxICu3L6y0rYY,25585
88
+ ahuora_builder/custom/thermal_utility_systems/tests/test_steam_user.py,sha256=0C2Jva_CS_l6tUGIZT_RdSlsXq1P-KmtUbKTyfMnPfI,10270
89
+ ahuora_builder/custom/thermal_utility_systems/tests/test_waterpipe.py,sha256=A9sNm9gKv5ncUYS6xvoajALemiLWkLc_gK0KWoNCEW0,1178
90
+ ahuora_builder/custom/thermal_utility_systems/tests/test_willans_turbine.py,sha256=1Xzq-vAmGUpOWNE3yBr1li_pnB9ukDCpq382IJS0usM,9959
91
+ ahuora_builder/diagnostics/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
92
+ ahuora_builder/diagnostics/infeasibilities.py,sha256=TVauLLQPzGRII6V-eD4BjZVF5-pGnoENtRfISktvwiw,1836
93
+ ahuora_builder/diagnostics/tests/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
94
+ ahuora_builder/diagnostics/tests/test_infeasibilities.py,sha256=4p22oMTr2vUxzoTtRIruKPSupqU9MiV31QT1x_xtypk,684
95
+ ahuora_builder/methods/BlockContext.py,sha256=TXm6_3AVTKl5zwGFv0bquh_NTtIBq78mSk5cx8pQwO4,4647
96
+ ahuora_builder/methods/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
97
+ ahuora_builder/methods/adapter.py,sha256=N7WGjd1a0nmwLbtuqdrbiv7GbI1KmqyDjB8rka_p7YA,16908
98
+ ahuora_builder/methods/adapter_library.py,sha256=whwU0oC5UsQtNYVmzFFSSZvBug52M0HKKHgigyh58EA,20740
99
+ ahuora_builder/methods/adapter_methods.py,sha256=XUd5qYgXLJOlFB1V8sDZlAu7ksAmzJuSYa1UDjFk_VQ,2674
100
+ ahuora_builder/methods/expression_parsing.py,sha256=EhEE-zYjcFNpyzFLG8SUytoQ26VYBUsZgHDZ9dpLa_o,4540
101
+ ahuora_builder/methods/load_unit_model.py,sha256=omG-aD2iOrYTk_Chg0nGga73jhybwGoAG5GRoHeK9f8,6688
102
+ ahuora_builder/methods/slice_manipulation.py,sha256=kgR5iW8hhQTjsfF_E1zyr5z_uVHQZig4ufiEuddoRjE,228
103
+ ahuora_builder/methods/units_handler.py,sha256=TRZq-hkvqqCAgEUQuZcXbbVA2ssmYK5op-mgeBhpvFw,4028
104
+ ahuora_builder/methods/tests/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
105
+ ahuora_builder/methods/tests/test_expression_parsing.py,sha256=C2-JD69d0elLI2s_kR33Vs1NtNw5nZOnGDpASHb1KEc,434
106
+ ahuora_builder/tests/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
107
+ ahuora_builder/tests/test_generate_python_file/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
108
+ ahuora_builder/tests/test_generate_python_file/test_generate_python_file.py,sha256=07n3m86D8YfIITORVQk8kl0kgfOdxmeKv3MM4aZPBtI,4380
109
+ ahuora_builder/tests/test_generate_python_file/configurations/compressor_generated.py,sha256=eh8GIk83hXZDlw8ndJw3vYZdy2mlpB0IFiNOnzsMDrU,1893
110
+ ahuora_builder/tests/test_generate_python_file/configurations/heat_exchanger_generated.py,sha256=3sJICneLtcYCG_Z_EECIftjl_9ybtcvsBho4wKpKQpc,2484
111
+ ahuora_builder/tests/test_generate_python_file/configurations/pump_generated.py,sha256=X6Ud1rSjL5hTArAkGtAzaeZSJwdmHPKkZ94RUtf2tqk,2379
112
+ ahuora_builder/tests/test_generate_python_file/configurations/recycle_generated.py,sha256=rCtCfIWgXwISt4UcI1iD7fa80ZBKomy2mLjKWF8aS6E,2159
113
+ ahuora_builder/tests/test_solver/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
114
+ ahuora_builder/tests/test_solver/test_solve_models.py,sha256=3S_rRxGEQ2nyff0pMnH_V0ZgvKn-ZWGdo_v8KYvoowo,9942
115
+ ahuora_builder/tests/test_solver/configurations/BT_PR.json,sha256=hs3J4fyAZ-Rlq3ndS5XPSpDBPShkxY7he-UYAis_FIg,1966
116
+ ahuora_builder/tests/test_solver/configurations/BT_PR_solved.json,sha256=8rY-CUOoKdsWBZ_A2SSVmpT9jJuBqS4f4PTkzEX2gX4,1557
117
+ ahuora_builder/tests/test_solver/configurations/bus.json,sha256=--R5qqPejpjFjOpOjpAJGk4aXkYXhobgSjLKVqigbfc,2687
118
+ ahuora_builder/tests/test_solver/configurations/bus_solved.json,sha256=0Z0nshDtC1DU3bgFRZbLtUkRQd2SLp-4boYGUXQE40U,1175
119
+ ahuora_builder/tests/test_solver/configurations/compound_separator.json,sha256=HklVhczm_36XV5CodI5fco4bk2rdSmD8O3OY-YXuGYM,13202
120
+ ahuora_builder/tests/test_solver/configurations/compound_separator_solved.json,sha256=MNkbMy0byN0pPH9zeSmCG25KRagMCjDRKCud0fcbRrs,10931
121
+ ahuora_builder/tests/test_solver/configurations/compressor.json,sha256=nfNpaV9SW6U9EicYpHapnlV1ChOmpgMpAsCpkiAUwTY,1371
122
+ ahuora_builder/tests/test_solver/configurations/compressor_solved.json,sha256=fz4lRuNNvqUH7OzxnaCZXGWaVsC73fp1oWHiKSy3ATU,1801
123
+ ahuora_builder/tests/test_solver/configurations/constraints.json,sha256=cb8VBO83A9l8JALtqAlFrfk__6fUpTchm5tkkPNqKy0,1519
124
+ ahuora_builder/tests/test_solver/configurations/constraints_solved.json,sha256=SwjWkDVrwGjlSES5rwoCnYbwwLvBCuaTdekvvXyhoKU,1551
125
+ ahuora_builder/tests/test_solver/configurations/control.json,sha256=R9Nacn5__ufAPd9iBC9qPPzoU5E2N0NA3droi9dY8GI,1497
126
+ ahuora_builder/tests/test_solver/configurations/control_solved.json,sha256=4GwbwYnju-uWDHvVc3dpAx_oF4d-bTfEBC0Dn3zQXSw,1786
127
+ ahuora_builder/tests/test_solver/configurations/dynamic_tank.json,sha256=lJd8q26iuiuUEKuMDLW6PrOr4NE-NXWIeDeubCRjyGg,29521
128
+ ahuora_builder/tests/test_solver/configurations/dynamic_tank_solved.json,sha256=LfvI3ROdyQAjAQptl6emEB0iYcitD6CuLPpvTT-rpkY,24866
129
+ ahuora_builder/tests/test_solver/configurations/elimination.json,sha256=uTgNcguBH3dtKaZ5HjMqNfI4nfcj_ciAl03dZ_eWMFE,1473
130
+ ahuora_builder/tests/test_solver/configurations/elimination_solved.json,sha256=gADmU3OJ6lkcIW8M-LfLIEg1y_g5t3J3hFVF1CluFJE,1795
131
+ ahuora_builder/tests/test_solver/configurations/expressions.json,sha256=eztW4vbpjn7SU3EQuLlf_Lp6bYrgm08053D0P4uhXt4,2041
132
+ ahuora_builder/tests/test_solver/configurations/expressions_solved.json,sha256=rreo-kIzMAGTZOI1Wmh2gWTUORTmVWib6qS_Ef7c3Ms,2678
133
+ ahuora_builder/tests/test_solver/configurations/header.json,sha256=2wE4gSIfxCzDG3M924zvsTj8NTNpetbuuqPNmmO4PTE,49075
134
+ ahuora_builder/tests/test_solver/configurations/header_solved.json,sha256=QBBx5fwLtAPokJkCW28P0dm5LlvE-ltH5lfGB73pk0U,21489
135
+ ahuora_builder/tests/test_solver/configurations/heat_exchanger.json,sha256=Sy73_MndZYew40AsFQ8i0Yhnf15x9uik_HDKEc-0DUY,2506
136
+ ahuora_builder/tests/test_solver/configurations/heat_exchanger_solved.json,sha256=IzkNt2SAffR43qrGDKJ0ooTh6JU8rq5ThZBpXtbStX8,2799
137
+ ahuora_builder/tests/test_solver/configurations/heat_pump.json,sha256=tFXzGVgGorSiqWkCtcYjCFGobFe8byt3AdLXy983ItI,3929
138
+ ahuora_builder/tests/test_solver/configurations/heat_pump_solved.json,sha256=3wFsAwuxk8P7LG89D7nCQZgWmN5Rp7WGvyDY59JNUbo,2672
139
+ ahuora_builder/tests/test_solver/configurations/machine_learning.json,sha256=Yz8vitIHx6BX5v-CYyuU-fqzohPItuREU2BsN3X1_e0,101391
140
+ ahuora_builder/tests/test_solver/configurations/machine_learning_solved.json,sha256=xEEyaGhA8CD6Q0FnY8lokcqBOJ6p2KHVd3IdaPd7HrE,7625
141
+ ahuora_builder/tests/test_solver/configurations/mass_flow_tear.json,sha256=2E-uiyXLCZorCIBIDYsvp3aP_D_JrB79d978-IzIdCA,2275
142
+ ahuora_builder/tests/test_solver/configurations/mass_flow_tear_solved.json,sha256=Xb2mg8BSf5UFuonYCfVUWFDvNifu59Jw7Tj3e4OSv5M,1761
143
+ ahuora_builder/tests/test_solver/configurations/milk_heater.json,sha256=CQeS1rWiUe1v4-xFhy6Cjy8sWblJJrZRNz6nczj6jd4,13628
144
+ ahuora_builder/tests/test_solver/configurations/milk_heater_solved.json,sha256=mZ9Q4i8Vn9aFCJqPW7PgXw-UShNo2h25fK1Oj0ZNkoI,9205
145
+ ahuora_builder/tests/test_solver/configurations/mixer.json,sha256=a1-1GXwIGa_8Fb9ooDhx2uL3RWJRiLWj6WkLLApmk5o,1547
146
+ ahuora_builder/tests/test_solver/configurations/mixer_solved.json,sha256=g7ccbMK35rDEZEnvxh3DBq8QBDY6NqS4lwr8aroTklM,2114
147
+ ahuora_builder/tests/test_solver/configurations/optimization.json,sha256=Dl_JDHJ8nvTv95MRc67h81qsvAJ63eUZ6b28nxUug6s,1880
148
+ ahuora_builder/tests/test_solver/configurations/optimization_solved.json,sha256=842EXXFK8m6hy_p-nK5KTPRuYlX4880H3SMVoiRIRy0,1592
149
+ ahuora_builder/tests/test_solver/configurations/propane_heat_pump.json,sha256=DP7-PuTCtxidK-6RPUCgnNNMc0oXxdxpUdL01TDss4A,5187
150
+ ahuora_builder/tests/test_solver/configurations/propane_heat_pump_solved.json,sha256=e0ACrKlGlxmX0sREn-F8zYizpTHzzIseQAwOnyght4Y,4168
151
+ ahuora_builder/tests/test_solver/configurations/propane_recycle.json,sha256=ifWh23iZxiucwH8n028WIxQpJWLxeJAHPEoyyjJmokQ,4022
152
+ ahuora_builder/tests/test_solver/configurations/propane_recycle_solved.json,sha256=iAOfcz0Do82xTeLEYULLkIECiAFvhD0L9bfNQdkm1HQ,2724
153
+ ahuora_builder/tests/test_solver/configurations/pump.json,sha256=Zt4fDD2ExexXRtnj17KtZ_5rPC7g-GeW6ytkepb3Kbs,1868
154
+ ahuora_builder/tests/test_solver/configurations/pump_solved.json,sha256=0A5w2166frvS_tx0NU5cM-1IR1rGmi7BGcdil7EXxVA,1504
155
+ ahuora_builder/tests/test_solver/configurations/pump_unit_conversions.json,sha256=JeTKGD1idwBnXAc15V1xD4Wl0lYaUUZbyrGCiA3dwjw,1825
156
+ ahuora_builder/tests/test_solver/configurations/recycle.json,sha256=UL7-FlkoZtFVVVqlxRawGFG7DtagOTIt5QL9ZrNmiaw,1527
157
+ ahuora_builder/tests/test_solver/configurations/recycle_solved.json,sha256=-sU6IYkVbio9kLXHMQHTC4FIjmucI3OdwLq1aOSDHU4,1281
158
+ ahuora_builder/tests/test_solver/configurations/sb_vapor_frac.json,sha256=1RyLqkIxGl1Gls6jPqy1OULAJDsZLRimNrau4AOVBRA,698
159
+ ahuora_builder/tests/test_solver/configurations/sb_vapor_frac_solved.json,sha256=rMrGcRyI8UB10w47pqtSZZI1U_ZuttCqGhClrueBR-Y,580
160
+ ahuora_builder/tests/test_solver/configurations/solar.json,sha256=j2mF9wTcoIT2f0jURjWWXCVdM1oqlI8cNX11qCcHxqo,1329
161
+ ahuora_builder/tests/test_solver/configurations/solar_solved.json,sha256=42DkeYXJx9BVKSA7pVQFZZ1UuFB9BwM5d4X-p42HJkY,1170
162
+ ahuora_builder/tests/test_solver/configurations/vapor_frac_target.json,sha256=AHdbraTo-mBK2wAwZX_MGVExDIja4Kypa351goyc6Qw,2085
163
+ ahuora_builder/tests/test_solver/configurations/vapor_frac_target_solved.json,sha256=-CE0urcoNiqqLOvWjGw6Sug7lbV-Zdig_nZc9V_DykI,1768
164
+ ahuora_builder/types/__init__.py,sha256=AbpHGcgLb-kRsJGnwFEktk7uzpZOCcBY74-YBdrKVGs,1
165
+ ahuora_builder-0.1.0.dist-info/METADATA,sha256=Er5u-ZF9LxaQUavG9eBy14M3-0QLV5XGDX06Mt56OEs,422
166
+ ahuora_builder-0.1.0.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
167
+ ahuora_builder-0.1.0.dist-info/RECORD,,
@@ -0,0 +1,4 @@
1
+ Wheel-Version: 1.0
2
+ Generator: hatchling 1.28.0
3
+ Root-Is-Purelib: true
4
+ Tag: py3-none-any