releso.mesh.MixdMesh

class releso.mesh.MixdMesh(*, save_location: Path, logger_name: str | None = None, path: str | Path | None = None, export: MeshExporter | None = None, dimensions: ConstrainedIntValue, mxyz_path: FilePath | None = None, mien_path: FilePath | None = None, hypercube: bool = True)

Bases: Mesh

Class used to read in the correct mixd mesh file and load it.

__init__(**data: Any) None

Constructor for the ReLeSO basemodel object.

Methods

adapt_export_path(environment_id)

If placeholder in export path insert environment_id into it.

convert_to_pathlib_add_datetime(v)

Add timestamp to save_location, of applicable.

get_export_path()

Direct return of object variable.

get_logger()

Gets the currently defined environment logger.

get_mesh()

Calls the correct method to load the mesh for the gustaf library.

set_logger_name_recursively(logger_name)

Set the logger_name variable for all child elements.

Attributes

mxyz_path

Please use either the path variable xor the mxyz variable, since if used both the used mxyz path might not be the one you think.

mien_path

Please use either the path variable xor the mien variable, since if used both the used mien path might not be the one you think.

hypercube

dimensions

Number of dimensions of the mesh.

path

path to the mesh file (might be not used in case of mixd )

export

Path to the default export location of the mesh during environment operations.

save_location

Definition of the save location of the logs and validation results.

logger_name

name of the logger.

dimensions: ConstrainedIntValue

Number of dimensions of the mesh.

get_mesh() gustaf.Volumes | gustaf.Faces

Calls the correct method to load the mesh for the gustaf library.

Note

There is an error in a version of gustaf during the loading process . Please check with the maintainer of this package if you have trouble.

Returns:

Mesh in gustaf library format.

Return type:

gustaf.Mesh

mien_path: FilePath | None

Please use either the path variable xor the mien variable, since if used both the used mien path might not be the one you think.

mxyz_path: FilePath | None

Please use either the path variable xor the mxyz variable, since if used both the used mxyz path might not be the one you think.