Skip to content

Commit

Permalink
fixing pysmo path
Browse files Browse the repository at this point in the history
  • Loading branch information
JavalVyas2000 committed Feb 15, 2024
1 parent 122a59a commit 11b50af
Showing 1 changed file with 7 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,8 @@
from idaes.core.surrogate.surrogate_block import SurrogateBlock
from idaes.core.surrogate.pysmo_surrogate import PysmoSurrogate

import os

from pyomo.util.model_size import build_model_size_report

# Some more information about this module
Expand Down Expand Up @@ -269,9 +271,11 @@ def _make_state_vars(self):
units=units.kJ/units.kmol,
doc='Enthalpy [kJ/ kmol]')

inputs=[self.pressure,self.temperature]
outputs=[self.enth_mol,self.entr_mol]
self.pysmo_surrogate = PysmoSurrogate.load_from_file("pysmo_poly_surrogate.json")
inputs = [self.pressure,self.temperature]
outputs = [self.enth_mol,self.entr_mol]
curr_dir = os.path.dirname(__file__)
rel_path = os.path.join(curr_dir,"pysmo_poly_surrogate.json")
self.pysmo_surrogate = PysmoSurrogate.load_from_file(rel_path)
self.surrogate_enth = SurrogateBlock()
self.surrogate_enth.build_model(
self.pysmo_surrogate,
Expand Down

0 comments on commit 11b50af

Please sign in to comment.