artist.data_parser.h5_scenario_parser

Functions

surface_config(...)

Load a surface configuration from an HDF5 scenario file.

kinematic_deviations(→ tuple[torch.Tensor, ...)

Load kinematic deviations from an HDF5 scenario file.

rigid_body_deviations(→ tuple[torch.Tensor, torch.Tensor])

Load kinematic deviations for a rigid body kinematic from an HDF5 scenario file.

actuator_parameters(→ tuple[torch.Tensor, torch.Tensor])

Load actuator parameters from an HDF5 scenario file.

linear_actuators(→ tuple[torch.Tensor, torch.Tensor])

Load actuator parameters for linear actuators from an HDF5 scenario file.

ideal_actuators(→ tuple[torch.Tensor, torch.Tensor])

Load actuator parameters for ideal actuators from an HDF5 scenario file.

Module Contents

artist.data_parser.h5_scenario_parser.surface_config(prototype: bool, scenario_file: h5py.File, device: torch.device | None = None) artist.scenario.configuration_classes.SurfaceConfig

Load a surface configuration from an HDF5 scenario file.

Parameters

prototypebool

Loading a prototype or an individual surface configuration.

scenario_fileh5py.File

The opened scenario HDF5 file containing the information.

devicetorch.device | None

The device on which to perform computations or load tensors and models (default is None). If None, ARTIST will automatically select the most appropriate device (CUDA or CPU) based on availability and OS.

Returns

SurfaceConfig

The surface configuration.

artist.data_parser.h5_scenario_parser.kinematic_deviations(prototype: bool, kinematic_type: str, scenario_file: h5py.File, log: logging.Logger, heliostat_name: str | None = None, device: torch.device | None = None) tuple[torch.Tensor, torch.Tensor, int]

Load kinematic deviations from an HDF5 scenario file.

Parameters

prototypebool

Loading prototype or individual kinematic deviations.

kinematic_typestr

The kinematic type.

scenario_fileh5py.File

The opened scenario HDF5 file containing the information.

loglogging.Logger

The logger for the scenario loader.

heliostat_namestr | None

The heliostat name, only needed for individual heliostats, not prototypes (default is None).

devicetorch.device | None

The device on which to perform computations or load tensors and models (default is None). If None, ARTIST will automatically select the most appropriate device (CUDA or CPU) based on availability and OS.

Raises

ValueError

If the kinematic type in the scenario file is unknown.

Returns

torch.Tensor

Translation deviation parameters for the kinematic.

torch.Tensor

Rotation deviation parameters for the kinematic.

int

The number of actuators needed for this kinematic type.

artist.data_parser.h5_scenario_parser.rigid_body_deviations(kinematic_config: h5py.File, log: logging.Logger, heliostat_name: str | None = None, device: torch.device | None = None) tuple[torch.Tensor, torch.Tensor]

Load kinematic deviations for a rigid body kinematic from an HDF5 scenario file.

Parameters

kinematic_configh5py.File

The opened scenario HDF5 file containing the information.

loglogging.Logger

The logger for the scenario loader.

heliostat_namestr | None

The heliostat name, only needed for individual heliostats, not prototypes (default is None).

devicetorch.device | None

The device on which to perform computations or load tensors and models (default is None). If None, ARTIST will automatically select the most appropriate device (CUDA or CPU) based on availability and OS.

Returns

torch.Tensor

Translation deviation parameters for the kinematic. Tensor of shape [9].

torch.Tensor

Rotation deviation parameters for the kinematic. Tensor of shape [4].

artist.data_parser.h5_scenario_parser.actuator_parameters(prototype: bool, scenario_file: h5py.File, actuator_type: str, number_of_actuators: int, initial_orientation: torch.Tensor, log: logging.Logger, heliostat_name: str | None = None, device: torch.device | None = None) tuple[torch.Tensor, torch.Tensor]

Load actuator parameters from an HDF5 scenario file.

Parameters

prototypebool

Loading prototype or individual actuator parameters.

scenario_fileh5py.File

The opened scenario HDF5 file containing the information.

actuator_typestr

The actuator type.

number_of_actuatorsint

The number of actuators.

initial_orientationtorch.Tensor

The initial orientation of the heliostat.

loglogging.Logger

The logger for the scenario loader.

heliostat_namestr | None

The heliostat name, only needed for individual heliostats, not prototypes (default is None).

devicetorch.device | None

The device on which to perform computations or load tensors and models (default is None). If None, ARTIST will automatically select the most appropriate device (CUDA or CPU) based on availability and OS.

Raises

ValueError

If the actuator type in the scenario file is unknown.

Returns

torch.Tensor

Non-optimizable actuator parameters for for each actuator in the file.

torch.Tensor

Optimizable actuator parameters for for each actuator in the file.

artist.data_parser.h5_scenario_parser.linear_actuators(actuator_config: h5py.File, number_of_actuators: int, initial_orientation: torch.Tensor, log: logging.Logger, heliostat_name: str | None = None, device: torch.device | None = None) tuple[torch.Tensor, torch.Tensor]

Load actuator parameters for linear actuators from an HDF5 scenario file.

Parameters

actuator_configh5py.File

The opened scenario HDF5 file containing the information.

number_of_actuatorsint

The number of actuators used for a specific kinematic.

initial_orientationtorch.Tensor

The initial orientation of the heliostat.

loglogging.Logger

The logger for the scenario loader.

heliostat_namestr | None

The heliostat name, only needed for individual heliostats, not prototypes (default is None).

devicetorch.device | None

The device on which to perform computations or load tensors and models (default is None). If None, ARTIST will automatically select the most appropriate device (CUDA or CPU) based on availability and OS.

Raises

ValueError

If the file contains the wrong amount of actuators for a heliostat with a specific kinematic type.

Returns

torch.Tensor

Non-optimizable actuator parameters for for each actuator in the file.

torch.Tensor

Optimizable actuator parameters for for each actuator in the file.

artist.data_parser.h5_scenario_parser.ideal_actuators(actuator_config: h5py.File, number_of_actuators: int, device: torch.device | None = None) tuple[torch.Tensor, torch.Tensor]

Load actuator parameters for ideal actuators from an HDF5 scenario file.

Parameters

actuator_configh5py.File

The opened scenario HDF5 file containing the information.

number_of_actuatorsint

The number of actuators used for a specific kinematic.

devicetorch.device | None

The device on which to perform computations or load tensors and models (default is None). If None, ARTIST will automatically select the most appropriate device (CUDA or CPU) based on availability and OS.

Raises

ValueError

If the file contains the wrong number of actuators for a heliostat with a specific kinematic type.

Returns

torch.Tensor

Non-optimizable actuator parameters for each actuator in the file.

torch.Tensor

Optimizable actuator parameters for each actuator in the file.