Metadata Format
You may specify additional metadata for a dataset by including a metadata.json
or metadata.jsonl
file in the root of your archive. A metadata.json
file contains an array of metadata JSON objects whereas a metadata.jsonl
file should contain a metadata JSON object on each line. A metadata JSON object has the following fields:
-
path:
Absolute path to the image or text file within the compressed file structure; see the example below. -
metadata:
An object containing key/value pairs, one for each metadata field/value for the image or text files.- Metadata keys must be strings
- Metadata values may be strings, numbers, or boolean
Some EXIF-specific keys included in the additional metadata file will override the corresponding original values extracted from the datum during upload. These values are GPSDateTime
, GPSLatitude
, and GPSLongitude
. Additional information on image preparation regarding EXIF fields can be found here. Specific field formats
and purposes are detailed below.
EXIF Override Fields
The following metadata fields can be provided in your additional metadata file to override EXIF data extracted from the image:
GPSLatitude
and GPSLongitude
These fields accept the following formats:
Type | Example | Notes |
---|---|---|
float | 45.123456 | Preferred format |
string | "45.123456" | Must be parsable as a float |
If the value is an empty string or cannot be parsed into a float, it will be ignored. All coordinates are expected to be in decimal degrees (not degrees/minutes/seconds format).
GPSDateTime
This field must be a string in one of the following timestamp formats:
Format | Example | Notes |
---|---|---|
ISO 8601 with offset | 2023-12-01T14:30:00-0500 | Local time and UTC offset |
RFC 3339 | 2023-12-01T14:30:00-05:00 | Local time and UTC offset |
Go time.DateTime | 2023-12-01 14:30:00 | No time zone info, assumed UTC |
If the value is empty or in an unrecognized format, it will be ignored.
Example Metadata File
{
"metadata": [
{
"path": "data_folder/a.jpg",
"metadata": {
"Species": "canine",
"Color": "brown/white"
}
},
{
"path": "data_folder/b.jpg",
"metadata": {
"Species": "feline",
"Color": "orange tabby"
}
}
]
}