Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

STAC core part one #58353

Merged
merged 4 commits into from
Oct 9, 2024
Merged

STAC core part one #58353

merged 4 commits into from
Oct 9, 2024

Conversation

uclaros
Copy link
Contributor

@uclaros uclaros commented Aug 9, 2024

Description

This is the first part of the implementation of qgis/QGIS-Enhancement-Proposals#300
It includes the building block classes for parsing and handling STAC elements and allows interacting with STAC catalogs using the QGIS browser.

The contents of both static catalogs and STAC API endpoints can be retrieved using the new STAC root entry on the browser.
image

STAC Items that contain assets that are cloud optimized (COG, COPC, EPT for now) can be drag and dropped to the map canvas and those assets will be added as layers.
Peek 2024-10-04 15-51

STAC Item assets may be downloaded to a local folder using the Download Assets dialog.
image
image

All Catalogs, Collections and Items properties can be examined using the STAC Object Details dialog:
Peek 2024-10-04 15-56

In subsequent PRs the Data Source Manager implementation will be added which will also allow searching for Items and Collections

Any feedback is warmly welcome!

@github-actions github-actions bot added this to the 3.40.0 milestone Aug 9, 2024
Copy link

github-actions bot commented Aug 9, 2024

🪟 Windows builds ready!

Windows builds of this PR are available for testing here. Debug symbols for this build are available here.

(Built from commit d770e55)

Copy link
Contributor

@troopa81 troopa81 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Really happy to see this landing in core, thanks for this work!

Local files reading and blocking network requests in QgsStacController

Could we avoid blocking request and use QgsTask ? I can see no way of canceling (I made a very very quick read of this PR though, I made have skipped it), what happen if I want to close the stac catalog window but QGIS is currently retrieving a lot of items?

@uclaros
Copy link
Contributor Author

uclaros commented Aug 26, 2024

Could we avoid blocking request and use QgsTask ? I can see no way of canceling (I made a very very quick read of this PR though, I made have skipped it), what happen if I want to close the stac catalog window but QGIS is currently retrieving a lot of items?

Blocking requests will only be used for the initial implementation on the browser panel, where QgsDataItem::createChildrent() is always called on a separate thread and there is no concept of closing/canceling in the browser.
The data source manager implementation, which will also support searching, will use async requests which could potentially be cancelled when the data source manager is closed.

@github-actions github-actions bot added the stale Uh oh! Seems this work is abandoned, and the PR is about to close. label Sep 10, 2024
@nyalldawson nyalldawson added the Freeze Exempt Feature Freeze exemption granted label Sep 13, 2024
@github-actions github-actions bot removed the stale Uh oh! Seems this work is abandoned, and the PR is about to close. label Sep 14, 2024
@qgis qgis deleted a comment from github-actions bot Sep 18, 2024
@uclaros uclaros marked this pull request as ready for review September 27, 2024 13:39
@uclaros uclaros changed the title STAC core wip STAC core part one Sep 27, 2024
@uclaros uclaros force-pushed the stac-core branch 2 times, most recently from 3ebb704 to 2e41291 Compare October 2, 2024 17:37
@saberraz
Copy link
Contributor

saberraz commented Oct 4, 2024

Nice work!
Just a minor comment on UI/UX: in the Browser panel, at the moment, ℹ️ icon is shown for the datasets:
image

Some datasets do have a preview image. It would be good to use the preview image instead of the ℹ️ icon:
image

@uclaros
Copy link
Contributor Author

uclaros commented Oct 4, 2024

Some datasets do have a preview image.

The STAC spec suggests to use thumbnail as a role for a quick preview image of the data which should be less than 600x600 pixels. Assets with this role are rendered on top of the Object Details dialog when available.
The overview role may contain large images and is probably more appropriate to actually load as a layer.

In any case, even the thumbnail images may be too big to be used as icons for the DataItems. For me it would make more sense to try and display those thumbnails on the item's tooltips instead.

Copy link
Member

@wonder-sk wonder-sk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good to me now

(we have discussed the work with Stefanos extensively, so my earlier comments have been addressed already)

If nobody objects, I would merge this tomorrow...

src/core/stac/qgsstaccontroller.h Show resolved Hide resolved
src/core/stac/qgsstacobject.h Show resolved Hide resolved
Copy link

github-actions bot commented Oct 8, 2024

🪟 Windows builds

Download Windows builds of this PR for testing.
Debug symbols for this build are available here.
(Built from commit 7b7b6e0)

🪟 Windows Qt6 builds

Download Windows Qt6builds of this PR for testing.
(Built from commit 7b7b6e0)

@wonder-sk wonder-sk added the Changelog Items that are queued to appear in the visual changelog - remove after harvesting label Oct 9, 2024
@wonder-sk wonder-sk merged commit a758dfd into qgis:master Oct 9, 2024
33 checks passed
@qgis-bot
Copy link
Collaborator

qgis-bot commented Oct 9, 2024

@uclaros

This pull request has been tagged for the changelog.

  • The description will be harvested so please provide a "nearly-ready" text for the final changelog
  • If possible, add a nice illustration of the feature. Only the first one in the description will be harvested (GIF accepted as well)
  • If you can, it's better to give credits to your sponsor, see below for different formats.

You can edit the description.

Format available for credits
  • Funded by NAME
  • Funded by URL
  • Funded by NAME URL
  • Sponsored by NAME
  • Sponsored by URL
  • Sponsored by NAME URL

Thank you!

@zacharlie zacharlie added ChangelogHarvested This PR description has been harvested in the Changelog already. and removed Changelog Items that are queued to appear in the visual changelog - remove after harvesting labels Oct 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ChangelogHarvested This PR description has been harvested in the Changelog already. Freeze Exempt Feature Freeze exemption granted
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants