Freesurfer教程(ubuntu)

Freesurfer教程(ubuntu)

参考链接:http://www.wjhsh.net/zhhfan-p-13405572.html

在这里插入图片描述

1.安装

freesurfer的安装教程各个网站上都用详细的过程,这里不再叙述

这个命令是在处理tutorial_data中的dcm数据时使用的:recon-all -all -i I0 -s Subj001

该命令大概运行了4个小时。

2.操作freesurfer的官方数据集

下载数据集(8G左右)

curl https://surfer.nmr.mgh.harvard.edu/pub/data/tutorial_data.tar.gz -o tutorial_data.tar.gz   #下载数据集tutorial_data
tar -xzvf tutorial_data.tar.gz   #解压下载的数据集压缩包(将解压后的文件名命名为tutorial_data)
rm tutorial_data.tar.gz   #解压后删除下载的压缩包

配置数据集环境变量TUTORIAL_DATA,由于后面需要经常用到这个文件夹中的内容,为方便使用,在这里配置一个TUTORIAL_DATA环境变量。

export TUTORIAL_DATA=/path/to/your/tutorial/dir   #这种export方式只对当前用户起作用,建议先在/etc/profile文件中引入,再在bashrc文件中引入
ls $TUTORIAL_DATA 

#输出类似于下面,下载的数据版本不一样,输出内容也不一样
buckner_data                    fsfast-functional
diffusion_recons                fsfast-tutorial.subjects
diffusion_tutorial              long-tutorial

经过上面的步骤,说明数据已经下载好了

设置环境变量SUBJECTS_DIR

export SUBJECTS_DIR=$TUTORIAL_DATA/buckner_data/tutorial_subjs
#在打开终端的时候,profile中的SUBJECTS_DIR=/home/lihao/Downloads/freesurfer/subjects
#这个SUBJECTS_DIR的值是相对于全局的,执行export SUBJECTS_DIR$TUTORIAL_DATA/buckner_data/tutorial_subjs后,对于该终端,SUBJECTS_DIR的值就变成了后者,但是重新打开一个终端时,环境变量SUBJECTS_DIR的值还是会变为profile中的值。
cd $SUBJECT_DIR
#这里我并没有设置SUBJECTS_DIR这个环境变量,因为在之前安装freesurfer时,定义了一个SUBJECTS_DIR,为防止搞混淆,我并没有在这里设置这个环境变量。

使用freeview查看tutorial_data中的volume(这个good_output文件夹是tutorial_data中已经被处理的结果(至于处理的是哪个文件,目前还不知道))

#紧接上面的命令cd $SUBJECTS_DIR,进入tutorial_data/buckner_data/tutorial_subjs文件夹下执行下面的命令(在该文件夹下有个good_output文件夹)
freeview -v \  #反斜杠的作用是可以输入多行
good_output/mri/T1.mgz \   //T1.mgz是采用加权值处理的volume
good_output/mri/wm.mgz \
good_output/mri/brainmask.mgz \
good_output/mri/aseg.mgz:colormap=lut:opacity=0.2 \  //aseg.mgz是皮下分割的volume
-f good_output/surf/lh.white:edgecolor=blue \
good_output/surf/lh.pial:edgecolor=red \
good_output/surf/rh.white:edgecolor=blue \
good_output/surf/rh.pial:edgecolor=red

上述命令中的-v用来打开一些常用的volumes(这里的volume是算法的意思),包括:

brainmask.mgz:skull-stripped(颅骨剥离) volume primarily used for troubleshooting

wm.mgz:white(白质) matter mask also used for troubleshooting

aseg.mgz:subcortical segmentation(皮层下分割) loaded with its corresponding color table and at a low opacity(皮下分割加载了相应颜色表,且不透明度较低).

其中命令中的-f用来加载页面

使用freesurfer查看3D表面

官方教程中只给出了显示左半脑的过程

pial(软膜),white(白质),inflated surface(膨胀的表面)

sucal(沟),curvature maps(曲率图)

thickness maps(厚度图)

cortical parcellation(皮质分割)

freeview -f  good_output/surf/lh.pial:annot=aparc.annot:name=pial_aparc:visible=0 \
good_output/surf/lh.pial:annot=aparc.a2009s.annot:name=pial_aparc_des:visible=0 \
good_output/surf/lh.inflated:overlay=lh.thickness:overlay_threshold=0.1,3::name=inflated_thickness:visible=0 \
good_output/surf/lh.inflated:visible=0 \
good_output/surf/lh.white:visible=0 \
good_output/surf/lh.pial \
--viewport 3d

lh.pial:annot=aparc.annot 在软脑膜表面加载 Desikan-Killiany 皮质分区.

lh.pial:annot=aparc.a2009s.annot 将 Destrieux 皮质分区加载到软脑膜表面.

:name=pial_aparc:visible=0 changes which name shows up in the menu display and turns off this layer

lh.inflated:overlay=lh.thickness:overlay_threshold=0.1,3 加载膨胀表面顶部的厚度叠加层并设置要显示的最小和最大阈值.

Pail Surface(软膜表面)

处理原始数据(dicom数据)

在该部分之前,需要下载好官方原始数据tutorial_data,前面已经设置过环境变量TUTORIAL_DATA,并且也已经设置过环境变量SUBJECTS_DIR(这个环境变量对应的地址是存储处理结果的)

首先,进入tutorial_data中的文件夹

cd $TUTORIAL_DATA   #tutorial_data文件夹中有一个practice_with_data文件夹
cd practice_with_data   #这个文件夹中的DICOM数据就是用于处理的原始数据

学习使用命令dcmunpack

在命令行中输入dcmunpack -help

请看下面一条命令:

dcmunpack -src . -scanonly scan.log

-src . 指明要操作的文件夹,其中符号 . 表示当前文件夹,如果是其他文件夹,指明文件路径即可。

-scanonly scan.log 指明仅仅扫描这个文件夹,并生成一个日志文件,名为scan.log,该日志可用more scan.log查看。

Now that you’ve identified the scan you want to use as input to FreeSurfer, what command do you need to use to create surfaces on it?

The correct answer is recon-all.

But wait! Before we run that command, there are a few other matters to take care of…

First, before processing a subject with FreeSurfer, you always want to make sure you have:

  1. Sourced FreeSurfer (already done for you if you’re at an organized course).
  2. Set the SUBJECTS_DIR variable to the location where the FreeSurfer output should go (make sure there is enough space [around ~300MB])!

For this exercise, let’s put the FreeSurfer output directory for this subject just above the dicoms directory you have been working in. You can check where the SUBJECTS_DIR variable is currently set to by doing:

echo $SUBJECTS_DIR  #由于我并没有重新设置环境变量SUBJECTS_DATA的值,处理结果被直接保存到系统默认的SUBJECTS_DIR对应的路径中,可使用export SUBJECTS_DIR=$TUTORIAL_DATA/practice_with_data设定结果的保存位置,但我没有更改(因为prifile文件中已经有一个名为SUBJECTS_DIR的环境变量)。

Once your SUBJECTS_DIR is set, you can type up the recon-all command needed to process a subject using dicoms as the input. Try it out before looking at the answer. If things go horribly wrong, you can always do Ctrl+c to stop it 😃.

Hint:

recon-all \
  -all \
  -i  <one slice in the anatomical(解剖学) dicom series> \
  -s  <subject id that you make up> \

Some explanation on the command:

  • -all will run all the steps in the FreeSurfer processing stream. Alternatively, you can run different parts of the stream.
  • -i stands for input. Here, you would specify one dicom file/slice in the T1-weighted scan series you collected (FreeSurfer will find the rest of the files in the DICOM series/ the rest of the slices automatically). Make sure you specify the full path to the file if it is not in the directory you are currently in. You could also specify nifti files as input. If you have more than one T1-weighted scan for a given subject, use additional -i flags for each one.
  • -s specifies the name or ID of the subject you would like to use. A directory with that name will be created for all the subject’s FreeSurfer output.

实例:

recon-all -all -i I0 -s Subj001  #处理dcm文件,recon-all是reconstruction all的缩写

最终Subj001文件生成在了$SUBJECTS_DIR对应的文件夹中。

export SUBJECTS_DIR=/home/lihao/tutorial_data
recon-all -i home/lihao/tutorial_data/practice_with_data/DICOM -s Subj002
#处理home/lihao/tutorial_data/practice_with_data/DICOM文件夹中的dicom文件,生成的文件夹名为Subj002,会被自动保存到SUBJECTS_DIR文件夹下。

recon-all命令的执行流程

1.Motion Correction and Conform 运动校正与确认

2.NU(Non-Uniform intensity normalization) NU(非均匀强度标准化处理)

3.Talairach transform computation Talairach变换

4.Intensity Normalization 1 强度标准化1

5.Skull Strip 去除脑壳

6.EM Register(linear volumetric registration) EM登记(线性体积登记)

7.CA Intensity Normalization CA强度标准化

8.CA Non-linear Volumetric Registration CA非线性体积登记

9.Remove Neck 去除颈部

10.LTA with Skull 剥壳LTA

11.CA Label(Volumetric Labeling,ie Aseg)and Statistics CA标记(体积标记,如Aseg)和统计

12.Intensity Normalization 2(start here for control points) 强度标准化2(控制点开始)

13.White matter segmentation 白质分割

14.Edit WM with ASeg 白质Aseg编辑

15.Fill(start here for wm edits) 填充(开始白质编辑)

16.Tessellation (begins per-hemisphere operations) Tessellation细分曲面技术(开始每个脑半球的操作)

17.Smooth1 平滑1

18.Inflate1 胀平1

19.QSphere QSphere ,sphere 领域

20.Automatic Topology Fixer 自动化局部解剖修复

21.Final Surfs(start here for brain edits for pial surf) 最终的曲面(从这里开始编辑软脑膜)

22.Smooth2 平滑2

23.Inflate2 胀平2

24.Spherical Mapping 球形映射

25.Spherical Registration 球形登记

26.Spherical Registration,Contralateral hemisphere 球形登记。对侧半球

27.Map average curvature to subject subject平均曲率映射

28.Cortical Parcellation-Desikan_Killiany and Christophe(Labeling) 皮质划分-Desikan_Killian和Christophe分类

29.Cortical Parcellation Statistics 皮质划分统计

30.Cortical Ribbon Mask 皮质色带覆盖

31.Cortical Paracellation mapping to Aseg 皮质划分到aseg映射

参考链接:https://read.douban.com/reader/column/594403/chapter/3949428/

在这里插入图片描述

批量处理dicom文件(batch processing)

参考链接:https://blog.csdn.net/qq_28480795/article/details/112980051?utm_medium=distribute.pc_relevant.none-task-blog-2defaultbaidujs_baidulandingword~default-0-112980051-blog-121210211.pc_relevant_without_ctrlist_v3&spm=1001.2101.3001.4242.1&utm_relevant_index=3

假设您有数百个对象的DICOM文件,并且想使用FreeSurfer处理它们。 您只需提交几个命令就可以提交所有内容。

运行单个的recon-all命令有时会执行很长的一段时间,批处理通过一次执行多个recon-all节省时间。

Recon-all从MRI扫描仪收集的3D图像块中重建光滑、连续的二维表面,类似于将纸质午餐袋揉成颗粒大小,然后吹气,像气球一样膨胀。

在这里插入图片描述

recon-all并行运行

1.安装并行处理包:parallel

2.设置合适的工作目录:export SUBJECTS_DIR=…

3.将数据整理成.nii格式放到一个文件夹(SUBJECTS_DIR)中,执行如下语句:

一些扩展

alias命令,alias:别名

alias lsdir "ls /home"  #使用lsdir代替命令ls /home,在命令行中输入lsdir和ls /home效果是一样的。

更多有关alias命令的功能可参考官方教程:

https://surfer.nmr.mgh.harvard.edu/fswiki/FsTutorial/Scripts#BatchProcessingwithrecon-all

freesurfer中surf文件格式的转换:mris_convert

mris_convert参考链接:http://www.grahamwideman.com/gw/brain/fs/mris_convert_doc.htm

参考资料:https://andysbrainbook.readthedocs.io/en/latest/FreeSurfer/FS_ShortCourse/FS_03_ReconAll.html

http://www.grahamwideman.com/gw/brain/fs/index.htm

Subj001中文件夹的结构

volume处理的结果放在mri文件夹下,surface处理的结果放在surf文件夹下,label文件夹中存放分区和标签文件,stats文件夹存放各个分区的结构指标的统计值。

最终的分割数据被存放在bert/mri/aseg.mgz中,使用命令mri_extract_label aseg.mgz 17 53 hippo_mask.mgz可以将海马区的数据提取出来,其中17 53分别为左右海马区

17 53这两个数据是从freesurfer/FreeSurferColorLUT.txt这个文件中得出的,该文件中包含了各个脑区对应的索引,如下图:其中最左侧的序号是.txt文件中特有的序号,是行的序列,#No.下面的数字才是各个脑区对应的索引。

在这里插入图片描述

aseg.stats文件夹:

ColHeaders Index SegId NVoxels Volume_mm3 StructName normMean normStdDev normMin normMax normRange
1 4 6228 6559.9 Left-Lateral-Ventricle 29.2696 13.2876 10.0000 80.0000 70.0000
2 5 358 419.7 Left-Inf-Lat-Vent 43.4581 12.7698 17.0000 75.0000 58.0000
3 7 15056 15671.6 Left-Cerebellum-White-Matter 87.8059 5.6825 34.0000 102.0000 68.0000
4 8 53140 52578.3 Left-Cerebellum-Cortex 69.2497 10.0171 9.0000 95.0000 86.0000
5 10 9348 9061.8 Left-Thalamus 90.2594 8.6170 35.0000 108.0000 73.0000
6 11 3634 3621.1 Left-Caudate 81.0105 7.4487 44.0000 107.0000 63.0000
7 12 5012 5004.7 Left-Putamen 91.5247 5.1483 58.0000 111.0000 53.0000
8 13 2087 2076.8 Left-Pallidum 101.3632 3.2738 83.0000 112.0000 29.0000
9 14 801 856.9 3rd-Ventricle 40.6767 14.0769 16.0000 84.0000 68.0000
10 15 2437 2600.8 4th-Ventricle 28.6487 10.8667 12.0000 75.0000 63.0000
11 16 23325 23046.6 Brain-Stem 85.5662 9.5485 21.0000 106.0000 85.0000
12 17 4463 4323.1 Left-Hippocampus 71.7213 7.8715 30.0000 97.0000 67.0000
13 18 1802 1852.4 Left-Amygdala 76.5044 6.0529 40.0000 93.0000 53.0000
14 24 893 943.6 CSF 48.4636 14.6775 17.0000 96.0000 79.0000
15 26 408 438.5 Left-Accumbens-area 78.8774 4.9469 48.0000 90.0000 42.0000
16 28 4258 4062.3 Left-VentralDC 92.0301 10.0371 31.0000 108.0000 77.0000
17 30 21 35.5 Left-vessel 57.0476 11.3687 36.0000 76.0000 40.0000
18 31 500 417.1 Left-choroid-plexus 51.1460 13.8320 23.0000 80.0000 57.0000
19 43 6686 6851.2 Right-Lateral-Ventricle 29.8295 13.8954 8.0000 86.0000 78.0000
20 44 373 395.1 Right-Inf-Lat-Vent 37.7105 14.2212 14.0000 76.0000 62.0000
21 46 13066 13884.3 Right-Cerebellum-White-Matter 87.3713 5.3633 36.0000 104.0000 68.0000
22 47 55841 55449.6 Right-Cerebellum-Cortex 69.6814 9.8568 6.0000 98.0000 92.0000
23 49 8840 8542.3 Right-Thalamus 88.7208 8.5001 29.0000 104.0000 75.0000
24 50 3903 3842.9 Right-Caudate 79.1737 7.2862 46.0000 100.0000 54.0000
25 51 4950 4954.8 Right-Putamen 88.0438 6.0793 58.0000 102.0000 44.0000
26 52 1981 1964.8 Right-Pallidum 99.0676 3.0505 76.0000 108.0000 32.0000
27 53 4628 4540.3 Right-Hippocampus 71.4568 7.3610 34.0000 99.0000 65.0000
28 54 1691 1726.2 Right-Amygdala 71.5239 5.6283 34.0000 96.0000 62.0000
29 58 632 637.1 Right-Accumbens-area 76.0807 3.9407 56.0000 94.0000 38.0000
30 60 4547 4303.2 Right-VentralDC 91.0086 10.0299 27.0000 107.0000 80.0000
31 62 5 11.7 Right-vessel 60.0000 7.3485 52.0000 70.0000 18.0000
32 63 588 523.3 Right-choroid-plexus 52.5731 12.6487 20.0000 78.0000 58.0000
33 72 0 0.0 5th-Ventricle 0.0000 0.0000 0.0000 0.0000 0.0000
34 77 777 737.7 WM-hypointensities 70.5740 10.5095 40.0000 107.0000 67.0000
35 78 0 0.0 Left-WM-hypointensities 0.0000 0.0000 0.0000 0.0000 0.0000
36 79 0 0.0 Right-WM-hypointensities 0.0000 0.0000 0.0000 0.0000 0.0000
37 80 0 0.0 non-WM-hypointensities 0.0000 0.0000 0.0000 0.0000 0.0000
38 81 0 0.0 Left-non-WM-hypointensities 0.0000 0.0000 0.0000 0.0000 0.0000
39 82 0 0.0 Right-non-WM-hypointensities 0.0000 0.0000 0.0000 0.0000 0.0000
40 85 218 222.2 Optic-Chiasm 79.0826 16.3161 38.0000 106.0000 68.0000
41 251 1049 967.6 CC_Posterior 96.7026 13.0807 46.0000 111.0000 65.0000
42 252 773 708.2 CC_Mid_Posterior 94.6054 15.6483 17.0000 112.0000 95.0000
43 253 572 526.8 CC_Central 95.5315 14.0085 41.0000 112.0000 71.0000
44 254 652 594.3 CC_Mid_Anterior 95.1779 15.2288 33.0000 112.0000 79.0000
45 255 1103 1024.3 CC_Anterior 97.7199 13.1296 35.0000 119.0000 84.0000

一些英文以及缩写

NumVert, Number of Vertices 顶点的数量

WhiteSurfArea, White Surface Total Area 白色表面的所有面积

MeanThicknes, Mean Thickness 平均厚度

BrainSeg,BrainSegVol, Brain Segmentation Volume segmentation 分段

BrainSegNotVent,BrainSegVolNotVent, Brain Segmentation Volume Without Ventricels ,ventricle 脑室

BrainSegNotVentSurf,BrainSegVolNotVentSurf, Brain Segmentation Volume Without Ventricle from surf

Cortex,CortexVol, Total cortical gray matter volume , cortical 皮质

SupraTentorial,SupraTentorialVol, Supratentorial volume, supratentorial 幕上

EstimatedTotalIntraCranialVol,eTIV, Estimated Total Intracranial Volume, intracranial 颅内

cerebral 颅内;大脑

ventricle 脑室

lateral 侧,旁边

cerebellum 小脑

cortex 皮质

thalamus 丘脑

caudate 尾状核

putamen 壳核

pullidum 苍白球

hippocampus 海马体

amygdala 杏仁核

accumbens-area 伏隔区

vessel 血管

ventral 腹侧

choroid-plexus 脉络丛

hypointensities 低信号

optic-chiasm 视交叉

insula 岛状

temporal pole temporal 颞 pole 极

front 正面

curvature 曲率

threshold 临界点

subcortical 皮下的

mri文件夹:

该文件夹中存放的是dcm文件处理后的各个分支部分,如wm.mgz中是有关大脑白质的数据

brainmask.mgz skull-stripped volume primarily used for troubleshooting(skull:头盖顾;strip:剥去)

wm.mgz white matter mask also used for troubleshooting

aseg.mgz subcortical segmentation loaded with its corresponding(相应的) color table and at a low opacity(不透明性,模糊).For more information on the subcortical segmentation,see here: https://surfer.nmr.mgh.harvard.edu/fswiki/SubcorticalSegmentation 大脑中的皮质白质,和皮质下结构 (subcortical 皮下的;segmentation 分割,分裂; ) aseg是automatic subcortical segmentation的缩写。

orig.mgz 大脑组织中白质的第一次遍历(后期会在该数据上继续操作,让数据更精确化)

white.mgz 对orig.mgz进一步的处理得到更精确化的white.mgz

pial.mgz 沿着white.mgz中的白质向外延申到边界,就是灰质的边界,最终形成pial.mgz,这个过程称为剥离,从灰色表面到剥离表面的距离是灰质的厚度。

将pial数据进行膨胀,得到inflated文件,这些inflated文件可以进一步膨胀成一个球体

在这里插入图片描述

surf文件夹:

参考链接:http://www.wjhsh.net/zhhfan-p-13405572.html

该文件夹下.white、.sphere、.inflated等网格点文件,每一个文件里都存储了大脑皮质表面网格点的三维坐标及相邻顶点构成的三角面信息,Freesurfer采用的是RAS坐标系,其意义为R:right,X轴方向;A:anterior,Y轴方向;S:superior,Z轴正方向。

freesurfer也会在surf文件夹下生成基于曲面的形态特征数据,不同的特征采用不同的文件名后缀,如皮质厚度(.thickness)、雅可比度量(.jacobian.white)、脑沟(.sulc)、曲率(.curv)、外表面积(.area)、体积(.volume)等面数据文件,其坐标索引号与Mesh网格序号一致。

Freesurfer在图像处理过程中依据Destrieux分区法对脑区进行标签划分,该分区方法将大脑皮质表面划分为75个脑区,其分区结构主要为脑回脑沟,分区依据为曲率的大小,其脑回区域只包括脑膜表面的部分,而隐藏在下面的部分则被划分为脑沟区域。其分区文件为label文件夹下的?h.aparc.a2009s.annot文件,该文件下还有对应的部分Broadmann分区文件(?.label)。(注:.annot和.label是脑分区文件)。

recon-all命令可以处理原始数据进行脑区分割,改命令使用的文件类型为.mgz/.nii/.nii.gz当文件格式为其他格式时候,可使用命令mri_convert ? ?.nii或者mris_convert ? ?.nii

freesurfer中各个脑区对应的索引(皮下组织的索引)可以从$FREESURFER_HOME/FreeSurferColorLUT.txt文件中查看:
在这里插入图片描述

皮层下体积统计信息保存在bert/stats/aseg.stats中,统计信息包括Index(在统计信息中的序号),SegId(对应的脑区索引),NVoxels(分割的体素数量),StrutName(在LUT中的名字),Mean/StdDev/Min/Max/Range:ROI的强度统计。

在这里插入图片描述

FreeSurfer使用了多种皮质分割方法,使用Desikan/Killiany Atlas可分为35个脑区,数据保存在bert/label/?h.aparc.annot中,使用Destrieux Atlas时,可分出58个脑区,保存在bert/label/?h.aparc.a2009s.annot文件中。两种方法分割的统计信息保存在bert/stats中,如:?h.aparc.stats和?h.aparc.a2009s.stats。MRI数据分别保存为bert/mri/aparc.DKTatlas+aseg.mgz以及bert/mri/aparc.a2009s+aseg.mgz,除此之外还有一个bert/mri/aparc+aseg.mgz

统计信息表现为下图,StructName表示结构名,NumVert表示结构中包含的定点数,SurfArea表示表面积,GrayVol表示灰质体积,ThickAvg/ThickStd表示厚度的均值与标准差,MeanCurv表示平均曲率,GausCurv表示平均高斯曲率,FoldInd表示折叠指数,CurvInd表示去路指数。

在这里插入图片描述

最终分割数据保存在bert/mri/aseg.mgz中,使用命令mri_extract_label aseg.mgz 17 53 hippo_mask.mgz可以将海马区的数据取出,其中17 53分为左右海马区,是从文件$FREESURFER_HOME/FreeSurferColorLUT.txt中得出的。

Here are some surfaces you can look at with Freeview:

pial,white and inflated surface (pial 软膜的,脑膜的;)

sulcal and curvature maps (sulcal 沟槽的;curvature 曲率;弯曲;曲度)

thickness maps

cortical parcellation (cortical 皮质的,外皮的;parcellation 分割)

freeview -f  good_output/surf/lh.pial:annot=aparc.annot:name=pial_aparc:visible=0 \
good_output/surf/lh.pial:annot=aparc.a2009s.annot:name=pial_aparc_des:visible=0 \
good_output/surf/lh.inflated:overlay=lh.thickness:overlay_threshold=0.1,3::name=inflated_thickness:visible=0 \
good_output/surf/lh.inflated:visible=0 \
good_output/surf/lh.white:visible=0 \
good_output/surf/lh.pial \
--viewport 3d

lh.pial:annot=aparc.annot loads the Desikan-Killiany cortical(皮质的,外皮的) parcellation(分割) on the pial(软膜的,脑膜的) surface。

lh.pial:annot=aparc.a2009s.annot loads the Destrieux cortical(皮质的,外皮的) parcellation(分割) on the pial(软膜的,脑膜的) surface.其中的pial_aparc_des 中的des是Destrieux,FreeSurfer 在图像处理过程中依据 Destrieux 分区法对脑区进行标签划分该方法将大脑皮质表面划分为75个脑区其分区结构主要为各脑回和脑沟,分区依据为曲率的大小,其脑回区域只包括脑膜表面的部分,而隐藏在下面的部分则被划分为脑沟区域,脑沟区域的分区文件为label文件夹下的?h.aparc.a2009s.annot文件,该文件夹下还有对应的部分Broadmann分区文件(?.label)。(freesuefer中使用多种皮质层的分割方法,使用Desikan/Killiany Atlas可分为35个脑区,数据保存在bert/label/?h.aparc.annot中,使用Destrieux Atlas时,可以分出58个脑区,保存在bert/label/?h.aparc.a2009s.annot文件中。这两种方法分割的统计信息保存在bert/stats中,例如?h.aparc.stats和 ?h.aparc.a2009s.stats,MRI数据分别保存为bert/mri/aparc.DKTatlas+aseg.mgz以及bert/mri/aparc.a2009s+aseg.mgz,除此之外还有一个bert/mri/aparc+aseg.mgz,注意,上面提到的是?.aparc.annot文件和?.aparc.a2009s.annot文件是皮质层的分割方法,即大脑皮层的分割方式,大脑皮层也笼统的说为大脑).

:name=pial_aparc:visible=0 changes which name shows up in the menu display and turns of this layer.(aparc:automatic parcellation 自动分割)

lh.inflated:overlay=lh.thickness:overlay_threshold=0.1,3 loads the thickness overlay(覆盖) on top of the infalted surface and sets the min and max thresholds(threshold 门槛,界限) to display。

pial surface

在这里插入图片描述

white surface

在这里插入图片描述

inflated surface

在这里插入图片描述

thickness map

在这里插入图片描述

cortical parcellation(Desikan-Killiany parcellation) pial_aparc

在这里插入图片描述

cortical parcellation(Destrieux parcellation) pial_aparc-des

在这里插入图片描述

使用recon-all命令时,会产生两种分割,一种是Desikan-Killiany分割产生的?h.aparc.annot文件(annot应该是annotation:注解的缩写),另一种是Destrieux分割产生的?h.aparc.a2009s.annot文件。The difference is the number and designation of the areas that are labeled.You can load the Destrieux parcellation by clicking on the drop down box next to “Annotation” on the panel and choosing Load from file… Browse to lh.aparc.a2009c.annot and hit ‘Open’.

生成的.ctab文件表示分割完后的颜色信息

在这里插入图片描述

以及.label文件,上图中每一个颜色块都是一个label.

下图中展示的是Desikan-Killiany分区与Destrieux分区的区别:

左脑Desikan-Killiany分区(35个区域)

在这里插入图片描述

在这里插入图片描述

左脑Destrieux分区(75个区域,资料中说是58个,但点击View/Edit可以看到75个分区)

在这里插入图片描述

在这里插入图片描述

上面提到的大脑分区方法:

Brodmann Areas(布罗德曼分区)

Brodmann分区是由德国医生Korbinian Brodmann在1909年根据大脑皮层的厚度,细胞层数和其中细胞的不同结构提出的,是目前比较常用的分区方法。每个区域的命名不但与其所处的位置(前/中/后/腹侧/背侧的顶叶/额叶/枕叶/颞叶等)有关,研究者们也希望找到该区参与的生命活动,用最能代表该区域功能的词命名他们,其实每个活动都可能涉及多个脑区的不同部分,有时并不能用一个功能区概括该区有贡献的所有的活动,人们更愿意将这称为脑区。

preview

从头顶中央沟算起,往后是顶叶(parietal lobe),往前是额叶(frontal lobe).

中央沟前面的中央后回主要与躯体感受有关:
1-3:初级躯体感受皮层

5:Somatosensory Association Cortex 躯体运动感觉联合区,与本体感受相关

7:Visuo-Motor Coordination 是视觉与本体感觉交汇处,与身体所处空间位置有关,经常和BA5-同在处理语言等高级任务时被激活,至此大约是高马尾的位置。

中央沟前面的中央前回主要与躯体运动有关:
4:Primary Motor Cortex初级运动皮层,位于中央前回和中央旁小叶前部。

6:前运动皮层+补充运动区SMC,分别在中央前回的前面和中央旁小叶前面。

其他额叶处脑区:

8:Intermediate frontal(includes Frontal eye fields) 位于前运动皮层的前面,与复杂运动的planning有关,受损会导致眼球向受损一侧的强直性偏移。

9:Granular frontal 包括背侧和内侧的前额叶,左侧和右侧具有不同的功能,与短期记忆,听觉语言注意有关,是很高级的皮层。

10:Frontopolar(DLFC) 最前面那部分前额叶,由此向下进入了眶额皮质(眶额皮质因位于眼眶之上而得名,在人脑中包括BA10,BA11和BA47)。与制定战略相关的BA10也是大脑皮层中最大的一块细胞结构,被发现可能与工作记忆,多任务协作,决策及执行相关。

11:Prefrontal(Orbitofrontal) 眶额皮质的一部分,从这部分开始皮层已经转到了腹侧,与长期记忆编码,计划,决策等都有关系。

12:Prefrontal(Orbitofrontal) 是从长尾猴属大脑分区中借鉴过来的,位于额叶中最”底部“的部分,与基底神经节的活动联系紧密。

44-45:左侧包含布洛卡区(Broca’s area),设计语义表达的动作执行。

46:Middle frontal

47:Orbital

位于大脑最后方的是枕叶,初级视皮层和很多视觉功能在这里完成:

17:striate (Primary visual cortex, V1) 初级视皮层也叫纹状皮层,接受从丘脑外侧膝状体传来的视网膜信号。
18:parastriate (Secondary visual cortex, V2) 在V1周围环绕自然分成四个区,同样也对简单的朝向/颜色/频率等性质做出响应,但比V1更受注意的调控,接收V1的信号向V3、V4、V5/MT传输的同时对V1有反馈调节。
19:视觉联合区,包括V3,V4,V5。V3分为上方的Dorsal V3和下方的Ventral V3,人类中还存在V3A和V3B的细分,V3A被认为与运动视觉相关。

视觉的腹侧信号通路由枕叶在侧面向前延伸,到达颞叶,与通过视觉信息回忆物体有关。

20:inferior temporal gyrus 颞下回,腹侧视觉通路的终站,与视觉识别记忆有关。
21:middle temporal gyrus 颞中回,与语言和听觉相关。
22:superior temporal gyrus 颞上回,初级听觉皮层。与感觉性失语有关的韦尼克区(Wernicke’s Area)位于左侧颞上回的尾部(该区域受到损坏,患者对语言理解有障碍,无法理解听到的和看到的句子的含义,尽管可以流利地连接词语,但说出的句子可能没有意义);右侧颞上回与区分音调、识别旋律有关。

扣带回(Cingulate cortex)被大脑皮层包裹,覆盖在胼胝体(corpus callosum)上,

23, 31:Posterior cingulate cortex (PCC)腹侧及背侧后扣带皮层,是默认网络活动的中心节点,与昏迷或麻醉状态中的意识活动有关。
24, 32, 33:Anterior cingulate cortex 前扣带皮层(ACC),与注意力分配,条件反射及情绪相关。

37 - occipitotemporal
38 - temporopolar (temporal pole)
39 – angular
40 - supramarginal
41-42 – ant. & posterior transverse temporal

还有一些太小或位于深部

13 - insular
25 - subgenual
26 - ectosplenial
28 - entorhinal
29 - granular retrolimbic
30 - agranular retrolimbic
33 - pregenual
34 - dorsal entorhinal
35 - perirhinal
36 - ectorhinal
43 - subcentral
48 - retrosubicular
52 - parainsular

Anatomical ROI analysis

参考链接:https://surfer.nmr.mgh.harvard.edu/fswiki/FsTutorial/AnatomicalROIV6.0

Relationship between segmentation,parcellation and LookUp Table(LUT)

freeview -v 004/mri/orig.mgz \
004/mri/aparc+aseg.mgz:colormap=lut:opacity=0.4 \
-f 004/surf/lh.white:annot=aparc.annot

注意上面的命令

-f 004/surf/lh.white:annot=aparc.annot

其中-f 表示显示的是surf文件,annot是分区文件(测试.annot文件的渲染效果)

aparc+aseg.mgz是Desikan-Killiany atlas,aparc.a2009s+aseg.mgz是Destrieux altas

查看LookUp Table(LUT)

less $FREESURFER_HOME/FreeSurferColorLUT.txt

stats files

During the FreeSurfer processing stream, via the recon-all script, some statistical output files are generated. They are kept in each subjectsstats/subdirectory and are generated for the subcortical segmentation (aseg) and the cortical parcellation (aparc). These tables include information on each labeled region for the individual subject. You can view these output files via the terminal or a text editor.

aparc+aseg.mgz是segmentation volume,aparc.annot是cortical surface parcellation

测试批处理,显卡是否能够提升recon-all的速度

recon-all是重建所有,有没有recon-?? 指定重建左脑或者右脑的命令,直接从.dcm文件中处理(这个.dcm文件是包含所有大脑信息的)

mri_extract_label aseg.mgz 17 53 hippo_mask.mgz 测试该条命令,提取各个分区在这里插入图片描述

  • 6
    点赞
  • 80
    收藏
    觉得还不错? 一键收藏
  • 2
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值