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

Anchor argument overridden in odc.stac.load #151

Open
pjhartzell opened this issue Apr 10, 2024 · 0 comments
Open

Anchor argument overridden in odc.stac.load #151

pjhartzell opened this issue Apr 10, 2024 · 0 comments

Comments

@pjhartzell
Copy link

Problem

In odc-stac version 0.3.9, odc.stac.load is overriding an anchor argument value of AnchorEnum.CENTER with the AnchorEnum.EDGE value.

Minimal Example

This is illustrated in a Jupyter notebook accessing some simple STAC Items at https://github.com/pjhartzell/data-gap/blob/main/anchor.ipynb.

Potential solution

In looking through the output_geobox function, it looks like the incoming anchor argument is never used. Is it possible that L968 should be changed from:

anchor = _anchor

to something like this?

anchor = anchor if anchor else _anchor

Versions, hardware

odc-stac==0.3.9
odc-geo==0.4.3

Tested with Python 3.9 and 3.11.

Apple M1 (arm64)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant