Workaround for ndimage.affine_transform endianness bug

Fixes #275.
> I may be missing something but the out parameter is passed into the function to
> be modified.

Sure, my bad. Please ignore my previous comment.

> Another thing I thought of is that we probably want to do some scipy version
> check if the scipy bug gets fixed in the future.

Let's not worry with this.

:+1: for merge!