bluemira.codes.process._setup

Defines the setup task for running PROCESS.

Classes

Setup

Setup Task for running PROCESS.

Functions

_make_writer(→ bluemira.codes.process.api.InDat)

create_template_from_path(...)

Module Contents

class bluemira.codes.process._setup.Setup(params: dict | bluemira.base.parameter_frame.ParameterFrame, in_dat_path: str, problem_settings: dict[str, float | str] | None = None)

Bases: bluemira.codes.interface.CodesSetup

Inheritance diagram of bluemira.codes.process._setup.Setup

Setup Task for running PROCESS.

Parameters:
  • params (dict | bluemira.base.parameter_frame.ParameterFrame) – The bluemira parameters for this task.

  • in_dat_path (str) – The path to where the IN.DAT file should be written.

  • problem_settings (dict[str, float | str] | None) – The PROCESS parameters that do not exist in bluemira.

MODELS: ClassVar
params: bluemira.codes.process.params.ProcessSolverParams
in_dat_path
problem_settings
run()

Write the IN.DAT file and store in the main PROCESS folder.

Bluemira params with param.mapping.send == True will be written to IN.DAT.

runinput()

Write the IN.DAT file and store in the main PROCESS folder.

Bluemira outputs will not be written to the file.

_write_in_dat(*, use_bp_inputs: bool = True)

Write the IN.DAT file and stores in the main PROCESS folder.

Parameters:

use_bp_inputs (bool) – Option to use bluemira values as PROCESS inputs. Used to re-run PROCESS within a bluemira run. If False, runs PROCESS without modifying inputs. Default, True

_validate_models(writer)

Loop through known models, find the PROCESS output value for the model, and convert the type to its corresponding Enum value.

bluemira.codes.process._setup._make_writer(template_in_dat: dict[str, bluemira.codes.process.api._INVariable]) bluemira.codes.process.api.InDat
Parameters:

template_in_dat (dict[str, bluemira.codes.process.api._INVariable])

Return type:

bluemira.codes.process.api.InDat

bluemira.codes.process._setup.create_template_from_path(template_in_dat: str | pathlib.Path) bluemira.codes.process._inputs.ProcessInputs
Parameters:

template_in_dat (str | pathlib.Path)

Return type:

bluemira.codes.process._inputs.ProcessInputs