Resample surf.gii (fmriprep output) from fsnative to fsaverage

Dear experts,

I am seeking help on resampling the anat/ file from fsnative space to fsaverage space. Currently, I have functional outputs in both fsaverage and fsaverage5 spaces. The file in fsaverage space is essential for the smoothing.

It appears that is the registration file for fsaverage, while is the sphere surface. Could you please advise me on how to proceed with this resampling?

Thank you!

Hi @yijun,


mri_surf2surf \
--srcsubject $SUBJECT \
--srcsurfval $ \
--trgsubject fsaverage \
--trgsurfval $ \
--hemi $HEMI


Thanks for your reply. I tried before, it didn’t work. Please see the error message below:

mri_surf2surf --srcsubject sub-LM002 --srcsurfval /media/dcnladmin/sunset/LM/test/testsurfresample/ --trgsubject fsaverage --trgsurfval /media/dcnladmin/sunset/LM/test/testsurfresample/ --hemi lh


setenv SUBJECTS_DIR /media/dcnladmin/sunset/LM/test/testsurfresample
cd /media/dcnladmin/sunset/LM/test/testsurfresample
mri_surf2surf --srcsubject sub-LM002 --srcsurfval /media/dcnladmin/sunset/LM/test/testsurfresample/ --trgsubject fsaverage --trgsurfval /media/dcnladmin/sunset/LM/test/testsurfresample/ --hemi lh 

sysname  Linux
hostname dcnladmin-Super-Server
machine  x86_64
user     dcnladmin
srcsubject = sub-LM002
srcval     = /media/dcnladmin/sunset/LM/test/testsurfresample/
srctype    = 
trgsubject = fsaverage
trgval     = /media/dcnladmin/sunset/LM/test/testsurfresample/
trgtype    = 
srcsurfreg = sphere.reg
trgsurfreg = sphere.reg
srchemi    = lh
trghemi    = lh
frame      = 0
fwhm-in    = 0
fwhm-out   = 0
label-src  = (null)
label-trg  = (null)
OKToRevFaceOrder  = 1
UseDualHemi = 0
Reading source surface reg /media/dcnladmin/sunset/LM/test/testsurfresample/sub-LM002/surf/lh.sphere.reg
Loading source data
** DA[1] has coordsys with intent NIFTI_INTENT_TRIANGLE (should be NIFTI_INTENT_POINTSET)
MRISreadGiftiAsMRI: no overlay data found in file /media/dcnladmin/sunset/LM/test/testsurfresample/
Segmentation fault (core dumped)

Hi @Steven ,
the mri_surf2surf only works with metric data, not the surface itself.
hemi-L_thickness.shape.gii <------worked <------didn’t work