JATICDetectionAugmentationWithMetric
- class nrtk.interop.maite.interop.object_detection.augmentation.JATICDetectionAugmentationWithMetric(augmentations: Sequence[Augmentation] | None, metric: ImageMetric, augment_id: str)
Implementation of JATIC augmentation wrapper for NRTK’s Image metrics.
Implementation of JATIC augmentation for NRTK metrics operating on a MAITE-protocol compliant object detection dataset.
Parameters
- augmentationsSequence[Augmentation] | None
Optional task-specific sequence of JATIC augmentations to be applied on a given batch.
- metricImageMetric
Image metric to be applied for a given image.
- metadata: AugmentationMetadata
Metadata for this augmentation.
Methods
Checks if the necessary dependency (MAITE) is available.
- __call__(batch: tuple[Sequence[_SupportsArray[dtype[Any]] | _NestedSequence[_SupportsArray[dtype[Any]]] | bool | int | float | complex | str | bytes | _NestedSequence[bool | int | float | complex | str | bytes]], Sequence[ObjectDetectionTarget], Sequence[DatumMetadata]]) tuple[Sequence[_SupportsArray[dtype[Any]] | _NestedSequence[_SupportsArray[dtype[Any]]] | bool | int | float | complex | str | bytes | _NestedSequence[bool | int | float | complex | str | bytes]], Sequence[ObjectDetectionTarget], Sequence[NRTKDatumMetadata]]
Compute a specified image metric on the given batch.
- __init__(augmentations: Sequence[Augmentation] | None, metric: ImageMetric, augment_id: str) None
Initialize augmentation with metric wrapper.
- __subclasshook__()
Abstract classes can override this to customize issubclass().
This is invoked early on by abc.ABCMeta.__subclasscheck__(). It should return True, False or NotImplemented. If it returns NotImplemented, the normal algorithm is used. Otherwise, it overrides the normal algorithm (and the outcome is cached).
- classmethod is_usable() bool
Checks if the necessary dependency (MAITE) is available.
- Returns:
bool: True MAITE is available; False otherwise.