SeaBee-no / documentation

Repo for all SeaBee documentation
https://seabee-no.github.io/documentation/
0 stars 0 forks source link

Publish orthorectification report PDF #55

Open JamesSample opened 5 months ago

JamesSample commented 5 months ago

A new function should be added to seabeepy.ortho to check for an orthorectification summary report located at ./report/report.pdf. If this exists, it should be renamed to match the layer name (e.g. grouping_area_datetime_[spectrum_type]_[elevation]m_odm_orthorec_report.pdf and then published to GeoNode along with the mosaic image.

JamesSample commented 5 months ago

In this commit, I added a new function called upload_document_to_geonode to sb.geo. This should make it possible to upload any supported document types to GeoNode via the API.

However, the version of GeoNode we are currently using does not support document upload via the API. See the link here, which currently says

HTTP 200 OK
Allow: GET, PATCH

If/when we upgrade GeoNode to v4.1 or above, this should include POST

HTTP 200 OK
Allow: GET, PATCH, POST

Once we can POST to the documents endpoint, the new function needs testing. It can be added to flights_runner.ipynb and used to upload ODM reports as part of the publishing workflow.