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

RasterFootprint with antimeridian-spanning sentinel-1 image gives incorrect and odd footprint #425

Open
philvarner opened this issue May 11, 2023 · 2 comments
Labels
bug Something isn't working

Comments

@philvarner
Copy link
Collaborator

philvarner commented May 11, 2023

Describe the bug

Using RasterFootprint with a sentinel-1 image that crosses the antimeridian gives an incorrect and odd footprint.

To reproduce

See attached script, and the 3 files it generates. This produces a geojson that looks like:

image

Then splitting it with either the stactools antimeridian package or gadomski/antimeridian give inverted results.

Expected behavior

RasterFootprint gives me a correct geometry over the raster.

Additional context

repro.py.txt

bad_footprint_split_with_antimeridian.geojson.txt
bad_footprint_split_with_stactools_antimeridian.geojson.txt
bad_footprint.geojson.txt

@philvarner philvarner added the bug Something isn't working label May 11, 2023
@philvarner philvarner changed the title RasterFootprint with sentinel-1 image gives incorrect and odd footprint RasterFootprint with antimeridian-spanning sentinel-1 image gives incorrect and odd footprint May 11, 2023
@gadomski gadomski added this to the 0.5.0 milestone May 11, 2023
@gadomski
Copy link
Member

gadomski commented May 11, 2023

Might be fixed once #421 is done, so I'll do #421 first and then take a look at the repro. Thanks for the report.

@gadomski gadomski self-assigned this May 11, 2023
@philvarner
Copy link
Collaborator Author

I ran it without the scaling also, and got the same result.

with WarpedVRT(src) as vrt:
                    return RasterFootprint(
                    vrt.read(1),
                    vrt.crs,
                    vrt.transform,
                    no_data=0,
                    simplify_tolerance=simplify_tolerance,
                ).footprint()

@gadomski gadomski removed their assignment May 16, 2023
@gadomski gadomski removed this from the 0.5.0 milestone Aug 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants