Modules.UncertaintyLobes package
Submodules
Modules.UncertaintyLobes.uncertainty_lobes module
- Modules.UncertaintyLobes.uncertainty_lobes.uncertainty_lobes(positions, ensemble_vectors, percentil1, percentil2=None, scale=0.2, ax=None, show_median=True)[source]
Draws uncertainty lobe glyphs for the given positions and ensemble vectors. This implemantation is inspired by M. Jarema, I. Demir, J. Kehrer and R. Westermann, “Comparative visual analysis of vector field ensembles,” 2015 IEEE Conference on Visual Analytics Science and Technology (VAST), Chicago, IL, USA, 2015, pp. 81-88, doi: 10.1109/VAST.2015.7347634. This implementation uses vector depth and doesn’t fit ensemble to a Gaussian Mixture Model as in the original paper. In addition, this implementation doesn’t perform clustering of the vectors, instead it draws lobes for all vectors at each position.
Parameters:
- positionsnumpy.ndarray
Array of shape (n, 2) representing the positions of the lobe glyphs.
- ensemble_vectorsnumpy.ndarray
Array of shape (n, m, 2) representing the ensemble vectors for each position.
- percentil1float
The first percentile for depth filtering.
- percentil2float, optional
The second percentile for depth filtering. If None, only one lobe is drawn.
- scalefloat
The scale factor for the glyphs.
- axmatplotlib axis
The axis to draw on. If None, a new figure and axis will be created.
Returns:
- axmatplotlib axis
The axis with the drawn lobe glyphs.
Modules.UncertaintyLobes.uncertainty_lobes_stats module
Modules.UncertaintyLobes.uncertainty_lobes_vis module
- Modules.UncertaintyLobes.uncertainty_lobes_vis.matplotlib_uncertainty_lobes_vis(ax, centers, theta1, theta2, mid_angle, r1, r2, r_arrow, show_median)[source]
Draws multiple wedges with arrows. Parameters: ———– centers : numpy.ndarray
Array of shape (n, 2) representing the center positions of the wedges.
- theta1numpy.ndarray
Array of shape (n, 2), each row [theta1_start, theta1_end] for the first wedge.
- theta2numpy.ndarray
Array of shape (n, 2), each row [theta2_start, theta2_end] for the second wedge (arrowhead).
- mid_angleiterable
Iterable of length n, mid angle for arrow direction.
- r1float or iterable
Radius for the first wedge.
- r2float or iterable of length n
Radius for the second wedge.
- r_arrowfloat or iterable of length n
Length of the arrow.
- show_medianbool
Whether to show the median arrow.
Module contents
UncertaintyLobes Module This module provides functionality for visualizing uncertainty lobes in 2D and 3D datasets. It includes methods for calculating statistical measures of uncertainty and rendering the lobes using matplotlib and pyvista.