ecr05 / MSM_HOCR

Multimodal Surface Matching with Higher order Clique Reduction: Mac OS and Linux binaries
35 stars 10 forks source link

aMSM throwing error messages #22

Open YaoMeng94 opened 2 years ago

YaoMeng94 commented 2 years ago

Hi Emma,

I trying using MSM (MSM_ubuntu_v3, V3.0FSL) to register the infant cerebral surface between two timepoints of dHCP, I have setting the config file refer to your 2017 NI paper (provided in this repository, /config/NeuroImage2017_configs/aMSM_STR_longitudinal_alignment), the command looks like:

msm_ubuntu_v3 \ --inmesh=origin_sphere.surf.gii --refmesh=reference_sphere.gii --inanat=origin_midthickness.surf.gii --refanat=reference_midthickness.surf.gii --indata=origin_sulc.shape.gii --refdata=reference_sulc.shape.gii -o from-origin_to-reference_mode- --conf /NeuroImage2017_configs/aMSM_STR_longitudinal_alignment --verbose

and the configuration file including parameters: --simval=2,2,2 --sigma_in=6,4,2 --sigma_ref=6,4,2 --lambda=0.025,0.025,0.025 --it=40,40,40 --opt=DISCRETE,DISCRETE,DISCRETE --CPgrid=2,3,4 --SGgrid=4,5,6 --datagrid=4,5,6 --anatgrid=4,5,6 --regoption=5 --regexp=2 --dopt=HOCR --VN --rescaleL --triclique --k_exponent=2 --bulkmod=1.6 --shearmod=0.4

but it throwing error messages: "error: inv(): matrix appears to be singular

terminate called after throwing an instance of 'std::runtime_error' what(): inv(): matrix appears to be singular Aborted (core dumped)"

and the output files including: from-origin_to-reference_mode-anat.reg.surf.gii from-origin_to-reference_mode-sphere.LR.reg.surf.gii from-origin_to-reference_mode-sphere.reg.surf.gii from-origin_to-reference_mode-transformed_and_reprojected.fuc.gii

but some subjects will have more outputs than the previous example with extra files: from-origin_to-reference_mode-STRAINS.func.gii

So I just wandering what's the correct output files should included when running aMSM? And is the less output situation meaning that the aMSM is not correctly performed?

Another question is that in Gracia et al., PNAS, 2018 paper, the config file described in supplementing information is: image image

which is not consistent with your blog which aMSM should be --regoption=5 instead of --regoption=3(spherical registration), is this inconsistence due to different software version?

I know this is a long and too-specific question, very much appreciate for you patience and looking forward to get your reply😁

Yao Meng

YaoMeng94 commented 2 years ago

I also attach the terminal output of the one that returning error message: MSMrunninglog.txt

ecr05 commented 2 years ago

Try increasing the regularisation perhaps, and run it level by level. It's telling you that the mesh is folding (breaking the diffeomorphism).

The mode is regoption 5 now

The outputs look fine

YaoMeng94 commented 2 years ago

Thanks Emma,

I will try some configurations with larger lambda (like in Gracia et al., PNAS, 2018), is this your suggestion if I understand it correctly?

ecr05 commented 2 years ago

Yes but also you can use the command line argument --levels to run the optimisation one resolution level at a time, that way it is easier to optimise. Kara took a different approach to optimising to me. I can't say which is better

YaoMeng94 commented 2 years ago

Understood, I will try the --levels option first, huge thanks to your help!