PANDORE Version 6 |
GREYC-IMAGE |
passessdetectionaccuracy
Assesses region detection accuracy of a segmentation result by comparison with a reference segmentation.
Synopsis
passessdetectionaccuracy matching_algorithm_id matching_threshold [segmentation_result_in|-] [reference_segmentation_in|-] [col_out|-]
Description
The operator passessdetectionaccuracy calculates 2 errors to assess
region detection accuracy of a segmentation result by comparison with
a reference segmentation.
The two errors are:
- Recall error accounts for proportion of false negative regions.
- Precision error accounts for proportion of false positive regions.
Error values are between 0..1, where 0 means no error and 1
the worst result.
A recall error of x means that x * 100
percent of the ground truth regions are not detected in the segmentation result.
A precision error of x means that x * 100 percent of the segments do not
detect any region.
The result is stored in the output collection col_out
which contains the two error values.
Discrepancy measures are computed using a matching graph between segments in the segmentation
result and regions in the reference segmentation.
Two types of graph matching algorithm can used depending on the parameter matching_algorithm_id:
the first one allows for over and under-segmentation, and the second
one is restricted to unique region-segment matching.
In this graph, a segment S detects a region R
if the overlapping area | R * S | is such that:
| R * S | | R * S |
--------- >= matching_threshold and --------- >= matching_threshold
| R | | S |
Parameters
- matching_algorithm_id: the index of the matching algorithm to be used:
- 0: for 1-n and n-1 matching.
A segment in the segmentation result can merge several regions in the reference segmentation (under-segmentation), and
a region in the reference segmentation can be split into several segments in the segmentation result (over-segmentation).
However, a segment or a region cannot be both part of over-segmentation and under-segmentation.
- 1: for 1-1 matching. A segment can only detect one region at the most, and a region can only be
detected by one segment at the most.
- matching_threshold: minimum proportion of overlapping area between a region and a segment to accept a detection.
The value is in the interval [0,1] where value x corresponds to a minimum
of (x*100)% overlapping.
Inputs
- segmentation_result_in : a region map with segmentation result.
- reference_segmentation_in : a region map with reference segmentation.
Outputs
- col_out: a collection with the 2 error values.
Result
Returns SUCCESS or FAILURE.
Examples
Assesses detection accuracy of the segmentation result stored in 'tangram.pan' considering a minimum overlapping area of 50%:
passessdetectionaccuracy 0 0.5 resultimages/algo001/tangram.pan groundtruths/expert001/tangram.pan errors.pan
pvisu errors.pan
See also
Evaluation,
passessfragmentationconsistency,
passessboundaryprecision,
passessshapefidelity,
passesstopologypreservation,
passesssegmentationalgorithm,
pranksegmentationalgorithms,
pranksegmentationalgorithmsfromfolders
Prototype C++
Errc PAssessDetectionAccuracy( const Reg2d &segmentation_result_in, const Reg2d &reference_segmentation_in, Collection &cold,
const int matching_algorithm_id, const float matching_threshold );
Author: Régis Clouard