pyvista.examples.downloads.download_particles

pyvista.examples.downloads.download_particles#

download_particles(load=True)[source]#

Download a particle dataset.

Added in version 0.44.0.

Parameters:
loadbool, default: True

Load the dataset after downloading it when True. Set this to False and only the filename will be returned.

Returns:
pyvista.PolyData | str

DataSet or filename depending on load.

Examples

>>> import pyvista as pv
>>> from pyvista import examples
>>> filename = examples.download_particles(load=False)
>>> reader = pv.get_reader(filename)
>>> reader.reader.SetDataByteOrderToBigEndian()
>>> reader.reader.Update()
>>> mesh = reader.read()
>>> mesh.plot()
../../../_images/pyvista-examples-downloads-download_particles-1_00_00.png

See also

Particles Dataset

See this dataset in the Dataset Gallery for more info.