sct_image: remove file removal kludge (#1688) (#1705)
sct_image: remove file removal kludge (#1688) (#1705)

When running something like:
sct_compute_snr -v 1 -i t2s_concat.nii.gz -m gre-me_1_seg.nii.gz -vol
0,1

The code was writing a file gre-me_1_seg_RPI.nii.gz with the call to
set_orientation(), and it was doing it in the current (work) directory,
then if the output filename was not set, it was just overwriting it,
else it wanted to create a new one and remove that temporary file.

With the fixes in temp. dir management, it failed.

Now, we just wrap all set_orientation() invocations by working in a
temporary directory, and no unwanted file will be created in the working
directory.

There shouldn't be side effects.

Former-commit-id: d008e3b59f9887bd09b6052695977a03122fe48a
neuropoly/spinalcordtoolbox,neuropoly/spinalcordtoolbox,neuropoly/spinalcordtoolbox,neuropoly/spinalcordtoolbox,neuropoly/spinalcordtoolbox,neuropoly/spinalcordtoolbox,neuropoly/spinalcordtoolbox