generated from stac-extensions/template
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathschema.json
219 lines (219 loc) · 6.25 KB
/
schema.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
{
"$schema": "http://json-schema.org/draft-07/schema#",
"$id": "https://stac-extensions.github.io/sentinel-2/v1.0.0/schema.json",
"title": "Sentinel-2 Extension",
"description": "STAC Sentinel-2 Extension for STAC Items and STAC Collection Summaries.",
"type": "object",
"required": ["stac_extensions"],
"properties": {
"stac_extensions": {
"type": "array",
"contains": {
"const": "https://stac-extensions.github.io/sentinel-2/v1.0.0/schema.json"
}
}
},
"oneOf": [
{
"$comment": "This is the schema for STAC Items.",
"type": "object",
"required": ["type", "properties"],
"properties": {
"type": {
"const": "Feature"
},
"properties": {
"allOf": [
{
"$ref": "#/definitions/require_any"
},
{
"$ref": "#/definitions/fields"
}
]
}
}
},
{
"$comment": "This is the schema for STAC Collections, or more specifically only Collection Summaries in this case. By default, only checks the existence of the properties, but not the schema of the summaries.",
"type": "object",
"required": ["type", "summaries"],
"properties": {
"type": {
"const": "Collection"
},
"summaries": {
"$ref": "#/definitions/require_any"
}
}
}
],
"definitions": {
"require_any": {
"$comment": "Please list all fields here so that we can force the existence of one of them in other parts of the schemas.",
"anyOf": [
{ "required": ["s2:tile_id"] },
{ "required": ["s2:datatake_id"] },
{ "required": ["s2:product_uri"] },
{ "required": ["s2:datastrip_id"] },
{ "required": ["s2:datatake_type"] },
{ "required": ["s2:reflectance_conversion_factor"] }
]
},
"fields": {
"type": "object",
"properties": {
"s2:tile_id": {
"title": "Tile Identifier",
"type": "string"
},
"s2:granule_id": {
"title": "Granule Identifier",
"type": "string",
"deprecated": true
},
"s2:datatake_id": {
"title": "Datatake Identifier",
"type": "string"
},
"s2:product_uri": {
"title": "Product URI",
"type": "string"
},
"s2:datastrip_id": {
"title": "Datastrip Identifier",
"type": "string"
},
"s2:product_type": {
"title": "Product Type",
"type": "string",
"deprecated": true
},
"s2:datatake_type": {
"title": "Datatake Type",
"type": "string"
},
"s2:generation_time": {
"title": "Generation Time",
"type": "string",
"format": "date-time",
"deprecated": true
},
"s2:processing_baseline": {
"title": "Processing Baseline",
"type": "string",
"pattern": "^\\d\\d\\.\\d\\d$",
"deprecated": true
},
"s2:water_percentage": {
"title": "Water Percentage",
"type": "number",
"minimum": 0,
"maximum": 100
},
"s2:mean_solar_zenith": {
"title": "Mean Solar Zenith",
"type": "number",
"minimum": 0,
"maximum": 180,
"deprecated": true
},
"s2:mean_solar_azimuth": {
"title": "Mean Solar Azimuth",
"type": "number",
"minimum": 0,
"maximum": 180,
"deprecated": true
},
"s2:snow_ice_percentage": {
"title": "Snow and Ice Percentage",
"type": "number",
"minimum": 0,
"maximum": 100
},
"s2:vegetation_percentage": {
"title": "Vegetation Percentage",
"type": "number",
"minimum": 0,
"maximum": 100
},
"s2:thin_cirrus_percentage": {
"title": "Thin Cirrus Percentage",
"type": "number",
"minimum": 0,
"maximum": 100
},
"s2:cloud_shadow_percentage": {
"title": "Cloud Shadow Percentage",
"type": "number",
"minimum": 0,
"maximum": 100
},
"s2:nodata_pixel_percentage": {
"title": "No Data Pixel Percentage",
"type": "number",
"minimum": 0,
"maximum": 100
},
"s2:unclassified_percentage": {
"title": "Unclassified Percentage",
"type": "number",
"minimum": 0,
"maximum": 100
},
"s2:dark_features_percentage": {
"title": "Dark Features Percentage",
"type": "number",
"minimum": 0,
"maximum": 100
},
"s2:not_vegetated_percentage": {
"title": "Not Vegetated Percentage",
"type": "number",
"minimum": 0,
"maximum": 100
},
"s2:degraded_msi_data_percentage": {
"title": "Degraded MSI Data Percentage",
"type": "number",
"minimum": 0,
"maximum": 100
},
"s2:high_proba_clouds_percentage": {
"title": "High Probability Clouds Percentage",
"type": "number",
"minimum": 0,
"maximum": 100
},
"s2:medium_proba_clouds_percentage": {
"title": "Medium Probability Clouds Percentage",
"type": "number",
"minimum": 0,
"maximum": 100
},
"s2:saturated_defective_pixel_percentage": {
"title": "Saturated Defective Pixel Percentage",
"type": "number",
"minimum": 0,
"maximum": 100
},
"s2:reflectance_conversion_factor": {
"title": "Reflectance Conversion Factor",
"type": "number"
},
"s2:mgrs_tile": {
"title": "Sentinel-2 MGRS Tile Identifier",
"type": "string",
"pattern": "^\\d\\d?[CDEFGHJKLMNPQRSTUVWX][ABCDEFGHJKLMNPQRSTUVWXYZ][ABCDEFGHJKLMNPQRSTUV]$",
"deprecated": true
}
},
"patternProperties": {
"^(?!s2:)": {
"$comment": "Do not allow other fields with this prefix"
}
},
"additionalProperties": false
}
}
}