Re: reading with a window doesn't honour window shape

Guillaume Lostis <guillaume@...>


If you add `out_shape=(1200, 1200)` to your `read()` call it returns an array with the right shape. I don't know exactly why you need to specify this though.



Le ven. 15 janv. 2021 à 17:48, Paolo Corti <pcorti@...> a écrit :
Hi all

I have the following problem: I want to read a dataset using a window with a specific shape, but the window shape isn't always honored from the returned array.

You can replicate this problem using this dataset:

with as src_pop:
window = Window(col_off=1470.4999917338748, row_off=2902.4961942222235, width=1200, height=1200)
pop_arr =, window=window)

print returns (1200, 1199) while it should be (1200, 1200)

Any idea why this could happen?
Thanks in advance


Paolo Corti
Geospatial software developer
twitter: @capooti
skype: capooti

Join to automatically receive all group messages.