Strange behavior with basemap.interp() and masked arrays

Hi,

I am trying to use basemap’s interp function for regridding purposes, and I need to be able to handle masked arrays. Using bilinear or nearest-neighbor interpolation (order=1, order=0), it seems to work fine for masked arrays. However, none of the elements get masked after using cubic spline interpolation (order=3). I am assuming that the reason for this is due to the limitations of scipy.ndimage.map_coordinates(), which gets called when order=3. Are there currently any workarounds for this?

Thanks,

Alex

···


Alex Goodman