ogstools.mesh.file_io module#
- ogstools.mesh.file_io.read(filename)[source]#
Read a single mesh from a filepath.
- Return type:
UnstructuredGrid
- ogstools.mesh.file_io.save(filename, mesh, **kwargs)[source]#
Save mesh to file.
Supported are all file formats pyvista supports. In case you want to save as a vtu-file and the given mesh is not a pv.UnstructuredGrid it is cast to one prior to saving.
- Parameters:
filename (Path | str) – Filename to save the mesh to
mesh (DataSet) – pyvista mesh