Pearl Harbor doesn't like OpenCL #17

mathuin opened this Issue Oct 17, 2012 · 3 comments

1 participant


For some reason, the Pearl Harbor region does not work well with the OpenCL code for PrepRegion. The inverse distance tree code works.


Specific coordinates: --ymax 21.3951 --xmin -158.0337 --ymin 21.2977 --xmax -157.9230


Turns out the IDT tree fails silently by generating empty ocean! Wacky.

So, the problem also exists for Alaska (well, Point Barrow anyway). I think I've narrowed down the problem.

The conterminous US uses L01 for landcover values. Puerto Rico uses L10. Hawaii uses L07. Alaska uses L04. Both Hawaii and Alaska maps return maps in WGS 84 projection, whereas the rest use NAD 83. Additionally, Hawaii and Alaska both have different Albers parameters than the conterminous US and Puerto Rico: the latter have parallels of 29.5 and 45.5 and a center of 23,-96 while the former have parallels of 8 and 18 and a center of 3,-157 for Hawaii and parallels of 55 and 56 and a center of 50,-154 for Alaska.

I think I need to use gdalwarp to transform all L04 and L07 files to match L01 parameters, before going any further.


Okay, I have written a patch which runs gdalwarp on all incoming files to force them to the L01 values. Before I commit this I need to run it on a few showcase examples to ensure it doesn't break something else.

@mathuin mathuin added a commit that closed this issue Oct 19, 2012
@mathuin Fixes #17, updates pymclevel, very minor cleanup.
The problem with Alaska and Hawaii maps has been resolved by
converting every map to the target SRS before further processing.

Additionally, I have updated pymclevel to the latest version in order
to use the supplied Height value and some other performance improvements.

I also did some very minor cleanup of the code in buildvrts(), and
handled the nodata-that-isn't-reported-as-nodata case for landcover.
@mathuin mathuin closed this in 2fcb426 Oct 19, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment