Skip to content

Commit

Permalink
update system factory param to match facility param
Browse files Browse the repository at this point in the history
  • Loading branch information
yoelcortes committed Aug 5, 2024
1 parent 02c4062 commit e111201
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion Bioindustrial-Park
8 changes: 4 additions & 4 deletions biosteam/process_tools/system_factory.py
Original file line number Diff line number Diff line change
Expand Up @@ -226,7 +226,7 @@ def __call__(self, ID=None, ins=None, outs=None,
relative_molar_tolerance=None,
temperature_tolerance=None,
relative_temperature_tolerance=None,
box=False, priority=None,
box=False, network_priority=None,
**kwargs
):
fthermo = self.fthermo
Expand All @@ -253,17 +253,17 @@ def __call__(self, ID=None, ins=None, outs=None,
temperature_tolerance=temperature_tolerance,
relative_temperature_tolerance=relative_temperature_tolerance,
)
if priority is not None: box = True
if network_priority is not None: box = True
if box:
if rename:
unit_registry = bst.main_flowsheet.unit
irrelevant_units = tuple(unit_registry)
unit_registry.untrack(irrelevant_units)
if priority is None:
if network_priority is None:
module = bst.Module(ins=ins, outs=outs)
else:
module = bst.FacilityModule(ins=ins, outs=outs)
module.network_priority = priority
module.network_priority = network_priority
ins = tuple([module.auxin(i) for i in module.ins])
outs = tuple([module.auxout(i) for i in module.outs])
with bst.Flowsheet(ID), (bst.MockSystem() if mockup else bst.System(**options)) as system:
Expand Down

0 comments on commit e111201

Please sign in to comment.