|
3 | 3 | For examples and tutorials on using the IBL atlas package, see |
4 | 4 | https://docs.internationalbrainlab.org/atlas_examples.html |
5 | 5 |
|
6 | | -TODO Explain differences between this package and the Allen SDK. |
7 | | -Much of this was adapted from the [cortexlab allenCCF repository](https://github.com/cortex-lab/allenCCF). |
| 6 | +.. TODO Explain differences between this package and the Allen SDK. |
| 7 | +Much of this was adapted from the `cortexlab allenCCF repository <https://github.com/cortex-lab/allenCCF>`_. |
8 | 8 |
|
9 | 9 | Terminology |
10 | 10 | ----------- |
|
37 | 37 | There are two principal mouse brain atlases in this module: |
38 | 38 |
|
39 | 39 | 1. The Allen Common Coordinate Framework (CCF) [1]_. |
40 | | -2. The Mouse Brain in Stereotaxic Coordinates (MBSC) 4th Edition, by Paxinos G, and Franklin KBJ [2]_ and matched to |
41 | | - to the Allen Common Coordiante Framework by Chon et al. [10] |
| 40 | +2. The Mouse Brain in Stereotaxic Coordinates (MBSC) 4th Edition, by Paxinos G, and Franklin KBJ [2]_, matched to |
| 41 | + to the Allen Common Coordiante Framework by Chon et al. [3]_. |
42 | 42 |
|
43 | 43 | The latter is referred to here as the 'Franklin-Paxinos atlas'. These atlases comprise a 3D array of voxels and their associated |
44 | 44 | brain region identifiers (labels) at a given resolution. The Allen Atlas can be instantiated in 10um, 25um or 50um resolution. |
45 | | -The Franklin-Paxinos atlas has a resolution of 10um in the ML and DV axis, and 100um in the AP axis. TODO Mention flat maps. |
| 45 | +The Franklin-Paxinos atlas has a resolution of 10um in the ML and DV axis, and 100um in the AP axis. **TODO Mention flat maps.** |
46 | 46 |
|
47 | 47 |
|
48 | 48 | Scalings |
|
51 | 51 | to account for distortion that occurs during the imaging and tissue fixation process: |
52 | 52 |
|
53 | 53 | 1. The Needles atlas - 40 C57BL/6J (p84) mice underwnt MRI imaging post-mortem while the brain was still in the skull, followed by |
54 | | - conventional Nissl histology [3]_. These mouse brain atlas images combined with segmentation (known as DSURQE) were manually |
| 54 | + conventional Nissl histology [4]_. These mouse brain atlas images combined with segmentation (known as DSURQE) were manually |
55 | 55 | transformed onto the Allen CCF atlas to determine the scaling. |
56 | 56 | 2. The MRI Toronto - 12 p65 mice MRI images were taken *in vivo* then averaged and transformed on the Allen CCF atlas to determine |
57 | | - the scaling [4]_. |
| 57 | + the scaling [5]_. |
58 | 58 |
|
59 | 59 | All scaling is currently linear. Scaling of this kind can be applied arbitrarily to better represent a specific mouse age and |
60 | | -sex [4]_. NB: In addition to distortions, the Allen CFF atlas is pitched down by about 5 degrees relative to a flat skull (where |
61 | | -bregma and lambda are at the same DV height) [5]_, however this is not currently accounted for. |
| 60 | +sex [5]_. NB: In addition to distortions, the Allen CFF atlas is pitched down by about 5 degrees relative to a flat skull (where |
| 61 | +bregma and lambda are at the same DV height) [6]_, however this is not currently accounted for. |
62 | 62 |
|
63 | 63 |
|
64 | 64 | Mappings |
|
69 | 69 |
|
70 | 70 | 1. Beryl - brain atlas annotations without layer sub-divisions or certain ganglial/nucleus sub-devisisions (e.g. the core/shell |
71 | 71 | sub-division of the lateral geniculate nucleus). Fibre tracts, pia, etc. are also absent. The choice of which areas to combine |
72 | | - was guided partially by the computed volume of each area. This mapping is used in the brainwide map and prior papers [6]_ [7]_ |
| 72 | + was guided partially by the computed volume of each area. This mapping is used in the brainwide map and prior papers [7]_, [8]_ |
73 | 73 | . |
74 | 74 | 2. Cosmos - coarse brain atlas annotations, dividing the atlas into 10 broad areas: isocortex, olfactory areas, cortical subplate, |
75 | 75 | cerebral nuclei, thalamus, hypothalamus, midbrain, hindbrain, cerebellum and hippocampal formation. |
|
78 | 78 |
|
79 | 79 | Non-Allen mappings: |
80 | 80 |
|
81 | | -3. Swanson - the brain atlas annotations from the Swansan rat brain flat map [8]_, mapped to the Allen atlas manually by Olivier |
| 81 | +3. Swanson - the brain atlas annotations from the Swansan rat brain flat map [9]_, mapped to the Allen atlas manually by Olivier |
82 | 82 | Winter. See `Fixtures`_ for details. |
83 | 83 |
|
84 | 84 | Each mapping includes both a lateralized (suffix '-lr') and non-laterized version. The lateralized mappings assign a different ID |
|
89 | 89 |
|
90 | 90 | Notes |
91 | 91 | ----- |
92 | | -The Allen atlas and the CCF annotations have different release dates and versions [8]_. The annotations used by IBL are the 2017 |
| 92 | +The Allen atlas and the CCF annotations have different release dates and versions [10]_. The annotations used by IBL are the 2017 |
93 | 93 | version. |
94 | 94 |
|
95 | 95 | The IBL uses the following conventions: |
96 | 96 |
|
97 | | -- All atlas images have dimensions (AP, ML, DV). With C-ordering this makes coronal slicing most efficient. |
| 97 | +- All atlas images have dimensions (AP, ML, DV). With C-ordering this makes coronal slicing most efficient. The origin is the top |
| 98 | + left corner of the image. |
98 | 99 | - Coordinates are provided in the order (ML AP DV) and are in meters relative to bregma. |
99 | 100 | - Left hemisphere ML coordinates are -ve; right, +ve. |
100 | 101 | - AP coordinates anterior to bregma are +ve; posterior, -ve. |
|
104 | 105 | - All left hemisphere regions have negative region IDs in all lateralized mappings. |
105 | 106 |
|
106 | 107 |
|
107 | | -References |
108 | | ----------- |
109 | | -.. [1] © 2015 Allen Institute for Brain Science. Allen Mouse Brain Atlas (2015) with region annotations (2017). |
110 | | - Available from: http://download.alleninstitute.org/informatics-archive/current-release/mouse_ccf/annotation/ |
111 | | -.. [2] Paxinos G, and Franklin KBJ (2012) The Mouse Brain in Stereotaxic Coordinates, 4th edition (Elsevier Academic Press) |
112 | | -.. [3] Dorr AE, Lerch JP, Spring S, Kabani N, Henkelman RM (2008). High resolution three-dimensional brain atlas using an average |
113 | | - magnetic resonance image of 40 adult C57Bl/6J mice. Neuroimage 42(1):60-9. [doi 10.1016/j.neuroimage.2008.03.037] |
114 | | -.. [4] Qiu, LR, Fernandes, DJ, Szulc-Lerch, KU et al. (2018) Mouse MRI shows brain areas relatively larger |
115 | | - in males emerge before those larger in females. Nat Commun 9, 2615. [doi 10.1038/s41467-018-04921-2] |
116 | | -.. [5] International Brain Laboratory et al. (2022) Reproducibility of in-vivo electrophysiological measurements in mice. |
117 | | - bioRxiv. [doi 10.1101/2022.05.09.491042] |
118 | | -.. [6] International Brain Laboratory et al. (2023) A Brain-Wide Map of Neural Activity during Complex Behaviour. |
119 | | - bioRxiv. [doi 10.1101/2023.07.04.547681] |
120 | | -.. [7] Findling C et al. (2023) Brain-wide representations of prior information in mouse decision-making. |
121 | | - bioRxiv. [doi 10.1101/2023.07.04.547684] |
122 | | -.. [8] Swanson LW (2018) Brain maps 4.0—Structure of the rat brain: An open access atlas with global nervous system nomenclature |
123 | | - ontology and flatmaps. J Comp Neurol. [doi 10.1002/cne.24381] |
124 | | -.. [9] Allen Mouse Common Coordinate Framework Technical White Paper (October 2017 v3) |
125 | | - http://help.brain-map.org/download/attachments/8323525/Mouse_Common_Coordinate_Framework.pdf |
126 | | -.. [10] Chon et al (2019) Enhanced and unified anatomical labeling for a common mouse brain atlas |
127 | | - [doi 10.1038/s41467-019-13057-w] |
128 | | -
|
129 | | -
|
130 | 108 | Examples |
131 | 109 | -------- |
132 | 110 | Below are some breif API examples. For in depth tutorials on using the IBL atlas package, see |
|
145 | 123 | Fixtures |
146 | 124 | -------- |
147 | 125 |
|
148 | | -* TODO List the data files in this package, their purpose, data types, shape, etc. |
149 | | -* TODO List the remote files used by this package, e.g. annotations files, swansonpaths.json, etc. |
| 126 | +.. TODO List the data files in this package, their purpose, data types, shape, etc. |
| 127 | +.. TODO List the remote files used by this package, e.g. annotations files, swansonpaths.json, etc. |
150 | 128 |
|
151 | | -### Local files |
| 129 | +Local files |
| 130 | +^^^^^^^^^^^ |
152 | 131 |
|
153 | 132 | * **allen_structure_tree.csv** - TODO Document. Where does this come from? Is it modified from either structure_tree_safe.csv or |
154 | 133 | structure_tree_safe_2017.csv? |
|
162 | 141 | The rows contain the correspondence of each mapping to the int64 index of the lateralized Allen structure tree. The table is |
163 | 142 | generated by ibllib.atlas.regions.BrainRegions._compute_mappings. |
164 | 143 |
|
165 | | -### Remote files |
| 144 | +Remote files |
| 145 | +^^^^^^^^^^^^ |
166 | 146 |
|
167 | 147 | * **annotation_<res_um>.nrrd** - A 3D volume containing indicies of the regions in the associated |
168 | 148 | structure tree. `res_um` indicates the isometric spacing in microns. These uint16 indicies are |
169 | 149 | known as the region 'index' in the structure tree, i.e. the position of the region in the |
170 | 150 | flattened tree. |
171 | 151 | * **average_template_<res_um>.nrrd** - TODO Document |
172 | 152 | * **annotation_<res_um>_lut_<LUT_VERSION>.npz** - TODO Document |
173 | | -* FranklinPaxinons/annotation_<res_um>.npz - A 3D volume containing indices of the regions associated with |
174 | | - the Franklin Paxinos structure tree. The volume was created from the images provided in Supplemtary Data 4 of |
175 | | - reference [10] and stitched together as a single volume using SimpleITK. |
176 | | -* FranklinPaxinons/average_template_<res_um>.npz - A 3D volume containing the Allen dwi image slices corresponding to |
177 | | - the slices in the annotation volume. The volume was created from the images provided in Supplemtary Data 5 of |
178 | | - reference [10] and stitched together as a single volume using SimpleITK. |
| 153 | +* **FranklinPaxinons/annotation_<res_um>.npz** - A 3D volume containing indices of the regions associated with the Franklin- |
| 154 | + Paxinos structure tree. |
| 155 | +* **FranklinPaxinons/average_template_<res_um>.npz** - A 3D volume containing the Allen dwi image slices corresponding to |
| 156 | + the slices in the annotation volume [*] . |
179 | 157 | * **swansonpaths.json** - The paths of a vectorized Swanson flatmap image [*]. The vectorized version was generated |
180 | 158 | from the Swanson bitmap image using the matlab contour function to find the paths for each region. The paths for each |
181 | | - region were then simplified using the Ramer Douglas Peucker algorithm https://rdp.readthedocs.io/en/latest/ |
| 159 | + region were then simplified using the `Ramer Douglas Peucker algorithm <https://rdp.readthedocs.io/en/latest/>`_ |
182 | 160 | * **swanson2allen.npz** - TODO Document who made this, its contents, purpose and data type |
183 | 161 | * **<flatmap_name>_<res_um>.nrrd** - TODO Document who made this, its contents, purpose and data type |
184 | 162 | * **gene-expression.pqt** - TODO Document who made this, its contents, purpose and data type |
185 | 163 | * **gene-expression.bin** - TODO Document who made this, its contents, purpose and data type. |
186 | 164 |
|
| 165 | +.. [*] The annotation and average template volumes were created from the images provided in Supplemtary Data 4 of Chon et al. [3]_ |
| 166 | + and stitched together as a single volume using SimpleITK. |
187 | 167 | .. [*] output of aggType 2 in https://github.com/cortex-lab/allenCCF/blob/master/Browsing%20Functions/aggregateAcr.m |
188 | 168 | .. [*] output of aggType 1 in https://github.com/cortex-lab/allenCCF/blob/master/Browsing%20Functions/aggregateAcr.m |
189 | 169 | .. [*] the paths were generated from a bitmap of the |
190 | | - [BM3 rat flatmap 3.0 foldout poster](https://larrywswanson.com/wp-content/uploads/2015/03/BM3-flatmap-foldout.pdf) in |
191 | | - [Swanson LW (2004) Brain Maps, 3rd ed.](https://larrywswanson.com/?page_id=164) TODO where is code for this? |
| 170 | + `BM3 rat flatmap 3.0 foldout poster <https://larrywswanson.com/wp-content/uploads/2015/03/BM3-flatmap-foldout.pdf>`_ |
| 171 | + in `Swanson LW (2004) Brain Maps, 3rd ed. <https://larrywswanson.com/?page_id=164>`_ TODO where is code for this? |
| 172 | +
|
| 173 | +
|
| 174 | +References |
| 175 | +---------- |
| 176 | +.. [1] © 2015 Allen Institute for Brain Science. Allen Mouse Brain Atlas (2015) with region annotations (2017). |
| 177 | + Available from: http://download.alleninstitute.org/informatics-archive/current-release/mouse_ccf/annotation/ |
| 178 | +.. [2] Paxinos G, and Franklin KBJ (2012) The Mouse Brain in Stereotaxic Coordinates, 4th edition (Elsevier Academic Press) |
| 179 | +.. [3] Chon U et al (2019) Enhanced and unified anatomical labeling for a common mouse brain atlas |
| 180 | + [doi 10.1038/s41467-019-13057-w] |
| 181 | +.. [4] Dorr AE, Lerch JP, Spring S, Kabani N, Henkelman RM (2008). High resolution three-dimensional brain atlas using an average |
| 182 | + magnetic resonance image of 40 adult C57Bl/6J mice. Neuroimage 42(1):60-9. [doi 10.1016/j.neuroimage.2008.03.037] |
| 183 | +.. [5] Qiu, LR, Fernandes, DJ, Szulc-Lerch, KU et al. (2018) Mouse MRI shows brain areas relatively larger |
| 184 | + in males emerge before those larger in females. Nat Commun 9, 2615. [doi 10.1038/s41467-018-04921-2] |
| 185 | +.. [6] International Brain Laboratory et al. (2022) Reproducibility of in-vivo electrophysiological measurements in mice. |
| 186 | + bioRxiv. [doi 10.1101/2022.05.09.491042] |
| 187 | +.. [7] International Brain Laboratory et al. (2023) A Brain-Wide Map of Neural Activity during Complex Behaviour. |
| 188 | + bioRxiv. [doi 10.1101/2023.07.04.547681] |
| 189 | +.. [8] Findling C et al. (2023) Brain-wide representations of prior information in mouse decision-making. |
| 190 | + bioRxiv. [doi 10.1101/2023.07.04.547684] |
| 191 | +.. [9] Swanson LW (2018) Brain maps 4.0—Structure of the rat brain: An open access atlas with global nervous system nomenclature |
| 192 | + ontology and flatmaps. J Comp Neurol. [doi 10.1002/cne.24381] |
| 193 | +.. [10] Allen Mouse Common Coordinate Framework Technical White Paper (October 2017 v3) |
| 194 | + http://help.brain-map.org/download/attachments/8323525/Mouse_Common_Coordinate_Framework.pdf |
| 195 | +
|
192 | 196 | """ |
193 | 197 | from .atlas import * # noqa |
194 | 198 | from .regions import regions_from_allen_csv |
|
0 commit comments