Fixes for resampling to a target fits image