Package ai.djl.basicdataset.cv
Class CocoMetadata.Annotation
- java.lang.Object
-
- ai.djl.basicdataset.cv.CocoMetadata.Annotation
-
- Enclosing class:
- CocoMetadata
public static final class CocoMetadata.Annotation extends java.lang.ObjectAn annotation applied to an image in the coco dataset.
-
-
Constructor Summary
Constructors Constructor Description Annotation()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description doublegetArea()Returns the area of this annotation.double[]getBoundingBox()Returns the bounding box of this annotation.longgetCategoryId()Returns the category id of this annotation.longgetId()Returns the id of this annotation.longgetImageId()Returns the id of the image this annotation applies to.
-
-
-
Method Detail
-
getImageId
public long getImageId()
Returns the id of the image this annotation applies to.- Returns:
- the id of the image this annotation applies to
-
getId
public long getId()
Returns the id of this annotation.- Returns:
- the id of this annotation
-
getBoundingBox
public double[] getBoundingBox()
Returns the bounding box of this annotation.- Returns:
- the bounding box of this annotation
-
getCategoryId
public long getCategoryId()
Returns the category id of this annotation.- Returns:
- the category id of this annotation
-
getArea
public double getArea()
Returns the area of this annotation.- Returns:
- the area of this annotation
-
-