Skip to content

Commit

Permalink
Merge pull request #1080 from xcube-dev/konstntokas-1077-stac_non_con…
Browse files Browse the repository at this point in the history
…formant_collection

Xcube server STAC API now returns a conformant collection time extent
  • Loading branch information
konstntokas authored Oct 8, 2024
2 parents 16cef10 + e4ba6c1 commit 033af87
Show file tree
Hide file tree
Showing 7 changed files with 1,097 additions and 1,065 deletions.
4 changes: 4 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@
(#1069)
* Bug fix in `resampling_in_space` when projecting from geographic to non-geographic
projection. (#1073)
* Bug fix of the `extent` field in the single item collection published by the xcube
server STAC API so that it follows the
[collection STAC specifications](https://github.com/radiantearth/stac-spec/blob/master/collection-spec/collection-spec.md#extent-object).
(#1077)

### Enhancements

Expand Down
2,072 changes: 1,037 additions & 1,035 deletions test/webapi/ows/stac/demo-collection.json

Large diffs are not rendered by default.

14 changes: 7 additions & 7 deletions test/webapi/ows/stac/stac-datacubes-item.json
Original file line number Diff line number Diff line change
Expand Up @@ -383,10 +383,10 @@
"tileUrl": "http://localhost:8080/datasets/demo-1w/vars/conc_chl/tiles2/{z}/{y}/{x}",
"tileLevelMin": 7,
"tileLevelMax": 9,
"colorBarName": "plasma",
"colorBarName": "my_cmap",
"colorBarNorm": "lin",
"colorBarMin": 0.0,
"colorBarMax": 24.0,
"colorBarMax": 20.0,
"htmlRepr": "<table>\n <tr>\n <td>\n <table style=\"border-collapse: collapse;\">\n <thead>\n <tr>\n <td> </td>\n <th> Array </th>\n <th> Chunk </th>\n </tr>\n </thead>\n <tbody>\n \n <tr>\n <th> Bytes </th>\n <td> 45.78 MiB </td>\n <td> 488.28 kiB </td>\n </tr>\n \n <tr>\n <th> Shape </th>\n <td> (3, 1000, 2000) </td>\n <td> (1, 250, 250) </td>\n </tr>\n <tr>\n <th> Dask graph </th>\n <td colspan=\"2\"> 96 chunks in 15 graph layers </td>\n </tr>\n <tr>\n <th> Data type </th>\n <td colspan=\"2\"> float64 numpy.ndarray </td>\n </tr>\n </tbody>\n </table>\n </td>\n <td>\n <svg width=\"194\" height=\"124\" style=\"stroke:rgb(0,0,0);stroke-width:1\" >\n\n <!-- Horizontal lines -->\n <line x1=\"10\" y1=\"0\" x2=\"24\" y2=\"14\" style=\"stroke-width:2\" />\n <line x1=\"10\" y1=\"15\" x2=\"24\" y2=\"29\" />\n <line x1=\"10\" y1=\"30\" x2=\"24\" y2=\"44\" />\n <line x1=\"10\" y1=\"45\" x2=\"24\" y2=\"59\" />\n <line x1=\"10\" y1=\"60\" x2=\"24\" y2=\"74\" style=\"stroke-width:2\" />\n\n <!-- Vertical lines -->\n <line x1=\"10\" y1=\"0\" x2=\"10\" y2=\"60\" style=\"stroke-width:2\" />\n <line x1=\"14\" y1=\"4\" x2=\"14\" y2=\"64\" />\n <line x1=\"19\" y1=\"9\" x2=\"19\" y2=\"69\" />\n <line x1=\"24\" y1=\"14\" x2=\"24\" y2=\"74\" style=\"stroke-width:2\" />\n\n <!-- Colored Rectangle -->\n <polygon points=\"10.0,0.0 24.9485979497544,14.948597949754403 24.9485979497544,74.9485979497544 10.0,60.0\" style=\"fill:#ECB172A0;stroke-width:0\"/>\n\n <!-- Horizontal lines -->\n <line x1=\"10\" y1=\"0\" x2=\"130\" y2=\"0\" style=\"stroke-width:2\" />\n <line x1=\"14\" y1=\"4\" x2=\"134\" y2=\"4\" />\n <line x1=\"19\" y1=\"9\" x2=\"139\" y2=\"9\" />\n <line x1=\"24\" y1=\"14\" x2=\"144\" y2=\"14\" style=\"stroke-width:2\" />\n\n <!-- Vertical lines -->\n <line x1=\"10\" y1=\"0\" x2=\"24\" y2=\"14\" style=\"stroke-width:2\" />\n <line x1=\"25\" y1=\"0\" x2=\"39\" y2=\"14\" />\n <line x1=\"40\" y1=\"0\" x2=\"54\" y2=\"14\" />\n <line x1=\"55\" y1=\"0\" x2=\"69\" y2=\"14\" />\n <line x1=\"70\" y1=\"0\" x2=\"84\" y2=\"14\" />\n <line x1=\"85\" y1=\"0\" x2=\"99\" y2=\"14\" />\n <line x1=\"100\" y1=\"0\" x2=\"114\" y2=\"14\" />\n <line x1=\"115\" y1=\"0\" x2=\"129\" y2=\"14\" />\n <line x1=\"130\" y1=\"0\" x2=\"144\" y2=\"14\" style=\"stroke-width:2\" />\n\n <!-- Colored Rectangle -->\n <polygon points=\"10.0,0.0 130.0,0.0 144.9485979497544,14.948597949754403 24.9485979497544,14.948597949754403\" style=\"fill:#ECB172A0;stroke-width:0\"/>\n\n <!-- Horizontal lines -->\n <line x1=\"24\" y1=\"14\" x2=\"144\" y2=\"14\" style=\"stroke-width:2\" />\n <line x1=\"24\" y1=\"29\" x2=\"144\" y2=\"29\" />\n <line x1=\"24\" y1=\"44\" x2=\"144\" y2=\"44\" />\n <line x1=\"24\" y1=\"59\" x2=\"144\" y2=\"59\" />\n <line x1=\"24\" y1=\"74\" x2=\"144\" y2=\"74\" style=\"stroke-width:2\" />\n\n <!-- Vertical lines -->\n <line x1=\"24\" y1=\"14\" x2=\"24\" y2=\"74\" style=\"stroke-width:2\" />\n <line x1=\"39\" y1=\"14\" x2=\"39\" y2=\"74\" />\n <line x1=\"54\" y1=\"14\" x2=\"54\" y2=\"74\" />\n <line x1=\"69\" y1=\"14\" x2=\"69\" y2=\"74\" />\n <line x1=\"84\" y1=\"14\" x2=\"84\" y2=\"74\" />\n <line x1=\"99\" y1=\"14\" x2=\"99\" y2=\"74\" />\n <line x1=\"114\" y1=\"14\" x2=\"114\" y2=\"74\" />\n <line x1=\"129\" y1=\"14\" x2=\"129\" y2=\"74\" />\n <line x1=\"144\" y1=\"14\" x2=\"144\" y2=\"74\" style=\"stroke-width:2\" />\n\n <!-- Colored Rectangle -->\n <polygon points=\"24.9485979497544,14.948597949754403 144.9485979497544,14.948597949754403 144.9485979497544,74.9485979497544 24.9485979497544,74.9485979497544\" style=\"fill:#ECB172A0;stroke-width:0\"/>\n\n <!-- Text -->\n <text x=\"84.948598\" y=\"94.948598\" font-size=\"1.0rem\" font-weight=\"100\" text-anchor=\"middle\" >2000</text>\n <text x=\"164.948598\" y=\"44.948598\" font-size=\"1.0rem\" font-weight=\"100\" text-anchor=\"middle\" transform=\"rotate(-90,164.948598,44.948598)\">1000</text>\n <text x=\"7.474299\" y=\"87.474299\" font-size=\"1.0rem\" font-weight=\"100\" text-anchor=\"middle\" transform=\"rotate(45,7.474299,87.474299)\">3</text>\n</svg>\n </td>\n </tr>\n</table>",
"attrs": {
"color_table_blue_values": [
Expand Down Expand Up @@ -462,10 +462,10 @@
"tileUrl": "http://localhost:8080/datasets/demo-1w/vars/conc_tsm/tiles2/{z}/{y}/{x}",
"tileLevelMin": 7,
"tileLevelMax": 9,
"colorBarName": "PuBuGn",
"colorBarName": "cmap_bloom_risk",
"colorBarNorm": "lin",
"colorBarMin": 0.0,
"colorBarMax": 100.0,
"colorBarMin": 0,
"colorBarMax": 3,
"htmlRepr": "<table>\n <tr>\n <td>\n <table style=\"border-collapse: collapse;\">\n <thead>\n <tr>\n <td> </td>\n <th> Array </th>\n <th> Chunk </th>\n </tr>\n </thead>\n <tbody>\n \n <tr>\n <th> Bytes </th>\n <td> 45.78 MiB </td>\n <td> 488.28 kiB </td>\n </tr>\n \n <tr>\n <th> Shape </th>\n <td> (3, 1000, 2000) </td>\n <td> (1, 250, 250) </td>\n </tr>\n <tr>\n <th> Dask graph </th>\n <td colspan=\"2\"> 96 chunks in 15 graph layers </td>\n </tr>\n <tr>\n <th> Data type </th>\n <td colspan=\"2\"> float64 numpy.ndarray </td>\n </tr>\n </tbody>\n </table>\n </td>\n <td>\n <svg width=\"194\" height=\"124\" style=\"stroke:rgb(0,0,0);stroke-width:1\" >\n\n <!-- Horizontal lines -->\n <line x1=\"10\" y1=\"0\" x2=\"24\" y2=\"14\" style=\"stroke-width:2\" />\n <line x1=\"10\" y1=\"15\" x2=\"24\" y2=\"29\" />\n <line x1=\"10\" y1=\"30\" x2=\"24\" y2=\"44\" />\n <line x1=\"10\" y1=\"45\" x2=\"24\" y2=\"59\" />\n <line x1=\"10\" y1=\"60\" x2=\"24\" y2=\"74\" style=\"stroke-width:2\" />\n\n <!-- Vertical lines -->\n <line x1=\"10\" y1=\"0\" x2=\"10\" y2=\"60\" style=\"stroke-width:2\" />\n <line x1=\"14\" y1=\"4\" x2=\"14\" y2=\"64\" />\n <line x1=\"19\" y1=\"9\" x2=\"19\" y2=\"69\" />\n <line x1=\"24\" y1=\"14\" x2=\"24\" y2=\"74\" style=\"stroke-width:2\" />\n\n <!-- Colored Rectangle -->\n <polygon points=\"10.0,0.0 24.9485979497544,14.948597949754403 24.9485979497544,74.9485979497544 10.0,60.0\" style=\"fill:#ECB172A0;stroke-width:0\"/>\n\n <!-- Horizontal lines -->\n <line x1=\"10\" y1=\"0\" x2=\"130\" y2=\"0\" style=\"stroke-width:2\" />\n <line x1=\"14\" y1=\"4\" x2=\"134\" y2=\"4\" />\n <line x1=\"19\" y1=\"9\" x2=\"139\" y2=\"9\" />\n <line x1=\"24\" y1=\"14\" x2=\"144\" y2=\"14\" style=\"stroke-width:2\" />\n\n <!-- Vertical lines -->\n <line x1=\"10\" y1=\"0\" x2=\"24\" y2=\"14\" style=\"stroke-width:2\" />\n <line x1=\"25\" y1=\"0\" x2=\"39\" y2=\"14\" />\n <line x1=\"40\" y1=\"0\" x2=\"54\" y2=\"14\" />\n <line x1=\"55\" y1=\"0\" x2=\"69\" y2=\"14\" />\n <line x1=\"70\" y1=\"0\" x2=\"84\" y2=\"14\" />\n <line x1=\"85\" y1=\"0\" x2=\"99\" y2=\"14\" />\n <line x1=\"100\" y1=\"0\" x2=\"114\" y2=\"14\" />\n <line x1=\"115\" y1=\"0\" x2=\"129\" y2=\"14\" />\n <line x1=\"130\" y1=\"0\" x2=\"144\" y2=\"14\" style=\"stroke-width:2\" />\n\n <!-- Colored Rectangle -->\n <polygon points=\"10.0,0.0 130.0,0.0 144.9485979497544,14.948597949754403 24.9485979497544,14.948597949754403\" style=\"fill:#ECB172A0;stroke-width:0\"/>\n\n <!-- Horizontal lines -->\n <line x1=\"24\" y1=\"14\" x2=\"144\" y2=\"14\" style=\"stroke-width:2\" />\n <line x1=\"24\" y1=\"29\" x2=\"144\" y2=\"29\" />\n <line x1=\"24\" y1=\"44\" x2=\"144\" y2=\"44\" />\n <line x1=\"24\" y1=\"59\" x2=\"144\" y2=\"59\" />\n <line x1=\"24\" y1=\"74\" x2=\"144\" y2=\"74\" style=\"stroke-width:2\" />\n\n <!-- Vertical lines -->\n <line x1=\"24\" y1=\"14\" x2=\"24\" y2=\"74\" style=\"stroke-width:2\" />\n <line x1=\"39\" y1=\"14\" x2=\"39\" y2=\"74\" />\n <line x1=\"54\" y1=\"14\" x2=\"54\" y2=\"74\" />\n <line x1=\"69\" y1=\"14\" x2=\"69\" y2=\"74\" />\n <line x1=\"84\" y1=\"14\" x2=\"84\" y2=\"74\" />\n <line x1=\"99\" y1=\"14\" x2=\"99\" y2=\"74\" />\n <line x1=\"114\" y1=\"14\" x2=\"114\" y2=\"74\" />\n <line x1=\"129\" y1=\"14\" x2=\"129\" y2=\"74\" />\n <line x1=\"144\" y1=\"14\" x2=\"144\" y2=\"74\" style=\"stroke-width:2\" />\n\n <!-- Colored Rectangle -->\n <polygon points=\"24.9485979497544,14.948597949754403 144.9485979497544,14.948597949754403 144.9485979497544,74.9485979497544 24.9485979497544,74.9485979497544\" style=\"fill:#ECB172A0;stroke-width:0\"/>\n\n <!-- Text -->\n <text x=\"84.948598\" y=\"94.948598\" font-size=\"1.0rem\" font-weight=\"100\" text-anchor=\"middle\" >2000</text>\n <text x=\"164.948598\" y=\"44.948598\" font-size=\"1.0rem\" font-weight=\"100\" text-anchor=\"middle\" transform=\"rotate(-90,164.948598,44.948598)\">1000</text>\n <text x=\"7.474299\" y=\"87.474299\" font-size=\"1.0rem\" font-weight=\"100\" text-anchor=\"middle\" transform=\"rotate(45,7.474299,87.474299)\">3</text>\n</svg>\n </td>\n </tr>\n</table>",
"attrs": {
"long_name": "Total suspended matter dry weight concentration",
Expand Down Expand Up @@ -3918,7 +3918,7 @@
"Conventions": "CF-1.7"
},
"attributions": [
"© by Brockmann Consult GmbH 2020, contains modified Copernicus Data 2019, processed by ESA"
"\u00a9 by Brockmann Consult GmbH 2020, contains modified Copernicus Data 2019, processed by ESA"
]
},
"datetime": null,
Expand Down Expand Up @@ -4252,4 +4252,4 @@
"href": "http://localhost:8080/tiles/demo-1w/c2rcc_flags/0/0/0?time=2017-01-22T00:00:00.000000000"
}
}
}
}
Loading

0 comments on commit 033af87

Please sign in to comment.