Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

aMSM throwing error messages #22

Open
YaoMeng94 opened this issue Dec 13, 2021 · 5 comments
Open

aMSM throwing error messages #22

YaoMeng94 opened this issue Dec 13, 2021 · 5 comments

Comments

@YaoMeng94
Copy link

YaoMeng94 commented Dec 13, 2021

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
Copy link
Author

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

@ecr05
Copy link
Owner

ecr05 commented Dec 13, 2021

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
Copy link
Author

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
Copy link
Owner

ecr05 commented Dec 13, 2021

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
Copy link
Author

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants