skimage 0.17.2

NotesParametersReturns
adapted_rand_error(image_true=None, image_test=None, *, table=None, ignore_labels=(0,))

Notes

Pixels with label 0 in the true segmentation are ignored in the score.

Parameters

image_true : ndarray of int

Ground-truth label image, same shape as im_test.

image_test : ndarray of int

Test image.

table : scipy.sparse array in crs format, optional

A contingency table built with skimage.evaluate.contingency_table. If None, it will be computed on the fly.

ignore_labels : sequence of int, optional

Labels to ignore. Any part of the true image labeled with any of these values will not be counted in the score.

Returns

are : float

The adapted Rand error; equal to $1 - \frac{2pr}{p + r}$ , where p and r are the precision and recall described below.

prec : float

The adapted Rand precision: this is the number of pairs of pixels that have the same label in the test label image and in the true image, divided by the number in the test image.

rec : float

The adapted Rand recall: this is the number of pairs of pixels that have the same label in the test label image and in the true image, divided by the number in the true image.

Compute Adapted Rand error as defined by the SNEMI3D contest.

Examples

See :

Local connectivity graph

Hover to see nodes names; edges to Self not shown, Caped at 50 nodes.

Using a canvas is more power efficient and can get hundred of nodes ; but does not allow hyperlinks; , arrows or text (beyond on hover)

SVG is more flexible but power hungry; and does not scale well to 50 + nodes.

All aboves nodes referred to, (or are referred from) current nodes; Edges from Self to other have been omitted (or all nodes would be connected to the central node "self" which is not useful). Nodes are colored by the library they belong to, and scaled with the number of references pointing them


File: /skimage/metrics/_adapted_rand_error.py#7
type: <class 'function'>
Commit: