porespy.metrics.find_porosity_threshold#
- porespy.metrics.find_porosity_threshold(im, axis=0, dt=None, conn='min')#
Finds the porosity of the image at the percolation threshold
This function progressively dilates the solid and reports the porosity at the step just before there are no percolating paths (in the specified direction)
- Parameters:
im (ndarray) – Image of the void space with True indicating void space
axis (int) – The axis along which percolation is checked
dt (ndarray) – The distance transform of the void space. If not provide it will be computed so providing one can save time if it is available.
conn (str) – Can be either ‘min’ or ‘max’ and controls the shape of the structuring element used to determine voxel connectivity. The default if ‘min’ which imposes the strictest criteria, so that voxels must share a face to be considered connected.
- Returns:
A Results object with the following attributes:
Attribute
Description
eps_orig
The total porosity of the original image, including closed and surface pores
eps_orig_perc
The percolating porosity of the original image (i.e. with closed and surface pores filled)
eps_thresh
The total porosity of the image just before the percolation threshold was reached (i.e at the point where one additional dilation would result in no connected void space.)
eps_thresh_perc
The percolating porosity (with closed and surface pores filled) just before the percolation threshold was reached (i.e at the point where one additional dilation would result in no connected void space.)
eps_thresh_post
The total porosity after the percolation threshold was reached (i.e. one step after the dilation which resulted in no connected pore space)
R
The threshold to apply to the distance transform to obtain the percolating image (i.e. im = dt >= R)
- Return type:
results
Examples
Click here to view online example.