MAINT: some cleanups in ndimage.morphology and ndimage.measurements.