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

GeoTIFFs not being loaded with tifffile 2022.4.26 #62

Closed
Nufflee opened this issue Jul 27, 2023 · 1 comment · Fixed by #66
Closed

GeoTIFFs not being loaded with tifffile 2022.4.26 #62

Nufflee opened this issue Jul 27, 2023 · 1 comment · Fixed by #66

Comments

@Nufflee
Copy link

Nufflee commented Jul 27, 2023

When using tifffile version 2022.4.26 (as specified in the requirements.txt), all GeoTIFF files I tried to load read as NODATA (0 in below example). When I manually update tifffile to 2023.4.12 or newer, the data is being loaded properly. I tried loading these files with tifffile directly and the beahvior was the same for older versions, meaning this is not an issue with this library's code. Additionally, this issue only manifests itself when loading as zarr, if loading to a numpy array, the data is loaded correctly.

The code I used for testing:

from geotiff import GeoTiff
import numpy as np

tiff = GeoTiff('FAA_UTM18N_NAD83.tif')

data = tiff.read()

print(np.mean(data))
tifffile version output
<=2023.3.21 0
>=2023.4.12 202.33013993598698

The used GeoTIFF file can be found here.

@mdotter-mitre
Copy link

Also seeing this issue with tifffile version (>=2021.7.2,<2022.4.28) specified in the requirements.txt, but the above fix (upgrading tifffile>=2023.4.12) works.

Please provide an updated requirement.txt

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

Successfully merging a pull request may close this issue.

2 participants