gruvoc.meshbfile: Tools for reading INRIA meshb files¶
One key functionality of this module is to determine the file type of
.meshb files or determine that they are not recognizable files of
that format.
- class cape.gruvoc.meshbfile.MESHBFileType(version, byteorder)¶
Bases:
tuple- byteorder¶
Alias for field number 1
- version¶
Alias for field number 0
- cape.gruvoc.meshbfile.MESHB_MODE_CHECKERS = {'b4': <function check_meshb_b>, 'b8': <function check_meshb_b>, 'lb4': <function check_meshb_lb>, 'lb8': <function check_meshb_lb>, 'lr4': <function check_meshb_lr>, 'lr8': <function check_meshb_lr>, 'r4': <function check_meshb_r>, 'r8': <function check_meshb_r>}¶
Dictionary of mode checkers
- cape.gruvoc.meshbfile.check_meshb_ascii(fp)¶
- cape.gruvoc.meshbfile.check_meshb_b(fp)¶
- cape.gruvoc.meshbfile.check_meshb_lb(fp)¶
- cape.gruvoc.meshbfile.check_meshb_lr(fp)¶
- cape.gruvoc.meshbfile.check_meshb_r(fp)¶
- cape.gruvoc.meshbfile.get_meshb_mode(fname_or_fp: IOBase | str, fmt: str | None = None) MESHBFileType | None¶
Identify meshb file format if possible
- Call:
>>> mode = get_ugrid_mode(fname_or_fp, fmt=None)
- Inputs:
- Outputs:
- mode:
None|MESHBFileType File type, big|little endian, stream|fortran, etc.
- mode:
- cape.gruvoc.meshbfile.get_meshb_mode_fname(fname: str, fmt: str | None = None) MESHBFileType¶
- cape.gruvoc.meshbfile.read_meshb(mesh: UmeshBase, fname_or_fp: str | IOBase, fmt: str | None = None)¶
Read data to a mesh object from
.meshbfile