Polygon (v1)¶
Warning
This is not the latest version. The latest version is v5.
Previous Version: none (this is the oldest version)
Shortname:
PolygonInherits from: Region (v1)
Also Known As: This type is also accessible at the following legacy URLs for backward compatibility:
Description¶
A polygon in an image or video. This is a two-dimensional object so if this occurs in a video it will be anchored to a particular frame or time point in the video.
Properties¶
Synopsis¶
Properties marked with * are required.
Property |
Type |
Origin |
|---|---|---|
array of array |
native |
|
integer |
native |
|
string |
||
string |
||
id * |
string |
Native¶
coordinates¶
type: array of array
required: yes
The coordinates of the polygon, taking the top-left of the image as the origin (0,0). Unit used to measure the distance is the number of pixels.
timePoint¶
type: integer
required: no
If on a video stream, the TimePoint that the BoundingBox occurs in.
Inherited from Region (v1)¶
timeUnit¶
type: string
required: no
Specifies which unit of time the measurement is based. Can be seconds or milliseconds, or in case of annotations on a VideoDocument, frames.
Inherited from Annotation (v2)¶
document¶
type: string
required: no
The identifier of the document that the annotation is over.
Inherited from Thing (v1)¶
id¶
type: string
required: yes
A unique identifier for the annotation or document. Uniqueness is relative to the view the annotation is in or the list of documents at the top level of a MMIF file.
JSON Schema¶
{
"additionalProperties": true,
"properties": {
"id": {
"description": "A unique identifier for the annotation or document. Uniqueness is relative to the view the annotation is in or the list of documents at the top level of a MMIF file.",
"type": "string"
},
"document": {
"type": "string",
"description": "The identifier of the document that the annotation is over."
},
"timeUnit": {
"type": "string",
"description": "Specifies which unit of time the measurement is based. Can be *seconds* or *milliseconds*, or in case of annotations on a VideoDocument, *frames*."
},
"coordinates": {
"description": "The coordinates of the polygon, taking the top-left of the image as the origin (0,0). Unit used to measure the distance is the number of pixels.",
"items": {
"items": {
"type": "integer"
},
"type": "array"
},
"type": "array"
},
"timePoint": {
"type": "integer",
"description": "If on a video stream, the TimePoint that the BoundingBox occurs in."
}
},
"required": [
"coordinates",
"id"
],
"type": "object"
}