# Examples from pyvista.Grid.to_hexahedra
# =======================================

# Convert a 3D `ImageData` to hexahedra.
import pyvista as pv
image = pv.ImageData(dimensions=(2, 2, 2))
hexes = image.to_hexahedra()
hexes.distinct_cell_types == {pv.CellType.HEXAHEDRON}

# ----------------------------------------------------------------------
# Generated by sphinx-examples-as-code https://github.com/pyvista/sphinx-examples-as-code
