JSON File Structure

Each JSON file contains array of per-frame annotation data:

  • The first element in the array (“zero frame”) contains general metadata, while the rest of the elements contain data for frames 1...N (where N is the last frame).

  • The length of the root array is therefore N+1 elements.

Example:

[
{Zero frame object},
{Object for frame 1},
{Object for frame 2},
...
{Object for the last frame}
]

Zero frame object format

Field name
Type
Description

version

string (“1.4”)

The version of the output format

file

string (e.g: “/video/072.mp4”)

Annotated video file name with relative path to its location at the time of annotation

frame_skip

Integer

In case frames were skipped, indicates

skipping step

original_frame

Integer

First frame index. In case that target movie was divided to parts, the number of the second part will be the last frame+1

part

Integer

Part Index, in case that target movie was divided into multiple parts. Starting from part 1.

attributes

Map <attrID, value>

Non-interpolated file attribute values

objects

List <ObjectPropertiesFrame()>

Ids and properties of all the annotated objects

in the video

Object Properties on frame 0

Field name
Type
Description

nm

string (examples: “0.1”,

“0.2”)

Unique object identifier

shape

string

One of the object shapes:

bBox poly multiline skeleton

bitmap

type

string

Object type id

parent

string

Identifier of the parent object (only present if

nested)

attributes

Map<attrId, value>

Non-interpolated object attribute values

Frame object format

Field name
Type
Description

attributes

Map <attrID, value>

Interpolated file attribute values on this frame

objects

List <ObjectPropertiesFrame()>

array of objects appearing on this frame

Object Properties

Field name
Type
Description

nm

string

Id of the object (string) Constructed by 2 or 3 numbers divided by “.”

x1

number

Left edge coordinate in pixel of the containing BB of

the object shape

y1

number

Top edge coordinate in pixels of the containing BB of

the object shape

x2

number

Right edge coordinate in pixels of the containing BB of

the object shape

y2

number

Bottom edge coordinate in pixels of the containing BB

of the object shape

path

• List <List<[x: float, y: float]>>

**For polygon and multiline in legacy export version)

• List <Point>

Shape outline path

Bitmaps may have holes and disjoint areas, and therefore bitmap outline is a bit more complicated: it consists of several closed path sections, and points are included in the bitmap according to the “even-odd” rule (This rule determines the "insideness" of a point on the canvas by drawing a ray from that point to infinity in any direction and counting the number of path segments from the given shape that the ray crosses. If this number is odd, the point is inside; if even, the point is outside).

**Note that in bitmap paths, points are not objects but arrays containing x coordinate as a 1st element and y coordinate as a 2nd element.

*** Bound box shape objects will have their vertexes in the following order (upper left, upper right, bottom right , bottom left)

If legacy export option is selected for polygon or multiline :

Objects with polygon and multiline shapes will have a single path represented by a collection of {x, y} points.

skeleton

Map <skeletonBoneId,

Point>

Map of skeleton points

attributes

Map <attrID, value>

Interpolated object attribute values on this frame

key

Boolean

true if this is a key instance of object shape

false if this

is interpolated instance of object shape

attr_key

Boolean

true if at least one object attribute has a key value on

this frame

Point

Field name
Type
Description

x

Float

point x coordinate

y

Float

point y coordinate

Last updated