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

Duplicate rasterization in align_and_resize_raster_stack when masking with a vector #366

Closed
phargogh opened this issue Jan 30, 2024 · 1 comment
Assignees
Labels
enhancement New feature or request in progress Working on it!

Comments

@phargogh
Copy link
Member

When using a vector mask in align_and_resize_raster_stack, the vector is rasterized once for each layer that needs to be aligned and masked - and if this is a big vector or a big raster, that can be prohibitively expensive. Runtime is not really an issue for small regions and/or at coarse resolutions, and especially if the vector has very simple geometry.

A preferable solution would be to only rasterize once and then reuse that vector mask once for each warp call.

@phargogh phargogh added the enhancement New feature or request label Jan 30, 2024
@phargogh phargogh self-assigned this Jan 30, 2024
@phargogh phargogh added the in progress Working on it! label Jan 30, 2024
phargogh added a commit to phargogh/pygeoprocessing that referenced this issue Jan 31, 2024
phargogh added a commit to phargogh/pygeoprocessing that referenced this issue Jan 31, 2024
phargogh added a commit to phargogh/pygeoprocessing that referenced this issue Jan 31, 2024
phargogh added a commit to phargogh/pygeoprocessing that referenced this issue Jan 31, 2024
phargogh added a commit to phargogh/pygeoprocessing that referenced this issue Jan 31, 2024
phargogh added a commit to phargogh/pygeoprocessing that referenced this issue Jan 31, 2024
phargogh added a commit to phargogh/pygeoprocessing that referenced this issue Jan 31, 2024
phargogh added a commit to phargogh/pygeoprocessing that referenced this issue Jan 31, 2024
phargogh added a commit to phargogh/pygeoprocessing that referenced this issue Feb 1, 2024
phargogh added a commit to phargogh/pygeoprocessing that referenced this issue Feb 6, 2024
phargogh added a commit to phargogh/pygeoprocessing that referenced this issue Feb 6, 2024
@phargogh
Copy link
Member Author

phargogh commented Feb 6, 2024

Resolved in #367

@phargogh phargogh closed this as completed Feb 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request in progress Working on it!
Projects
None yet
Development

No branches or pull requests

1 participant