Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,10 @@ classifiers = [
dynamic = ["version"]
dependencies = [
"orjson",
"titiler.core>=1.1,<1.2",
"titiler.mosaic>=1.1,<1.2",
"titiler.extensions>=1.1,<1.2",
"titiler-core>=2.0.0a2,<2.1",
"titiler-mosaic>=2.0.0a2,<2.1",
"titiler-extensions>=2.0.0a2,<2.1",
"rio-tiler>=9.0.0a4,<10.0",
"pystac-client",
"pydantic>=2.4,<3.0",
"pydantic-settings~=2.0",
Expand Down
11 changes: 4 additions & 7 deletions tests/fixtures/catalog.json
Original file line number Diff line number Diff line change
Expand Up @@ -81,9 +81,8 @@
"visual": {
"title": "Visual Image",
"assets": [
"visual"
"visual|indexes=1,2,3"
],
"asset_bidx": "visual|1,2,3",
"minmax_zoom": [
8,
22
Expand All @@ -98,9 +97,8 @@
"color": {
"title": "Colored Image",
"assets": [
"visual"
"visual|indexes=1"
],
"asset_bidx": "visual|1",
"colormap": {
"1": [0, 0, 0, 255],
"1000": [255, 255, 255, 255]
Expand All @@ -109,14 +107,13 @@
"visualr": {
"title": "Rescaled Image",
"assets": [
"visual"
"visual|indexes=1"
],
"asset_bidx": "visual|1",
"rescale": [
[0, 100]
]
}
},
},
"description": "Maxar OpenData | Cyclone Mocha, a category five cyclone with 130 mph winds and torrential rain, hit parts of Myanmar and Bangladesh, forcing mass evacuations ahead of the storm. The cyclone, one of the most powerful to hit the region in the last decade, made landfall on Sunday, May 14, 2023, near Sittwe in Myanmar's Rakhine state. Rain and a storm surge caused widespread flooding in low-lying areas. The United National Office Coordination of Humanitarian Affairs stated that there had been extensive damage among already vulnerable communities and that communications with the affected areas have been difficult.",
"item_assets": {
"visual": {
Expand Down
343 changes: 343 additions & 0 deletions tests/fixtures/catalog_old_renders.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,343 @@
{
"collections": [
{
"id": "MAXAR_BayofBengal_Cyclone_Mocha_May_23",
"type": "Collection",
"links": [
{
"rel": "items",
"type": "application/geo+json",
"href": "https://stac.endpoint.io/collections/MAXAR_BayofBengal_Cyclone_Mocha_May_23/items"
},
{
"rel": "parent",
"type": "application/json",
"href": "https://stac.endpoint.io/"
},
{
"rel": "root",
"type": "application/json",
"href": "https://stac.endpoint.io/"
},
{
"rel": "self",
"type": "application/json",
"href": "https://stac.endpoint.io/collections/MAXAR_BayofBengal_Cyclone_Mocha_May_23"
}
],
"title": "Bay of Bengal Cyclone Mocha 2023",
"extent": {
"spatial": {
"bbox": [
[
91.831615,
19.982078842323997,
92.97426268500965,
21.666101
],
[
92.567815,
20.18811887678192,
92.74417544237298,
20.62968532404085
],
[
92.72278776887262,
20.104801,
92.893524,
20.630214
],
[
92.75855246040959,
19.982078842323997,
92.89682495377032,
20.514473160464657
],
[
92.84253515935835,
19.984656587012033,
92.97426268500965,
20.514418665444474
],
[
91.831615,
21.518411,
91.957078,
21.666101
]
]
},
"temporal": {
"interval": [
[
"2023-01-03T04:30:17Z",
"2023-05-22T04:35:25Z"
]
]
}
},
"license": "CC-BY-NC-4.0",
"renders": {
"visual": {
"title": "Visual Image",
"assets": [
"visual"
],
"asset_bidx": "visual|1,2,3",
"minmax_zoom": [
8,
22
],
"tilematrixsets": {
"WebMercatorQuad": [
8,
22
]
}
},
"color": {
"title": "Colored Image",
"assets": [
"visual"
],
"asset_bidx": "visual|1",
"colormap": {
"1": [0, 0, 0, 255],
"1000": [255, 255, 255, 255]
}
},
"visualr": {
"title": "Rescaled Image",
"assets": [
"visual"
],
"asset_bidx": "visual|1",
"rescale": [
[0, 100]
]
}
},
"description": "Maxar OpenData | Cyclone Mocha, a category five cyclone with 130 mph winds and torrential rain, hit parts of Myanmar and Bangladesh, forcing mass evacuations ahead of the storm. The cyclone, one of the most powerful to hit the region in the last decade, made landfall on Sunday, May 14, 2023, near Sittwe in Myanmar's Rakhine state. Rain and a storm surge caused widespread flooding in low-lying areas. The United National Office Coordination of Humanitarian Affairs stated that there had been extensive damage among already vulnerable communities and that communications with the affected areas have been difficult.",
"item_assets": {
"visual": {
"type": "image/tiff; application=geotiff; profile=cloud-optimized",
"roles": [
"visual"
],
"title": "Visual Image"
},
"data-mask": {
"type": "application/geopackage+sqlite3",
"roles": [
"data-mask"
],
"title": "Data Mask"
},
"ms_analytic": {
"type": "image/tiff; application=geotiff; profile=cloud-optimized",
"roles": [
"data"
],
"title": "Multispectral Image"
},
"pan_analytic": {
"type": "image/tiff; application=geotiff; profile=cloud-optimized",
"roles": [
"data"
],
"title": "Panchromatic Image"
}
},
"stac_version": "1.0.0",
"stac_extensions": [
"https://stac-extensions.github.io/item-assets/v1.0.0/schema.json",
"https://stac-extensions.github.io/render/v1.0.0/schema.json"
]
},
{
"id": "MAXAR_BayofBengal_Cyclone_Mocha_May_23_cube_dimensions",
"type": "Collection",
"links": [
{
"rel": "items",
"type": "application/geo+json",
"href": "https://stac.endpoint.io/collections/MAXAR_BayofBengal_Cyclone_Mocha_May_23/items"
},
{
"rel": "parent",
"type": "application/json",
"href": "https://stac.endpoint.io/"
},
{
"rel": "root",
"type": "application/json",
"href": "https://stac.endpoint.io/"
},
{
"rel": "self",
"type": "application/json",
"href": "https://stac.endpoint.io/collections/MAXAR_BayofBengal_Cyclone_Mocha_May_23"
}
],
"title": "Bay of Bengal Cyclone Mocha 2023",
"cube:dimensions": {
"time": {
"type": "temporal",
"extent": [
"2023-01-03T04:30:17Z",
"2023-05-22T04:35:25Z"
],
"values": [
"2023-01-03T04:30:17Z",
"2023-02-03T04:30:17Z",
"2023-03-03T04:30:17Z",
"2023-04-03T04:30:17Z",
"2023-05-03T04:30:17Z",
"2023-05-22T04:35:25Z"
]
}
},
"extent": {
"spatial": {
"bbox": [
[
91.831615,
19.982078842323997,
92.97426268500965,
21.666101
],
[
92.567815,
20.18811887678192,
92.74417544237298,
20.62968532404085
],
[
92.72278776887262,
20.104801,
92.893524,
20.630214
],
[
92.75855246040959,
19.982078842323997,
92.89682495377032,
20.514473160464657
],
[
92.84253515935835,
19.984656587012033,
92.97426268500965,
20.514418665444474
],
[
91.831615,
21.518411,
91.957078,
21.666101
]
]
},
"temporal": {
"interval": [
[
"2023-01-03T04:30:17Z",
"2023-05-22T04:35:25Z"
]
]
}
},
"license": "CC-BY-NC-4.0",
"renders": {
"visual": {
"title": "Visual Image",
"assets": [
"visual"
],
"asset_bidx": "visual|1,2,3",
"minmax_zoom": [
8,
22
],
"tilematrixsets": {
"WebMercatorQuad": [
8,
22
]
}
}
},
"description": "Maxar OpenData | Cyclone Mocha, a category five cyclone with 130 mph winds and torrential rain, hit parts of Myanmar and Bangladesh, forcing mass evacuations ahead of the storm. The cyclone, one of the most powerful to hit the region in the last decade, made landfall on Sunday, May 14, 2023, near Sittwe in Myanmar's Rakhine state. Rain and a storm surge caused widespread flooding in low-lying areas. The United National Office Coordination of Humanitarian Affairs stated that there had been extensive damage among already vulnerable communities and that communications with the affected areas have been difficult.",
"item_assets": {
"visual": {
"type": "image/tiff; application=geotiff; profile=cloud-optimized",
"roles": [
"visual"
],
"title": "Visual Image"
},
"data-mask": {
"type": "application/geopackage+sqlite3",
"roles": [
"data-mask"
],
"title": "Data Mask"
},
"ms_analytic": {
"type": "image/tiff; application=geotiff; profile=cloud-optimized",
"roles": [
"data"
],
"title": "Multispectral Image"
},
"pan_analytic": {
"type": "image/tiff; application=geotiff; profile=cloud-optimized",
"roles": [
"data"
],
"title": "Panchromatic Image"
}
},
"stac_version": "1.0.0",
"stac_extensions": [
"https://stac-extensions.github.io/item-assets/v1.0.0/schema.json",
"https://stac-extensions.github.io/render/v1.0.0/schema.json",
"https://stac-extensions.github.io/datacube/v2.2.0/schema.json"
]
}
],
"links": [
{
"rel": "root",
"type": "application/json",
"href": "https://stac.endpoint.io/"
},
{
"rel": "parent",
"type": "application/json",
"href": "https://stac.endpoint.io/"
},
{
"rel": "self",
"type": "application/json",
"href": "https://stac.endpoint.io/collections"
},
{
"rel": "data",
"type": "application/json",
"href": "https://stac.endpoint.io/collections"
},
{
"rel": "aggregate",
"type": "application/json",
"title": "Aggregate",
"href": "https://stac.endpoint.io/aggregate"
},
{
"rel": "aggregations",
"type": "application/json",
"title": "Aggregations",
"href": "https://stac.endpoint.io/aggregations"
}
]
}
2 changes: 1 addition & 1 deletion tests/fixtures/noaa-emergency-response.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"id":"noaa-emergency-response", "title": "NOAA Emergency Response Imagery", "description":"NOAA Emergency Response Imagery hosted on AWS Public Dataset.","stac_version":"1.0.0","license":"public-domain","links":[],"extent":{"spatial":{"bbox":[[-180,-90,180,90]]},"temporal":{"interval":[["2005-01-01T00:00:00Z",null]]}}}
{"id":"noaa-emergency-response", "type": "Collection", "title": "NOAA Emergency Response Imagery", "description":"NOAA Emergency Response Imagery hosted on AWS Public Dataset.","stac_version":"1.0.0","license":"public-domain","links":[],"extent":{"spatial":{"bbox":[[-87.00,35.00,-84.00,37.00]]},"temporal":{"interval":[["2005-01-01T00:00:00Z",null]]}}}
Loading