satn_to_panels(satn, im, bins=None, axis=0, slice=None, **kwargs)[source]#

Produces a set of images with each panel containing one saturation

  • satn (ndarray) – An image with each voxel indicating the global saturation at which it was invaded. 0 indicates solid and -1 indicates uninvaded.

  • im (ndarray) – A boolean image with True values indicating the void voxels and False for solid.

  • bins (int) – Indicates for which saturations images should be made. If an int then a list of equally space values between 0 and 1 is generated. If None (default) than all saturation values in the image are used.

  • axis (int, optional) – If the image is 3D, a 2D image is extracted at the specified slice taken along this axis. If the image is 2D this is ignored.

  • slice (int, optional) – If the image is 3D, a 2D image is extracted from this slice along the given axis. If None, then a slice at the mid-point of the axis is returned. If 2D this is ignored.

  • **kwargs (various) – Additional keyword arguments are sent to the imshow function, such as interpolation.


fig, ax – The same things as returned by plt.subplots

Return type:

Matplotlib figure and axis objects


Click here to view online example.