Try using -lta instead of --reg

On 7/5/2025 12:22 PM, Zahnert, Felix wrote:
Dear experts,
I ran into an issue running mri_vol2vol after running bbregister using freesurfer 8.
Running the same commands in freesurfer 7.4.1 worked well. bbregister worked in both versions, while mri_vol2vol (8.0.0) resulted in the following error:

INFO: This REGISTER_DAT transform is valid only for volumes between  COR types with c_(r,a,s) = 0.
[...]
INFO: using NIfTI-1 sform (sform_code=2)
error: File exists
error: LTAchangeType: src geometry must be valid

Running version 7.4.1 mri_vol2vol using the .dat file generated with bbregister version 8.0.0 worked as well.

The commands:

# bbregister, where fs8 is the freesurfer directory of the subject (SUBJECTS_DIR has been set to 'structural_dir', in which fs8 is located)
reg_file="$out_dir/diff2str.dat"
bbregister --s fs8 --mov "$b0" --reg "$reg_file" --fslmat "${reg_file%.dat}.mat" --dti

# mri_vol2vol cmd below, working in version 7.4.1, but not in version 8.0.0
# with mov being a map of diffusion metrics in the same space as b0 here

mri_vol2vol \
        --mov "$mov" \ 
        --targ "$structural_dir/fs8/mri/T1.mgz" \
        --o "$output" \
        --no-save-reg --reg "$reg_file"

I also tried the following prior to mri_vol2vol, which did not help: mri_convert -rl "$b0" -rt nearest "$my_mov" "$my_mov_modified"
I encountered the same issue when running mri_vol2vol and bbregister with the identical input as --mov.

Might there be a bug in version 8's mri_vol2vol, or am I missing something?

Thank you for your help!

Best,

Felix


_______________________________________________
Freesurfer mailing list -- freesurfer@nmr.mgh.harvard.edu
To unsubscribe send an email to freesurfer-leave@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman3/lists/freesurfer@nmr.mgh.harvard.edu/