lazyslide.cv.ProbabilityMap#
- class ProbabilityMap(probability_map, prob_map=None, class_names=None)#
Bases:
Mask- to_polygons(threshold=0.5, min_area=0, min_hole_area=0, detect_holes=True, ignore_index=0)#
Convert the probability map to polygons.
- Parameters:
- thresholdfloat
Threshold to convert the probability map to term:binary mask.
- min_areafloat
Minimum area of detected regions to be included in the polygon`.
- min_hole_areafloat
Minimum area of detected holes to be included in the polygon`.
- detect_holesbool
Whether to detect holes in regions.
- ignore_indexint or Sequence[int] or None
Indexes to ignore.
- Returns:
- gpd.GeoDataFrame
GeoDataFrame containing polygons and their probabilities.