-
Notifications
You must be signed in to change notification settings - Fork 66
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
Update the probabilistic maps for the Segmentation? #254
Comments
Actually "OldSeg" in spm12 (equivalent to "Segment" in spm8) needs grey/white/csf.nii to carry the segmentation. Could you copy/paste your script ? |
You mean the MATLAB code for the step Segment? stage = stage + 1;
stage_segmentation = stage;
matlabbatch{stage}.spm.spatial.preproc.channel.vols = {anatfile };
matlabbatch{stage}.spm.spatial.preproc.warp.write = [0 1];
matlabbatch{stage}.spm.spatial.preproc.channel.biasreg = 0.001;
matlabbatch{stage}.spm.spatial.preproc.channel.biasfwhm = 60;
matlabbatch{stage}.spm.spatial.preproc.channel.write = [0 1];
ngaus = [1 1 2 3 4 2];
native = [1 1 1 0 0 0];
for c = 1:6 % tissue class c
matlabbatch{stage}.spm.spatial.preproc.tissue(c).tpm = {
fullfile(spm('dir'), 'tpm', sprintf('TPM.nii,%d', c))};
matlabbatch{stage}.spm.spatial.preproc.tissue(c).ngaus = ngaus(c);
matlabbatch{stage}.spm.spatial.preproc.tissue(c).native = [native(c) 0];
matlabbatch{stage}.spm.spatial.preproc.tissue(c).warped = [0 0];
end
matlabbatch{stage}.spm.spatial.preproc.warp.mrf = 1;
matlabbatch{stage}.spm.spatial.preproc.warp.cleanup = 1;
matlabbatch{stage}.spm.spatial.preproc.warp.reg = [0 0.001 0.5 0.05 0.2];
matlabbatch{stage}.spm.spatial.preproc.warp.affreg = 'mni';
matlabbatch{stage}.spm.spatial.preproc.warp.fwhm = 0;
matlabbatch{stage}.spm.spatial.preproc.warp.samp = 3;
matlabbatch{stage}.spm.spatial.preproc.warp.write = [1 1]; |
Well, I was expecting pypreprocess script :) Anyway, this looks like Segment in spm12 which uses tpm.nii In pypreprocess, if you do |
Yes, I've seen the "newsegment" option in my config file. |
If we now accept that spm12 is the default, we should not use newsegment=True, but just segment=True, right? |
Because we have had issues that data of two subjects cannot be segmented correctly.
We found that pypreprocess is using the probabilistic maps for SPM8
'/i2bm/local/spm12/toolbox/OldSeg/grey.nii',
'/i2bm/local/spm12/toolbox/OldSeg/white.nii',
'/i2bm/local/spm12/toolbox/OldSeg/csf.nii'
When we tried with the latest probabilistic maps for SPM12, it solved our problems.
/i2bm/local/spm12/tmp/TMP.nii.1 % grey matter
/i2bm/local/spm12/tmp/TMP.nii.2 % white matter
/i2bm/local/spm12/tmp/TMP.nii.3 % CSF
/i2bm/local/spm12/tmp/TMP.nii.4 % bone
/i2bm/local/spm12/tmp/TMP.nii.5 % soft tissue
/i2bm/local/spm12/tmp/TMP.nii.6 % air/background
Do you have any concern to keep the SPM8 maps, or could it be updated to the SPM12 version?
Thanks!
The text was updated successfully, but these errors were encountered: