fdg-neurosegmenter 1.0.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- fdg_neurosegmenter-1.0.0/LICENSE +21 -0
- fdg_neurosegmenter-1.0.0/PKG-INFO +261 -0
- fdg_neurosegmenter-1.0.0/README.md +219 -0
- fdg_neurosegmenter-1.0.0/pyproject.toml +36 -0
- fdg_neurosegmenter-1.0.0/setup.cfg +4 -0
- fdg_neurosegmenter-1.0.0/src/fdg_neurosegmenter/__init__.py +0 -0
- fdg_neurosegmenter-1.0.0/src/fdg_neurosegmenter/data/CN_quantification.csv +538 -0
- fdg_neurosegmenter-1.0.0/src/fdg_neurosegmenter/data/label_correspondence.csv +53 -0
- fdg_neurosegmenter-1.0.0/src/fdg_neurosegmenter/quantifier.py +121 -0
- fdg_neurosegmenter-1.0.0/src/fdg_neurosegmenter/segmenter.py +34 -0
- fdg_neurosegmenter-1.0.0/src/fdg_neurosegmenter/utilities.py +215 -0
- fdg_neurosegmenter-1.0.0/src/fdg_neurosegmenter.egg-info/PKG-INFO +261 -0
- fdg_neurosegmenter-1.0.0/src/fdg_neurosegmenter.egg-info/SOURCES.txt +15 -0
- fdg_neurosegmenter-1.0.0/src/fdg_neurosegmenter.egg-info/dependency_links.txt +1 -0
- fdg_neurosegmenter-1.0.0/src/fdg_neurosegmenter.egg-info/entry_points.txt +3 -0
- fdg_neurosegmenter-1.0.0/src/fdg_neurosegmenter.egg-info/requires.txt +9 -0
- fdg_neurosegmenter-1.0.0/src/fdg_neurosegmenter.egg-info/top_level.txt +1 -0
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2025 NM-Radiopharmacology
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
|
@@ -0,0 +1,261 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: fdg-neurosegmenter
|
|
3
|
+
Version: 1.0.0
|
|
4
|
+
Summary: AI-based anatomical segmentation and regional quantification of brain [18F]FDG PET acquisitions
|
|
5
|
+
Author: Luísa C. Silva
|
|
6
|
+
License: MIT License
|
|
7
|
+
|
|
8
|
+
Copyright (c) 2025 NM-Radiopharmacology
|
|
9
|
+
|
|
10
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
11
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
12
|
+
in the Software without restriction, including without limitation the rights
|
|
13
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
14
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
15
|
+
furnished to do so, subject to the following conditions:
|
|
16
|
+
|
|
17
|
+
The above copyright notice and this permission notice shall be included in all
|
|
18
|
+
copies or substantial portions of the Software.
|
|
19
|
+
|
|
20
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
21
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
22
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
23
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
24
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
25
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
26
|
+
SOFTWARE.
|
|
27
|
+
|
|
28
|
+
Classifier: Programming Language :: Python :: 3
|
|
29
|
+
Classifier: Topic :: Scientific/Engineering :: Medical Science Apps.
|
|
30
|
+
Description-Content-Type: text/markdown
|
|
31
|
+
License-File: LICENSE
|
|
32
|
+
Requires-Dist: torch>=2.0.0
|
|
33
|
+
Requires-Dist: nnunetv2>=2.0
|
|
34
|
+
Requires-Dist: itk<6.0,>=5.4.0
|
|
35
|
+
Requires-Dist: pandas<3.0,>=2.2.0
|
|
36
|
+
Requires-Dist: numpy<2.0,>=1.26.0
|
|
37
|
+
Requires-Dist: SimpleITK<3.0,>=2.0.0
|
|
38
|
+
Requires-Dist: scipy>=1.10.0
|
|
39
|
+
Requires-Dist: tqdm>=4.60.0
|
|
40
|
+
Requires-Dist: scikit-image>=0.20.0
|
|
41
|
+
Dynamic: license-file
|
|
42
|
+
|
|
43
|
+
# FDG-NeuroSegmenter
|
|
44
|
+
<b>FDG-NeuroSegmenter</b> is a deep-learning-based model developed to perform the automatic segmentation of 52
|
|
45
|
+
anatomical regions in brain [<sup>18</sup>F]FDG PET images.
|
|
46
|
+
|
|
47
|
+
Please cite [REF!]
|
|
48
|
+
|
|
49
|
+
<img src="/figures/fdg_brain_segmentation.png" alt="[18F]FDG PET brain anatomical segmentation" style="max-width: 95%; height: auto;">
|
|
50
|
+
|
|
51
|
+
1736 brain [<sup>18</sup>F]FDG PET studies of 1197 subjects with and without cognitive impairments were used to train
|
|
52
|
+
and test a deep-learning-based anatomical segmentation model via the [nnU-Net](https://github.com/MIC-DKFZ/nnUNet)
|
|
53
|
+
framework. Ground-truth segmentations were obtained on the respectively paired T1-weighted MRI studies using
|
|
54
|
+
[FastSurfer](https://github.com/Deep-MI/FastSurfer). All images belong to different neuroimaging initiatives
|
|
55
|
+
(please refer to the [Acknowledgements](#acknowledgements) section for more information).
|
|
56
|
+
|
|
57
|
+
## Installation & Usage
|
|
58
|
+
‼️ Using a [virtual environment](https://docs.python.org/3/library/venv.html) is recommended!
|
|
59
|
+
|
|
60
|
+
‼️ **PyTorch must be installed beforehand for [CUDA](https://developer.nvidia.com/cuda-toolkit) support!!**
|
|
61
|
+
[Refer to their website and install PyTorch](https://pytorch.org/get-started/locally/) with support for your hardware.
|
|
62
|
+
|
|
63
|
+
Only then:
|
|
64
|
+
|
|
65
|
+
```
|
|
66
|
+
git clone https://github.com/NM-Radiopharmacology/FDG-NeuroSegmenter.git
|
|
67
|
+
cd FDG-NeuroSegmenter
|
|
68
|
+
pip install .
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
‼️ If you prefer to employ FDG-NeuroSegmenter using [nnU-Net](https://github.com/MIC-DKFZ/nnUNet)'s framework directly,
|
|
72
|
+
you can download the models by clicking
|
|
73
|
+
[here](https://huggingface.co/NM-Rph/FDG-NeuroSegmenter/resolve/main/Dataset505_FDGNeuroSeg.zip).
|
|
74
|
+
|
|
75
|
+
### Anatomical Segmentation ⟶ `fdg-neurosegmenter`
|
|
76
|
+
|
|
77
|
+
To perform the anatomical segmentation of [<sup>18</sup>F]FDG PET images, simply run:
|
|
78
|
+
```
|
|
79
|
+
fdg-neurosegmenter -i /path/to/your/dataset_folder
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
Options:
|
|
83
|
+
|
|
84
|
+
- `-i`, `--input`: path to the directory containing your brain [<sup>18</sup>F]FDG PET images (NIfTI, NRRD, MetaImage)
|
|
85
|
+
- `--fast`: runs inference using only a single fold (fold 0) instead of ensembling all 5 folds. Highly recommended for
|
|
86
|
+
fast previews or restricted compute environments.
|
|
87
|
+
|
|
88
|
+
There is no need to pre-process or re-organise data. The output segmentations will be stored in a folder created next to
|
|
89
|
+
the dataset folder, with the suffix `_FDG-NeuroSegmenter`.
|
|
90
|
+
|
|
91
|
+
Label correspondence is stored in [`label_correspondence.csv`](src/fdg_neurosegmenter/data/label_correspondence.csv) and displayed below:
|
|
92
|
+
|
|
93
|
+
<table>
|
|
94
|
+
<thead>
|
|
95
|
+
<tr>
|
|
96
|
+
<th>Label (L, R)<sup>*</sup></th>
|
|
97
|
+
<th>Anatomical Structure</th>
|
|
98
|
+
</tr>
|
|
99
|
+
</thead>
|
|
100
|
+
<tbody>
|
|
101
|
+
<tr>
|
|
102
|
+
<td align="center">1, 2</td>
|
|
103
|
+
<td align="left">Superior Frontal Gyrus</td>
|
|
104
|
+
</tr>
|
|
105
|
+
<tr>
|
|
106
|
+
<td align="center">3, 4</td>
|
|
107
|
+
<td align="left">Orbitofrontal Cortex</td>
|
|
108
|
+
</tr>
|
|
109
|
+
<tr>
|
|
110
|
+
<td align="center">5, 6</td>
|
|
111
|
+
<td align="left">Dorsolateral Frontal Cortex</td>
|
|
112
|
+
</tr>
|
|
113
|
+
<tr>
|
|
114
|
+
<td align="center">7, 8</td>
|
|
115
|
+
<td align="left">Paracentral Lobule</td>
|
|
116
|
+
</tr>
|
|
117
|
+
<tr>
|
|
118
|
+
<td align="center">9, 10</td>
|
|
119
|
+
<td align="left">Postcentral Gyrus</td>
|
|
120
|
+
</tr>
|
|
121
|
+
<tr>
|
|
122
|
+
<td align="center">11, 12</td>
|
|
123
|
+
<td align="left">Dorsolateral Parietal Cortex</td>
|
|
124
|
+
</tr>
|
|
125
|
+
<tr>
|
|
126
|
+
<td align="center">13, 14</td>
|
|
127
|
+
<td align="left">Precuneus</td>
|
|
128
|
+
</tr>
|
|
129
|
+
<tr>
|
|
130
|
+
<td align="center">15, 16</td>
|
|
131
|
+
<td align="left">Anterior Cingulate Cortex</td>
|
|
132
|
+
</tr>
|
|
133
|
+
<tr>
|
|
134
|
+
<td align="center">17, 18</td>
|
|
135
|
+
<td align="left">Posterior Cingulate Cortex</td>
|
|
136
|
+
</tr>
|
|
137
|
+
<tr>
|
|
138
|
+
<td align="center">19, 20</td>
|
|
139
|
+
<td align="left">Isthmus Cingulate Cortex</td>
|
|
140
|
+
</tr>
|
|
141
|
+
<tr>
|
|
142
|
+
<td align="center">21, 22</td>
|
|
143
|
+
<td align="left">Lateral Temporal Cortex</td>
|
|
144
|
+
</tr>
|
|
145
|
+
<tr>
|
|
146
|
+
<td align="center">23, 24</td>
|
|
147
|
+
<td align="left">Mesial Temporal Cortex</td>
|
|
148
|
+
</tr>
|
|
149
|
+
<tr>
|
|
150
|
+
<td align="center">25, 26</td>
|
|
151
|
+
<td align="left">Lateral Occipital Cortex</td>
|
|
152
|
+
</tr>
|
|
153
|
+
<tr>
|
|
154
|
+
<td align="center">27, 28</td>
|
|
155
|
+
<td align="left">Pericalcarine Cortex</td>
|
|
156
|
+
</tr>
|
|
157
|
+
<tr>
|
|
158
|
+
<td align="center">29, 30</td>
|
|
159
|
+
<td align="left">Lingual Gyrus</td>
|
|
160
|
+
</tr>
|
|
161
|
+
<tr>
|
|
162
|
+
<td align="center">31, 32</td>
|
|
163
|
+
<td align="left">Cuneus</td>
|
|
164
|
+
</tr>
|
|
165
|
+
<tr>
|
|
166
|
+
<td align="center">33, 34</td>
|
|
167
|
+
<td align="left">Insula</td>
|
|
168
|
+
</tr>
|
|
169
|
+
<tr>
|
|
170
|
+
<td align="center">35, 36</td>
|
|
171
|
+
<td align="left">Cerebellar Cortex</td>
|
|
172
|
+
</tr>
|
|
173
|
+
<tr>
|
|
174
|
+
<td align="center">37, 38</td>
|
|
175
|
+
<td align="left">Thalamus</td>
|
|
176
|
+
</tr>
|
|
177
|
+
<tr>
|
|
178
|
+
<td align="center">39, 40</td>
|
|
179
|
+
<td align="left">Caudate</td>
|
|
180
|
+
</tr>
|
|
181
|
+
<tr>
|
|
182
|
+
<td align="center">41, 42</td>
|
|
183
|
+
<td align="left">Putamen</td>
|
|
184
|
+
</tr>
|
|
185
|
+
<tr>
|
|
186
|
+
<td align="center">43, 44</td>
|
|
187
|
+
<td align="left">Globus Pallidus</td>
|
|
188
|
+
</tr>
|
|
189
|
+
<tr>
|
|
190
|
+
<td align="center">45</td>
|
|
191
|
+
<td align="left">Brainstem w/o Pons</td>
|
|
192
|
+
</tr>
|
|
193
|
+
<tr>
|
|
194
|
+
<td align="center">46</td>
|
|
195
|
+
<td align="left">Pons</td>
|
|
196
|
+
</tr>
|
|
197
|
+
<tr>
|
|
198
|
+
<td align="center">47, 48</td>
|
|
199
|
+
<td align="left">Hippocampus</td>
|
|
200
|
+
</tr>
|
|
201
|
+
<tr>
|
|
202
|
+
<td align="center">49, 50</td>
|
|
203
|
+
<td align="left">Amygdala</td>
|
|
204
|
+
</tr>
|
|
205
|
+
<tr>
|
|
206
|
+
<td align="center">51, 52</td>
|
|
207
|
+
<td align="left">Ventral Diencephalon</td>
|
|
208
|
+
</tr>
|
|
209
|
+
</tbody>
|
|
210
|
+
</table>
|
|
211
|
+
<sup>*</sup> <small>For all paired anatomical structures (left and right hemispheres), odd labels refer to the left hemisphere
|
|
212
|
+
(L) and even labels to the right hemisphere (R). Single labels (45 and 46) represent non-lateralised or singular structures.</small>
|
|
213
|
+
|
|
214
|
+
### Quantification ⟶ `fdg-neuroquantifier`
|
|
215
|
+
|
|
216
|
+
To perform the semi-quantitative assessment of [<sup>18</sup>F]FDG PET images, run:
|
|
217
|
+
```
|
|
218
|
+
fdg-neuroquantifier -i /path/to/your/dataset_folder
|
|
219
|
+
```
|
|
220
|
+
|
|
221
|
+
Options:
|
|
222
|
+
|
|
223
|
+
- `-i`, `--input`: path to the directory containing your brain [<sup>18</sup>F]FDG PET images (NIfTI, NRRD, MetaImage)
|
|
224
|
+
- `--fast`: runs inference (if needed) using only a single fold (fold 0) instead of ensembling all 5 folds. Highly
|
|
225
|
+
recommended for fast previews or restricted compute environments.
|
|
226
|
+
|
|
227
|
+
There is no need to pre-process or re-organise data. If the segmentation folder is not found, segmentation will be
|
|
228
|
+
performed and the outputs stored in a folder created next to the dataset folder, with the suffix `_FDG-NeuroSegmenter`.
|
|
229
|
+
Pons-based SUVR normalisation<sup>1</sup> will be applied to each image for quantification purposes. The output
|
|
230
|
+
quantification files will be stored in a folder created next to the dataset folder, with the suffix
|
|
231
|
+
`_FDG-NeuroSegmenter_quantification`.
|
|
232
|
+
|
|
233
|
+
Each quantification file stores:
|
|
234
|
+
- `SUVRmean`: the SUVR<sub>mean</sub> in the respective anatomical region for the given [<sup>18</sup>F]FDG PET image.
|
|
235
|
+
- `zscore`: the z-score of `SUVRmean` relative to the cognitively normal cohort<sup>2</sup>.
|
|
236
|
+
- `percentile`: the percentile in which `SUVRmean` is placed relative to the SUVR<sub>mean</sub> distribution of that anatomical region in
|
|
237
|
+
the cognitively normal cohort<sup>2</sup>.
|
|
238
|
+
|
|
239
|
+
<sup>1</sup> <small>By default, an erosion filter (spherical kernel of 3 mm radius) is applied to the segmentation of
|
|
240
|
+
the pons, to minimise the contribution of background/vicinity signal to the normalisation constant.</small>
|
|
241
|
+
|
|
242
|
+
<sup>2</sup> <small>537 [<sup>18</sup>F]FDG PET studies of 355 cognitively normal subjects.</small>
|
|
243
|
+
|
|
244
|
+
## Acknowledgements
|
|
245
|
+
|
|
246
|
+
#### Dataset
|
|
247
|
+
- [Alzheimer's Disease Neuroimaging Initiative (ADNI)](https://adni.loni.usc.edu/)
|
|
248
|
+
- [Frontotemporal Lobar Degeneration Neuroimaging Initiative (FTLDNI/NIFD)](http://memory.ucsf.edu/research/studies/nifd)
|
|
249
|
+
- [National Alzheimer's Coordinating Center (NACC): Standardized Centralized Alzheimer’s & Related Dementias
|
|
250
|
+
Neuroimaging (SCAN)](https://scan.naccdata.org/)
|
|
251
|
+
- [Open Access Series of Imaging Studies 3 (OASIS-3)](https://sites.wustl.edu/oasisbrains/)
|
|
252
|
+
|
|
253
|
+
For more information click [here](ACKNOWLEDGEMENTS.md).
|
|
254
|
+
|
|
255
|
+
#### Methods
|
|
256
|
+
- [nnU-Net](https://github.com/MIC-DKFZ/nnUNet) ([Isensee & Jaeger et al. (2021)](https://www.nature.com/articles/s41592-020-01008-z)) -
|
|
257
|
+
used for training and inference of the segmentation models
|
|
258
|
+
- [FastSurfer](https://github.com/Deep-MI/FastSurfer) ([Henschel et al. (2020)](https://doi.org/10.1016/j.neuroimage.2020.117012);
|
|
259
|
+
[Henschel et al. (2022)](https://doi.org/10.1016/j.neuroimage.2022.118933);
|
|
260
|
+
[Faber et al. (2022)](https://doi.org/10.1016/j.neuroimage.2022.119703);
|
|
261
|
+
[Estrada et al. (2023)](https://doi.org/10.1162/imag_a_00034)) - used to obtain the ground-truth MRI-based segmentation
|
|
@@ -0,0 +1,219 @@
|
|
|
1
|
+
# FDG-NeuroSegmenter
|
|
2
|
+
<b>FDG-NeuroSegmenter</b> is a deep-learning-based model developed to perform the automatic segmentation of 52
|
|
3
|
+
anatomical regions in brain [<sup>18</sup>F]FDG PET images.
|
|
4
|
+
|
|
5
|
+
Please cite [REF!]
|
|
6
|
+
|
|
7
|
+
<img src="/figures/fdg_brain_segmentation.png" alt="[18F]FDG PET brain anatomical segmentation" style="max-width: 95%; height: auto;">
|
|
8
|
+
|
|
9
|
+
1736 brain [<sup>18</sup>F]FDG PET studies of 1197 subjects with and without cognitive impairments were used to train
|
|
10
|
+
and test a deep-learning-based anatomical segmentation model via the [nnU-Net](https://github.com/MIC-DKFZ/nnUNet)
|
|
11
|
+
framework. Ground-truth segmentations were obtained on the respectively paired T1-weighted MRI studies using
|
|
12
|
+
[FastSurfer](https://github.com/Deep-MI/FastSurfer). All images belong to different neuroimaging initiatives
|
|
13
|
+
(please refer to the [Acknowledgements](#acknowledgements) section for more information).
|
|
14
|
+
|
|
15
|
+
## Installation & Usage
|
|
16
|
+
‼️ Using a [virtual environment](https://docs.python.org/3/library/venv.html) is recommended!
|
|
17
|
+
|
|
18
|
+
‼️ **PyTorch must be installed beforehand for [CUDA](https://developer.nvidia.com/cuda-toolkit) support!!**
|
|
19
|
+
[Refer to their website and install PyTorch](https://pytorch.org/get-started/locally/) with support for your hardware.
|
|
20
|
+
|
|
21
|
+
Only then:
|
|
22
|
+
|
|
23
|
+
```
|
|
24
|
+
git clone https://github.com/NM-Radiopharmacology/FDG-NeuroSegmenter.git
|
|
25
|
+
cd FDG-NeuroSegmenter
|
|
26
|
+
pip install .
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
‼️ If you prefer to employ FDG-NeuroSegmenter using [nnU-Net](https://github.com/MIC-DKFZ/nnUNet)'s framework directly,
|
|
30
|
+
you can download the models by clicking
|
|
31
|
+
[here](https://huggingface.co/NM-Rph/FDG-NeuroSegmenter/resolve/main/Dataset505_FDGNeuroSeg.zip).
|
|
32
|
+
|
|
33
|
+
### Anatomical Segmentation ⟶ `fdg-neurosegmenter`
|
|
34
|
+
|
|
35
|
+
To perform the anatomical segmentation of [<sup>18</sup>F]FDG PET images, simply run:
|
|
36
|
+
```
|
|
37
|
+
fdg-neurosegmenter -i /path/to/your/dataset_folder
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
Options:
|
|
41
|
+
|
|
42
|
+
- `-i`, `--input`: path to the directory containing your brain [<sup>18</sup>F]FDG PET images (NIfTI, NRRD, MetaImage)
|
|
43
|
+
- `--fast`: runs inference using only a single fold (fold 0) instead of ensembling all 5 folds. Highly recommended for
|
|
44
|
+
fast previews or restricted compute environments.
|
|
45
|
+
|
|
46
|
+
There is no need to pre-process or re-organise data. The output segmentations will be stored in a folder created next to
|
|
47
|
+
the dataset folder, with the suffix `_FDG-NeuroSegmenter`.
|
|
48
|
+
|
|
49
|
+
Label correspondence is stored in [`label_correspondence.csv`](src/fdg_neurosegmenter/data/label_correspondence.csv) and displayed below:
|
|
50
|
+
|
|
51
|
+
<table>
|
|
52
|
+
<thead>
|
|
53
|
+
<tr>
|
|
54
|
+
<th>Label (L, R)<sup>*</sup></th>
|
|
55
|
+
<th>Anatomical Structure</th>
|
|
56
|
+
</tr>
|
|
57
|
+
</thead>
|
|
58
|
+
<tbody>
|
|
59
|
+
<tr>
|
|
60
|
+
<td align="center">1, 2</td>
|
|
61
|
+
<td align="left">Superior Frontal Gyrus</td>
|
|
62
|
+
</tr>
|
|
63
|
+
<tr>
|
|
64
|
+
<td align="center">3, 4</td>
|
|
65
|
+
<td align="left">Orbitofrontal Cortex</td>
|
|
66
|
+
</tr>
|
|
67
|
+
<tr>
|
|
68
|
+
<td align="center">5, 6</td>
|
|
69
|
+
<td align="left">Dorsolateral Frontal Cortex</td>
|
|
70
|
+
</tr>
|
|
71
|
+
<tr>
|
|
72
|
+
<td align="center">7, 8</td>
|
|
73
|
+
<td align="left">Paracentral Lobule</td>
|
|
74
|
+
</tr>
|
|
75
|
+
<tr>
|
|
76
|
+
<td align="center">9, 10</td>
|
|
77
|
+
<td align="left">Postcentral Gyrus</td>
|
|
78
|
+
</tr>
|
|
79
|
+
<tr>
|
|
80
|
+
<td align="center">11, 12</td>
|
|
81
|
+
<td align="left">Dorsolateral Parietal Cortex</td>
|
|
82
|
+
</tr>
|
|
83
|
+
<tr>
|
|
84
|
+
<td align="center">13, 14</td>
|
|
85
|
+
<td align="left">Precuneus</td>
|
|
86
|
+
</tr>
|
|
87
|
+
<tr>
|
|
88
|
+
<td align="center">15, 16</td>
|
|
89
|
+
<td align="left">Anterior Cingulate Cortex</td>
|
|
90
|
+
</tr>
|
|
91
|
+
<tr>
|
|
92
|
+
<td align="center">17, 18</td>
|
|
93
|
+
<td align="left">Posterior Cingulate Cortex</td>
|
|
94
|
+
</tr>
|
|
95
|
+
<tr>
|
|
96
|
+
<td align="center">19, 20</td>
|
|
97
|
+
<td align="left">Isthmus Cingulate Cortex</td>
|
|
98
|
+
</tr>
|
|
99
|
+
<tr>
|
|
100
|
+
<td align="center">21, 22</td>
|
|
101
|
+
<td align="left">Lateral Temporal Cortex</td>
|
|
102
|
+
</tr>
|
|
103
|
+
<tr>
|
|
104
|
+
<td align="center">23, 24</td>
|
|
105
|
+
<td align="left">Mesial Temporal Cortex</td>
|
|
106
|
+
</tr>
|
|
107
|
+
<tr>
|
|
108
|
+
<td align="center">25, 26</td>
|
|
109
|
+
<td align="left">Lateral Occipital Cortex</td>
|
|
110
|
+
</tr>
|
|
111
|
+
<tr>
|
|
112
|
+
<td align="center">27, 28</td>
|
|
113
|
+
<td align="left">Pericalcarine Cortex</td>
|
|
114
|
+
</tr>
|
|
115
|
+
<tr>
|
|
116
|
+
<td align="center">29, 30</td>
|
|
117
|
+
<td align="left">Lingual Gyrus</td>
|
|
118
|
+
</tr>
|
|
119
|
+
<tr>
|
|
120
|
+
<td align="center">31, 32</td>
|
|
121
|
+
<td align="left">Cuneus</td>
|
|
122
|
+
</tr>
|
|
123
|
+
<tr>
|
|
124
|
+
<td align="center">33, 34</td>
|
|
125
|
+
<td align="left">Insula</td>
|
|
126
|
+
</tr>
|
|
127
|
+
<tr>
|
|
128
|
+
<td align="center">35, 36</td>
|
|
129
|
+
<td align="left">Cerebellar Cortex</td>
|
|
130
|
+
</tr>
|
|
131
|
+
<tr>
|
|
132
|
+
<td align="center">37, 38</td>
|
|
133
|
+
<td align="left">Thalamus</td>
|
|
134
|
+
</tr>
|
|
135
|
+
<tr>
|
|
136
|
+
<td align="center">39, 40</td>
|
|
137
|
+
<td align="left">Caudate</td>
|
|
138
|
+
</tr>
|
|
139
|
+
<tr>
|
|
140
|
+
<td align="center">41, 42</td>
|
|
141
|
+
<td align="left">Putamen</td>
|
|
142
|
+
</tr>
|
|
143
|
+
<tr>
|
|
144
|
+
<td align="center">43, 44</td>
|
|
145
|
+
<td align="left">Globus Pallidus</td>
|
|
146
|
+
</tr>
|
|
147
|
+
<tr>
|
|
148
|
+
<td align="center">45</td>
|
|
149
|
+
<td align="left">Brainstem w/o Pons</td>
|
|
150
|
+
</tr>
|
|
151
|
+
<tr>
|
|
152
|
+
<td align="center">46</td>
|
|
153
|
+
<td align="left">Pons</td>
|
|
154
|
+
</tr>
|
|
155
|
+
<tr>
|
|
156
|
+
<td align="center">47, 48</td>
|
|
157
|
+
<td align="left">Hippocampus</td>
|
|
158
|
+
</tr>
|
|
159
|
+
<tr>
|
|
160
|
+
<td align="center">49, 50</td>
|
|
161
|
+
<td align="left">Amygdala</td>
|
|
162
|
+
</tr>
|
|
163
|
+
<tr>
|
|
164
|
+
<td align="center">51, 52</td>
|
|
165
|
+
<td align="left">Ventral Diencephalon</td>
|
|
166
|
+
</tr>
|
|
167
|
+
</tbody>
|
|
168
|
+
</table>
|
|
169
|
+
<sup>*</sup> <small>For all paired anatomical structures (left and right hemispheres), odd labels refer to the left hemisphere
|
|
170
|
+
(L) and even labels to the right hemisphere (R). Single labels (45 and 46) represent non-lateralised or singular structures.</small>
|
|
171
|
+
|
|
172
|
+
### Quantification ⟶ `fdg-neuroquantifier`
|
|
173
|
+
|
|
174
|
+
To perform the semi-quantitative assessment of [<sup>18</sup>F]FDG PET images, run:
|
|
175
|
+
```
|
|
176
|
+
fdg-neuroquantifier -i /path/to/your/dataset_folder
|
|
177
|
+
```
|
|
178
|
+
|
|
179
|
+
Options:
|
|
180
|
+
|
|
181
|
+
- `-i`, `--input`: path to the directory containing your brain [<sup>18</sup>F]FDG PET images (NIfTI, NRRD, MetaImage)
|
|
182
|
+
- `--fast`: runs inference (if needed) using only a single fold (fold 0) instead of ensembling all 5 folds. Highly
|
|
183
|
+
recommended for fast previews or restricted compute environments.
|
|
184
|
+
|
|
185
|
+
There is no need to pre-process or re-organise data. If the segmentation folder is not found, segmentation will be
|
|
186
|
+
performed and the outputs stored in a folder created next to the dataset folder, with the suffix `_FDG-NeuroSegmenter`.
|
|
187
|
+
Pons-based SUVR normalisation<sup>1</sup> will be applied to each image for quantification purposes. The output
|
|
188
|
+
quantification files will be stored in a folder created next to the dataset folder, with the suffix
|
|
189
|
+
`_FDG-NeuroSegmenter_quantification`.
|
|
190
|
+
|
|
191
|
+
Each quantification file stores:
|
|
192
|
+
- `SUVRmean`: the SUVR<sub>mean</sub> in the respective anatomical region for the given [<sup>18</sup>F]FDG PET image.
|
|
193
|
+
- `zscore`: the z-score of `SUVRmean` relative to the cognitively normal cohort<sup>2</sup>.
|
|
194
|
+
- `percentile`: the percentile in which `SUVRmean` is placed relative to the SUVR<sub>mean</sub> distribution of that anatomical region in
|
|
195
|
+
the cognitively normal cohort<sup>2</sup>.
|
|
196
|
+
|
|
197
|
+
<sup>1</sup> <small>By default, an erosion filter (spherical kernel of 3 mm radius) is applied to the segmentation of
|
|
198
|
+
the pons, to minimise the contribution of background/vicinity signal to the normalisation constant.</small>
|
|
199
|
+
|
|
200
|
+
<sup>2</sup> <small>537 [<sup>18</sup>F]FDG PET studies of 355 cognitively normal subjects.</small>
|
|
201
|
+
|
|
202
|
+
## Acknowledgements
|
|
203
|
+
|
|
204
|
+
#### Dataset
|
|
205
|
+
- [Alzheimer's Disease Neuroimaging Initiative (ADNI)](https://adni.loni.usc.edu/)
|
|
206
|
+
- [Frontotemporal Lobar Degeneration Neuroimaging Initiative (FTLDNI/NIFD)](http://memory.ucsf.edu/research/studies/nifd)
|
|
207
|
+
- [National Alzheimer's Coordinating Center (NACC): Standardized Centralized Alzheimer’s & Related Dementias
|
|
208
|
+
Neuroimaging (SCAN)](https://scan.naccdata.org/)
|
|
209
|
+
- [Open Access Series of Imaging Studies 3 (OASIS-3)](https://sites.wustl.edu/oasisbrains/)
|
|
210
|
+
|
|
211
|
+
For more information click [here](ACKNOWLEDGEMENTS.md).
|
|
212
|
+
|
|
213
|
+
#### Methods
|
|
214
|
+
- [nnU-Net](https://github.com/MIC-DKFZ/nnUNet) ([Isensee & Jaeger et al. (2021)](https://www.nature.com/articles/s41592-020-01008-z)) -
|
|
215
|
+
used for training and inference of the segmentation models
|
|
216
|
+
- [FastSurfer](https://github.com/Deep-MI/FastSurfer) ([Henschel et al. (2020)](https://doi.org/10.1016/j.neuroimage.2020.117012);
|
|
217
|
+
[Henschel et al. (2022)](https://doi.org/10.1016/j.neuroimage.2022.118933);
|
|
218
|
+
[Faber et al. (2022)](https://doi.org/10.1016/j.neuroimage.2022.119703);
|
|
219
|
+
[Estrada et al. (2023)](https://doi.org/10.1162/imag_a_00034)) - used to obtain the ground-truth MRI-based segmentation
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
[build-system]
|
|
2
|
+
requires = ["setuptools>=61.0.0", "wheel"]
|
|
3
|
+
build-backend = "setuptools.build_meta"
|
|
4
|
+
|
|
5
|
+
[project]
|
|
6
|
+
name = "fdg-neurosegmenter"
|
|
7
|
+
version = "1.0.0"
|
|
8
|
+
description = "AI-based anatomical segmentation and regional quantification of brain [18F]FDG PET acquisitions"
|
|
9
|
+
readme = "README.md"
|
|
10
|
+
authors = [{ name = "Luísa C. Silva" }]
|
|
11
|
+
license = { file = "LICENSE" }
|
|
12
|
+
classifiers = [
|
|
13
|
+
"Programming Language :: Python :: 3",
|
|
14
|
+
"Topic :: Scientific/Engineering :: Medical Science Apps."
|
|
15
|
+
]
|
|
16
|
+
dependencies = [
|
|
17
|
+
"torch>=2.0.0",
|
|
18
|
+
"nnunetv2>=2.0",
|
|
19
|
+
"itk>=5.4.0,<6.0",
|
|
20
|
+
"pandas>=2.2.0,<3.0",
|
|
21
|
+
"numpy>=1.26.0,<2.0",
|
|
22
|
+
"SimpleITK>=2.0.0,<3.0",
|
|
23
|
+
"scipy>=1.10.0",
|
|
24
|
+
"tqdm>=4.60.0",
|
|
25
|
+
"scikit-image>=0.20.0"
|
|
26
|
+
]
|
|
27
|
+
|
|
28
|
+
[project.scripts]
|
|
29
|
+
fdg-neurosegmenter = "fdg_neurosegmenter.segmenter:main"
|
|
30
|
+
fdg-neuroquantifier = "fdg_neurosegmenter.quantifier:main"
|
|
31
|
+
|
|
32
|
+
[tool.setuptools.packages.find]
|
|
33
|
+
where = ["src"]
|
|
34
|
+
|
|
35
|
+
[tool.setuptools.package-data]
|
|
36
|
+
fdg_neurosegmenter = ["data/*.csv"]
|
|
File without changes
|