romtools.vector_space.utils.outputter#

Functions

exodus_ouput(output_filename, mesh_filename, ...)

Save vector space information to an Exodus file.

hdf5_output(output_filename, vector_space)

Save vector space information to an HDF5 file.

npz_output(output_filename, vector_space[, ...])

Save vector space information to a compressed or uncompressed NumPy .npz file.

romtools.vector_space.utils.outputter.exodus_ouput(output_filename, mesh_filename, vector_space, var_names=None)[source]#

Save vector space information to an Exodus file.

Parameters:
  • output_filename (str) – The name of the output Exodus file.

  • mesh_filename (str) – The name of the mesh file.

  • vector_space (VectorSpace) – The vector space containing shift and basis information.

  • var_names (list, optional) – A list of variable names (default is None).

Return type:

None

Example

exodus_output(“vector_space.e”, “mesh.exo”, my_vector_space, var_names=[“var1”, “var2”])

romtools.vector_space.utils.outputter.hdf5_output(output_filename, vector_space)[source]#

Save vector space information to an HDF5 file.

Parameters:
  • output_filename (str) – The name of the output HDF5 file.

  • vector_space (VectorSpace) – The vector space containing shift and basis information.

Return type:

None

Example

hdf5_output(“vector_space.h5”, my_vector_space)

romtools.vector_space.utils.outputter.npz_output(output_filename, vector_space, compress=True)[source]#

Save vector space information to a compressed or uncompressed NumPy .npz file.

Parameters:
  • filename (str) – The name of the output file.

  • vector_space (VectorSpace) – The vector space containing shift and basis information.

  • compress (bool, optional) – Whether to compress the output file (default is True).

  • output_filename (str)

Return type:

None

Example

npz_output(“vector_space.npz”, my_vector_space)