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

rare crash when running mardo_5/estimate #8

Open
Remi-Gau opened this issue Nov 16, 2022 · 3 comments
Open

rare crash when running mardo_5/estimate #8

Remi-Gau opened this issue Nov 16, 2022 · 3 comments

Comments

@Remi-Gau
Copy link

Using marsbar to run some roi analysis within the BIDS pipeline we use in the lab.

I am getting this error once in a while when trying to estimate a model with MarsBar.

It is reproducible but only for specific to a given subject + ROI combination:

  • the same ROI in MNI space will work fine with other subjects
  • the estimation for same subject will work fine on some other ROIs

Also it seems that this crash is more frequent when using the FAST correction for auto-correlation rather than the default AR(1).

Error message

For the syntax spdiags(B,d,m,n), the size of B must be min(m,n)-by-length(d).

Error in pr_estimate (line 128)
    s     = spdiags(1./sqrt(diag(s)),0,nScan,nScan);

Error in pr_estimate (line 345)
    SPM = pr_estimate(SPM,marsY);

Error in mardo_5/estimate (line 72)
SPM        = pr_estimate(SPM, marsY);

Error in bidsRoiBasedGLM (line 119)
        estimation = estimate(model, data);

Related

related to Remi-Gau/olfactory_fmri_blind#12
related to cpp-lln-lab/bidspm#689

Could try to provide a minimal working example if that helps but that may take some time in terms of data wrangling.

@matthew-brett
Copy link
Collaborator

I'd expect the default SPM ReML autocorrelation to fail sometimes - is that what you mean? But I would expect the fmristat AR(1) to always succeed. Does it sometimes fail?

What do you mean by the FAST correction? (Sorry, it's been a while since I went back over this).

@Remi-Gau
Copy link
Author

Remi-Gau commented Nov 16, 2022

I'd expect the default SPM ReML autocorrelation to fail sometimes - is that what you mean?

yup

But I would expect the fmristat AR(1) to always succeed. Does it sometimes fail?

It failed something like 3 times out of 3000 (rough estimate). So pretty rare.

What do you mean by the FAST correction? (Sorry, it's been a while since I went back over this).

SPM12 lets you choose this for rapidly sampled fMRI time series

https://onlinelibrary.wiley.com/doi/full/10.1002/hbm.24218

Screenshot from 2022-11-16 21-37-42

@Remi-Gau
Copy link
Author

FYI: a fix for this is not urgent at all

Just wanted to post this here in case someone else encounters this

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