OpenMode

class OpenMode[source]

Bases: enum.Enum

Defines the mode of using the Project and Dataset.

Attributes

READ

int: READ open mode.

CREATE

int: CREATE open mode.

CREATE = 2

int: CREATE open mode. Creates a leaf directory and empty meta.json file. Generates error if project directory already exists and is not empty.

READ = 1

int: READ open mode. Loads project from given project directory. Checks that item and annotation directories exist and dataset is not empty. Consistency checks. Checks that every image has an annotation and the correspondence is one to one.