pyvista.XMLRectilinearGridReader

class XMLRectilinearGridReader(filename)

XML RectilinearGrid Reader for .vtr files.

Examples

>>> import pyvista
>>> from pyvista import examples
>>> filename = examples.download_rectilinear_grid(load=False)
>>> filename.split("/")[-1]  # omit the path
'RectilinearGrid.vtr'
>>> reader = pyvista.get_reader(filename)
>>> mesh = reader.read()
>>> sliced_mesh = mesh.slice('y')
>>> sliced_mesh.plot(scalars='Void Volume Fraction', cpos='xz',
...                  show_scalar_bar=False)
../../../_images/pyvista-XMLRectilinearGridReader-1_00_00.png

Methods

XMLRectilinearGridReader.cell_array_status(name)

Get status of cell array with name.

XMLRectilinearGridReader.disable_all_cell_arrays()

Disable all cell arrays.

XMLRectilinearGridReader.disable_all_point_arrays()

Disable all point arrays.

XMLRectilinearGridReader.disable_cell_array(name)

Disable cell array with name.

XMLRectilinearGridReader.disable_point_array(name)

Disable point array with name.

XMLRectilinearGridReader.enable_all_cell_arrays()

Enable all cell arrays.

XMLRectilinearGridReader.enable_all_point_arrays()

Enable all point arrays.

XMLRectilinearGridReader.enable_cell_array(name)

Enable cell array with name.

XMLRectilinearGridReader.enable_point_array(name)

Enable point array with name.

XMLRectilinearGridReader.point_array_status(name)

Get status of point array with name.

XMLRectilinearGridReader.read()

Read data in file.

Attributes

XMLRectilinearGridReader.all_cell_arrays_status

Return the status of all cell arrays.

XMLRectilinearGridReader.all_point_arrays_status

Return the status of all point arrays.

XMLRectilinearGridReader.cell_array_names

Return the list of all cell array names.

XMLRectilinearGridReader.number_cell_arrays

Return the number of cell arrays.

XMLRectilinearGridReader.number_point_arrays

Return the number of point arrays.

XMLRectilinearGridReader.point_array_names

Return the list of all point array names.

XMLRectilinearGridReader.reader

Return the vtk Reader object.