pysdic.PointCloud.quick_visualize#
- PointCloud.quick_visualize(*, warp_by=None, color=None, size=None, opacity=None, mask=None, property=None, property_axis=None, property_clim=None, property_cmap=None, property_below_color=None, property_above_color=None, title=None, show_bar=True, show_bounds=True, show_points_index=False, index_font_size=10, screenshot=None)[source]#
Visualize the point cloud with PyVista (only for \(E \leq 3\)).
Only the finite points are displayed.
See also
pysdic.Plotter3Dfor more control over the visualization.
- Parameters:
warp_by (Optional[Union[str, ArrayLike]], optional) – The property used to warp the points: the name of a property of the point cloud, or an array of shape \((N_p,)\) or \((N_p, A)\).
color (Union[str, Tuple[Real, Real, Real]], optional) – The color of the points: a color name (e.g.
"red"), an RGB tuple or a hex string. Ignored ifpropertyis given.size (Real, optional) – The size of the points (positive). PyVista default:
5.0.opacity (Real, optional) – The opacity of the points, between
0.0(transparent) and1.0(opaque). PyVista default:1.0.mask (Optional[ArrayLike], optional) – A boolean array of shape \((N_p,)\), True for the points to display. By default, all the finite points are displayed.
property (Union[str, ArrayLike], optional) – The property used to color the points: the name of a property of the point cloud, or an array of shape \((N_p,)\) or \((N_p, A)\).
property_axis (Optional[Integral], optional) – The component used to color the points when the property has \(A > 1\) components. By default, the norm of the property vector is used.
property_clim (Optional[Tuple[Real, Real]], optional) – The color limits (min, max). By default, they are set automatically.
property_cmap (Union[str,
matplotlib.colors.Colormap], optional) – The colormap (name or object). Matplotlib default:"viridis".property_below_color (Union[str, Tuple[Real, Real, Real]], optional) – The color of the values below
property_clim. By default, the first color of the colormap.property_above_color (Union[str, Tuple[Real, Real, Real]], optional) – The color of the values above
property_clim. By default, the last color of the colormap.title (Optional[str], optional) – The title of the window.
show_bar (bool, optional (default:
True)) – Whether to show the color bar whenpropertyis given.show_bounds (bool, optional (default:
True)) – Whether to show the axes bounds.show_points_index (bool, optional (default:
False)) – Whether to write the index of each displayed point next to it.index_font_size (Real, optional (default:
10)) – The font size of the indices, in pixels of the screen (constant when zooming).screenshot (Optional[str], optional) – The path of a screenshot to save. By default, no screenshot is saved.
- Return type:
None
Examples
1import numpy 2from pysdic import PointCloud 3 4point_cloud = PointCloud(numpy.random.rand(100, 3)) 5point_cloud.quick_visualize(color='red', size=10) 6point_cloud.quick_visualize(show_points_index=True) # Numbering of the points