Open AndongZhou12 opened 1 month ago
Dear Andong,
The horzcat
error points to an issue with the length of the multiple regressors vectors, presumably the one created from the logfiles vs. the nifti image files CSF etc.). Here are some questions to explore:
noise_rois
), does the script run through?noise_rois
(no logfiles specified), does the script run through?.nii
file exactly have 344 volumes, as specified in the sqpar.Nscans
?matlabbatch{1}.spm.tools.physio.model.noise_rois.yes.fmri_files = {
'/Users/zhouandong/Desktop/800p/800_CNBT.nii,1'
'/Users/zhouandong/Desktop/800p/800_CNBT.nii,2'
...
'/Users/zhouandong/Desktop/800p/800_CNBT.nii,344'
}
You can use functions such as spm_select
to create this array automatically.
I hope this helps!
All the best, Lars
Dear Andong,
The
horzcat
error points to an issue with the length of the multiple regressors vectors, presumably the one created from the logfiles vs. the nifti image files CSF etc.). Here are some questions to explore:
- If you only use the logfiles (no
noise_rois
), does the script run through?- If you only use the
noise_rois
(no logfiles specified), does the script run through?- Does your
.nii
file exactly have 344 volumes, as specified in thesqpar.Nscans
?- If not, or if (2) fails with a wrong number of volumes, you may have to specify the 344 volumes within the 4D nifti-file explicitly, e.g.,
matlabbatch{1}.spm.tools.physio.model.noise_rois.yes.fmri_files = { '/Users/zhouandong/Desktop/800p/800_CNBT.nii,1' '/Users/zhouandong/Desktop/800p/800_CNBT.nii,2' ... '/Users/zhouandong/Desktop/800p/800_CNBT.nii,344' }
You can use functions such as
spm_select
to create this array automatically.I hope this helps!
All the best, Lars
Dear Lars,
Thank you for the suggestions, there are very helpful and I found the mistakes I made. One is that the realignment parameter I got from AFNI is not compatible with SPM (AFNI uses degrees for the roll, pitch and yaw parameters, whereas SPM12 uses radians), therefore I transfrom them into the correct version for SPM. The second mistake is a bit embarrassing, I think I mistakenly typed the Nscans to 344 (it is 342 instead!) After that I can get the regressors and SPM.mat with the logfiles and the movement files.
However, when I want to added the final step (the ROIs: the combined nii and white matter and CSF files), I can see a fancy plot been generated but got this error message: '14-Jun-2024 16:16:52 - Failed 'TAPAS PhysIO Toolbox' Unrecognized field name "cm". In file "/Users/zhouandong/Desktop/spm12/toolbox/PhysIO/code/model/tapas_physio_create_noise_rois_regressors.m" (???), function "tapas_physio_create_noise_rois_regressors" at line 186. In file "/Users/zhouandong/Desktop/spm12/toolbox/PhysIO/tapas_physio_main_create_regressors.m" (???), function "tapas_physio_main_create_regressors" at line 360. In file "/Users/zhouandong/Desktop/spm12/toolbox/PhysIO/tapas_physio_cfg_matlabbatch.m" (???), function "run_physio" at line 1661.
The following modules did not run: Failed: TAPAS PhysIO Toolbox'
Can you give me some more guidance, I am really appreciated for the help!
Best wishes, Andong
Dear Andong,
The
horzcat
error points to an issue with the length of the multiple regressors vectors, presumably the one created from the logfiles vs. the nifti image files CSF etc.). Here are some questions to explore:
- If you only use the logfiles (no
noise_rois
), does the script run through?- If you only use the
noise_rois
(no logfiles specified), does the script run through?- Does your
.nii
file exactly have 344 volumes, as specified in thesqpar.Nscans
?- If not, or if (2) fails with a wrong number of volumes, you may have to specify the 344 volumes within the 4D nifti-file explicitly, e.g.,
matlabbatch{1}.spm.tools.physio.model.noise_rois.yes.fmri_files = { '/Users/zhouandong/Desktop/800p/800_CNBT.nii,1' '/Users/zhouandong/Desktop/800p/800_CNBT.nii,2' ... '/Users/zhouandong/Desktop/800p/800_CNBT.nii,344' }
You can use functions such as
spm_select
to create this array automatically.I hope this helps!
All the best, Lars
Hi Lars,
after trying: physio.verbose.level = 1;
I succeed!!!!!
Thank u so much!
Best wishes, Andong
Dear Lars,
I am currently using the PhysIO toolbox for generating the regressors for 7T multi-echo data. I also got the CSF and whiter matter anat files, and combined functional nii file and realignment parameters. However, no matter how I modify my codes (I also tried turn off the ROIs and parameters), the same error appeared: 03-Jun-2024 22:07:16 - Failed 'TAPAS PhysIO Toolbox' Error using horzcat Dimensions of arrays being concatenated are not consistent. In file "/Users/zhouandong/Desktop/spm12/toolbox/PhysIO/tapas_physio_main_create_regressors.m" (???), function "append_regressors" at line 466. In file "/Users/zhouandong/Desktop/spm12/toolbox/PhysIO/tapas_physio_main_create_regressors.m" (???), function "tapas_physio_main_create_regressors" at line 363. In file "/Users/zhouandong/Desktop/spm12/toolbox/PhysIO/tapas_physio_cfg_matlabbatch.m" (???), function "run_physio" at line 1661.
Can you give me some suggestions?
The following modules did not run: Failed: TAPAS PhysIO Toolbox
800_PULS.log 800_RESP.log 800_Info.log ME.txt
Best wishes, Andong