MlFmuProcess

class mlfmu.api.MlFmuProcess(command: MlFmuCommand, source_folder: Path | None = None, ml_model_file: Path | None = None, interface_file: Path | None = None, fmu_output_folder: Path | None = None)

Bases: object

Represents the ML FMU process.

This class encapsulates the functionality to run the ML FMU process in a self-terminated loop. It provides methods to control the execution of the process and manage the number of runs.

__init__(command: MlFmuCommand, source_folder: Path | None = None, ml_model_file: Path | None = None, interface_file: Path | None = None, fmu_output_folder: Path | None = None) → None

Instantiate the MlFmuProcess.

Parameters:
  • command (MlFmuCommand) – The command to be executed by the process.

  • source_folder (Path | None, optional) – The path to the source folder., by default None

  • ml_model_file (Path | None, optional) – The path to the ML model file., by default None

  • interface_file (Path | None, optional) – The path to the interface file., by default None

  • fmu_output_folder (Path | None, optional) – The path to the FMU output folder., by default None

Methods

__init__(command[, source_folder, ...])

Instantiate the MlFmuProcess.

run()

Run the mlfmu process.

Attributes

command

The command to be executed by the process.

builder

The builder object responsible for building the FMU.

run() → None

Run the mlfmu process.

Runs the mlfmu process in a self-terminated loop.

builder: MlFmuBuilder

The builder object responsible for building the FMU.

command: MlFmuCommand

The command to be executed by the process.