iaa_od.models.k_alpha_unit

Classes

KAlphaUnit(*, id, img_filename[, annotations])

Data class representing a "unit" for Krippendorff's Alpha analysis.

class iaa_od.models.k_alpha_unit.KAlphaUnit(*, id, img_filename, annotations=<factory>)[source]

Bases: object

Data class representing a “unit” for Krippendorff’s Alpha analysis. The definition of unit comes from Krippendorff’s 2011 paper “Computing Krippendorff’s Alpha-Reliability”.

id

Unique identifier for the unit.

Type:

int

img_filename

Filename of the image associated with the unit.

Type:

str

annotations

List of annotations linked to this unit.

Type:

list[Annotation]

annotations: list[AnnotationProtocol]
property average_area: float

Compute the average area of the bounding boxes in the annotations for this unit.

Returns:

The average area of the bounding boxes, or 0 if there are no annotations.

Return type:

float

id: int
img_filename: str