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

Support multispectral geotiffs #115

Open
HowcanoeWang opened this issue Oct 11, 2024 · 2 comments
Open

Support multispectral geotiffs #115

HowcanoeWang opened this issue Oct 11, 2024 · 2 comments
Assignees
Labels
enhancement New feature or request
Milestone

Comments

@HowcanoeWang
Copy link
Member

e.g. NDVI geotiff with two layers, first is ndvi, second is alpha

Multi-GeoTiff, with several layers, each layer has -32767 or has alpha layer

logic:

input parameter: has_alpha_layer or has_alpha_value

if has_alpha_layer: merge masks
if has_alpha_value: extract mask and merge

@HowcanoeWang HowcanoeWang added the enhancement New feature or request label Oct 11, 2024
@HowcanoeWang HowcanoeWang added this to the 2.0.1 milestone Oct 11, 2024
@HowcanoeWang HowcanoeWang self-assigned this Oct 11, 2024
@HowcanoeWang
Copy link
Member Author

Multiple-band test files explanation

NDVI 2 layers

图片

Multi-spectral 2 layers

2024-10-21_10-38

HowcanoeWang added a commit that referenced this issue Oct 21, 2024
@HowcanoeWang
Copy link
Member Author

GeoTiff.polygon_math not support multi-spectral

File ~/Documents/Github/EasyIDP/easyidp/geotiff.py:817, in GeoTiff.polygon_math(self, polygon_hv, is_geo, kernel)
    inside_value = imarray[mask, :]   # (mxn-o, 4)
else:
-->    raise IndexError("Only support (m,n) dsm and (m,n,4) RGBA dom")
def _get_idx(group, thresh, compare="<="):
    if thresh.shape == ():  # single value

IndexError: Only support (m,n) dsm and (m,n,4) RGBA dom

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Status: No status
Development

No branches or pull requests

1 participant