-
Notifications
You must be signed in to change notification settings - Fork 15
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
Raster footprint generation #53
Comments
thanks for sharing @drnextgis I believe I've already implemented some of this in https://github.com/developmentseed/rio-stac/blob/main/rio_stac/stac.py#L53-L73 but I couldn't (or didn't want) to go further down the
|
Fair enough. What would you recommend for a user who loves |
I guess you'll need to create some custom code import rasterio
from rio_stac import create_stac_item
with rasterio.open("my.tif") as src:
item = create_stac_item(
src,
input_datetime=input_datetime,
extensions=extensions,
collection=collection,
collection_url=collection_url,
properties=property,
id=id,
asset_name=asset_name,
asset_href=asset_href,
asset_media_type=asset_mediatype,
with_proj=with_proj,
with_raster=with_raster,
with_eo=with_eo,
raster_max_size=max_raster_size,
geom_densify_pts=densify_geom,
geom_precision=geom_precision,
)
item.geometry = get_precise_geo(src)
|
The more I think about it the more I think that maybe we could add optional dependency (shapely) to allow this! Like if the user request |
rio-stac
creates a geometry property using a raster extent. I found this article explaining how to generate convex hulls of valid raster data for use in STAC Item geometries to be very useful. I believe it would be beneficial to have this option incorporated intorio-stac
.The text was updated successfully, but these errors were encountered: