Hi!
I am trying to use ndimage's uniform_filter (for a simple local mean filtering) on a map-projected image that has NAN's at the border (basically the corners where the rotated map projected image does not fit into the rectangular grid).
Is there a way, maybe in skimage, to use a uniform_filter on an array that contains NANs? ndimage' version does not cope with it correctly:
> arr = array([np.nan, 1,2,3,4,5,np.nan])
> arr
array([ nan, 1., 2., 3., 4., 5., nan])
> nd.filters.uniform_filter(arr, 3)
array([ nan, nan, nan, nan, nan, nan, nan])
Cheers,
Michael