f4enix.output.eeout.EEOUT#
- class f4enix.output.eeout.EEOUT(filepath: PathLike)#
Bases:
objectRepresentation of an MCNP .eeout output file
This class is used to parse and manipulate a .eeout file. The main feature is the possibility to convert the results to a .vtk format
- Parameters:
filepath (os.PathLike) – path to the .eeout file to be parsed.
- Variables:
filename (str) – name of the original .eeout file
lines (list[str]) – lines of the file stored in memory
info (dict) – contains general informations about the file
n_nodes (int) – number of nodes of the mesh
n_elem (int) – number of elements of the mesh
grid (pv.UnstructuredGrid) – vtk object containing all the parsed data from eeout
Examples
Parse an eeout file and export it to .vtu format
>>> from f4enix.output.eeout import EEOUT ... eeout = EEOUT(r'path/to/file.eeout') ... eeout.export(r'path/to/output/folder')
- Raises:
NotImplementedError – Only 1st and 2nd order tetras are supported
Methods
__init__(filepath)Representation of an MCNP .eeout output file
export(outfolder[, filename, format])Export the eeout to different format.
- export(outfolder: PathLike, filename: str | None = None, format: str = 'vtu') None#
Export the eeout to different format.
at the moment only unstructured mesh vtk (vtu) is the only supported format.
- Parameters:
outfolder (os.PathLike) – path to the output folder where to export.
filename (str, optional) – name of the file (without format extension), by default None, meaning the the original name of the eeout file will be used.
format (str, optional) – export format, by default ‘vtu’ which is only one that is currently supported.
- Raises:
ValueError – if the output folder does not exists.