Metrics

Extract Quantitative Information

This submodule contains functions for determining key metrics about an image. Typically these are applied to an image after applying a filter, but a few functions can be applied directly to the binary image.

metrics.chord_counts(im)

Finds the length of each chord in the supplied image and returns a list of their individual sizes

metrics.chord_length_distribution(im[, …])

Determines the distribution of chord lengths in an image containing chords.

metrics.geometrical_tortuosity(im[, axis])

Calculate geometrical tortuosity across an image

metrics.lineal_path_distribution(im[, bins, …])

Determines the probability that a point lies within a certain distance of the opposite phase along a specified direction

metrics.mesh_surface_area([mesh, verts, faces])

Calculates the surface area of a meshed region

metrics.phase_fraction(im[, normed])

Calculates the number (or fraction) of each phase in an image

metrics.pore_size_distribution(im[, bins, …])

Calculate a pore-size distribution based on the image produced by the porosimetry or local_thickness functions.

metrics.porosity(im)

Calculates the porosity of an image assuming 1’s are void space and 0’s are solid phase.

metrics.porosity_profile(im[, axis])

Returns a porosity profile along the specified axis

metrics.prop_to_image(regionprops, shape, prop)

Creates an image with each region colored according the specified prop, as obtained by regionprops_3d.

metrics.props_to_DataFrame(regionprops)

Returns a Pandas DataFrame containing all the scalar metrics for each region, such as volume, sphericity, and so on, calculated by regionprops_3D.

metrics.radial_density_distribution(dt[, …])

Computes radial density function by analyzing the histogram of voxel values in the distance transform.

metrics.region_interface_areas(regions, areas)

Calculates the interfacial area between all pairs of adjecent regions

metrics.region_surface_areas(regions[, …])

Extracts the surface area of each region in a labeled image.

metrics.regionprops_3D(im)

Calculates various metrics for each labeled region in a 3D image.

metrics.representative_elementary_volume(im)

Calculates the porosity of the image as a function subdomain size.

metrics.two_point_correlation_fft(im)

Calculates the two-point correlation function using fourier transforms.