BUG: fix ndimage functions for large data

map_coordinates uses int to index into data arrays which can overflow
for arrays of several gigabytes size. Patch by @cgohlke.
some other occurances of int replaced by npy_intp for safety.
Closes gh-3733