Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import os
- import rasterio
- file_path = os.path.abspath('path/to/tza10povcons125.tif')
- raster = rasterio.open(file_path)
- band = raster.read(1)
- array([[ -3.39999995e+38, -3.39999995e+38, -3.39999995e+38, ...,
- -3.39999995e+38, -3.39999995e+38, -3.39999995e+38],
- [ -3.39999995e+38, -3.39999995e+38, -3.39999995e+38, ...,
- -3.39999995e+38, -3.39999995e+38, -3.39999995e+38],
- [ -3.39999995e+38, -3.39999995e+38, -3.39999995e+38, ...,
- -3.39999995e+38, -3.39999995e+38, -3.39999995e+38],
- ...,
- [ -3.39999995e+38, -3.39999995e+38, -3.39999995e+38, ...,
- -3.39999995e+38, -3.39999995e+38, -3.39999995e+38],
- [ -3.39999995e+38, -3.39999995e+38, -3.39999995e+38, ...,
- -3.39999995e+38, -3.39999995e+38, -3.39999995e+38],
- [ -3.39999995e+38, -3.39999995e+38, -3.39999995e+38, ...,
- -3.39999995e+38, -3.39999995e+38, -3.39999995e+38]], dtype=float32)
- >>> import numpy as np
- >>> np.finfo('float32').min
- -3.4028235e+38
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement