Functional networks#
Two group resting-state network colourings of the cortex. Yeo’s seven networks are carried per vertex from the Schaefer 2018 400-parcel annotation, so they cross the borders of every cortical atlas. The twelve networks of the Cole-Anticevic Brain-wide Network Partition (CAB-NP) are carried per area of HCP-MMP1.0 (Human Connectome Project multi-modal parcellation), so their borders are HCP-MMP’s. Both reach this brain through surface registration; neither is its measured function.
Fig. 18 | Yeo 7 is a per-vertex field that ignores area borders; CAB-NP colours whole HCP-MMP areas. a, Yeo 7, lateral left hemisphere. b, CAB-NP, same view. c, Yeo 7, medial left hemisphere. d, CAB-NP, same view. Atlas HCP-MMP1.0 in all panels; Colour Yeo 7 networks (a, c) or CAB-NP networks (b, d); hemisphere left; internal anatomy hidden. Colours are the published network colours (Yeo et al. 2011; CAB-NP label key v1.1.6). In c and d the medial wall carries no network and keeps its region colour.#
Data#
Input |
Source |
Form in the repository |
Licence |
|---|---|---|---|
Yeo 7 |
|
|
MIT |
Yeo 7 on CDMD |
The same annotations after registered-sphere transfer (108,347 left and 108,379 right vertices) |
|
MIT |
CAB-NP v1.1.6 |
|
|
Non-commercial (Rutgers University and Yale University) |
Schaefer parcel names carry the Yeo network in their third underscore-separated field (7Networks_LH_Default_pCunPCC_11). Parcel colours are the published Yeo colours jittered per parcel. CAB-NP assigns each of HCP-MMP1.0’s 180 areas per hemisphere to one of 12 networks (Ji et al. 2019); its subcortical assignments are not used.
Method#
Transfer to the subject#
transfer_annotation (scripts/prepare_subject.py) gives each CDMD vertex the label of the nearest fsaverage vertex in sphere.reg space, without smoothing. It fails if the set of labels changes, and it checks 512 evenly spaced vertices (annotation_projection.verify_samples) against a brute-force nearest-vertex search.
Palette check#
read_networks (brain_model/build.py) passes the subject annotation to networks.verify_palette. Every parcel colour must lie within networks.maximum_color_jitter = 12 per RGB channel of its network’s published colour; otherwise the build fails. The widest jitter in both hemispheres, on fsaverage and on CDMD, is 8.
Network |
Key |
Published RGB |
|---|---|---|
Visual |
|
120, 18, 134 |
Somatomotor |
|
70, 130, 180 |
Dorsal attention |
|
0, 118, 14 |
Salience / ventral attention |
|
196, 58, 250 |
Limbic |
|
220, 248, 164 |
Frontoparietal control |
|
230, 148, 34 |
Default mode |
|
205, 62, 78 |
Parcel to network index#
networks.network_of reads the third name field and raises on an unknown network or a truncated name. network_indices maps each vertex to 1–7 in the order of the table above, and to 0 (NONE) for the medial wall and label −1. The index is the stored value and is part of the model’s contract.
Per-vertex field#
build_cortex runs once per cortical atlas (Destrieux, Desikan-Killiany, HCP-MMP1.0, Julich-Brain, Schaefer). partition_vertex_labels (brain_model/surfaces/geometry.py) carries the integer index onto the partitioned mesh. Source vertices keep their value. A vertex added on a region border takes the majority of its edge’s two ends or its face’s three corners; a tie goes to the lower value. The field is never averaged. It is written to each glTF region as _NETWORK (uint8; 0 unassigned).
Region composition#
For each cortical region, networks.composition counts its source vertices per network, excludes unassigned vertices from the denominator and stores the shares, largest first, as networks in manifest.json. No minimum is applied at build. NextBrain cortical regions have no surface: cortical_network_compositions (brain_model/labels/nextbrain.py) gives each of their voxels the network of the nearest pial or white vertex (k-d tree over both surfaces) after the same palette check, and composes shares over voxels.
CAB-NP assignment#
cab_np.read_label_keykeeps rows whose label ends in-Ctxand keys each by hemisphere and Glasser name (e.g.left,L_V1_ROI). It fails if a name is filed under the other hemisphere or assigned twice, if a network key has two names or colours, if either hemisphere has other than 180 areas, or if network keys do not run from 1 without gaps.The twelve networks, in key order: Visual1, Visual2, Somatomotor, Cingulo-Opercular, Dorsal-Attention, Language, Frontoparietal, Auditory, Default, Posterior-Multimodal, Ventral-Multimodal, Orbito-Affective. Each keeps its key colour (Default 255, 0, 0).
cab_np.assigngives every published HCP-MMP cortical region the network of its area name and hemisphere, and fails on an area missing from either side. Hemispheres are assigned separately, so the 13 areas assigned differently on each side keep that difference (e.g. area 44: Language left, Frontoparietal right).cab_np.exportwritescab-np.json(360 area-to-network assignments) and copies the licence and label key unchanged topublic/models/licenses/CAB-NP.txtandCAB-NP-LabelKey.txt, as the licence requires.
Display#
Both colourings are options of the masthead’s Colour list (URL colors=network or colors=cab-np). attachNetworkColors (web/src/lib/engine/render/network-colors.ts) converts _NETWORK to a four-channel per-vertex colour; the fourth channel is 1 only where a network exists. Colours, not indices, are interpolated across a triangle, so a Visual–Default border blends two colours instead of sweeping through five intermediate indices. The cortex material mixes the colour in by networkMix, set to 1 only under Yeo 7 on a region with no paint or ghost; the medial wall keeps its region colour.
CAB-NP is not a vertex field: brain-atlas.ts gives each HCP-MMP region its network’s colour. Choosing it switches the atlas to HCP-MMP1.0 (requiredAtlas), and setSurfaceColor('cab-np') throws on any other atlas. validateCabNp rejects an assignment to an unknown region or network and a network without a colour or name.
A cut face samples one label per parcel. Under Yeo 7 a parcel is painted with its dominant network (dominantNetwork, largest share ≥ 5%); a parcel split between networks is one colour on the cut and several on the surface, and the cut status line says so. Regions without a network (nuclei, white matter, medial wall) keep their tissue colour. The striatum is coloured voxel by voxel instead (striatal networks). The region detail (Functional networks) lists Yeo shares ≥ 5% (MINIMUM_SHARE), without renormalisation, with the counting basis (vertices or voxels); for an HCP-MMP area it adds its CAB-NP network.
Validation#
Test |
Criterion |
Result |
|---|---|---|
|
Every parcel colour within 12 per channel of its network colour |
Widest jitter 8 |
|
As above, on the published annotations |
Passes |
|
Unknown network or truncated name raises |
Passes |
|
Categorical field carried by majority, never averaged |
Passes |
|
Shares not rescaled |
Passes |
|
7- and 17-network orders pair the 400 parcels one to one |
Passes |
|
Published |
Exact |
|
180 areas per hemisphere |
Passes |
|
Areas assigned differently per hemisphere |
13 |
|
Rebuilt assignments equal |
Exact; 360 areas assigned |
|
Display threshold without rescaling; index past the palette draws no network; CAB-NP network without colour rejected |
Passes |
Limitations#
Group resting-state networks, not this brain’s measured function.
Yeo 7 reaches CDMD through one sphere registration from
fsaverage; CAB-NP through the HCP-MMP projection.CAB-NP assigns whole areas, so it colours HCP-MMP areas only and its borders are HCP-MMP’s.
Shares count assigned vertices or voxels, not surface area.
A cut face shows one network per parcel.
CAB-NP is licensed for non-commercial use only; HCP-MMP terms pass to every recipient of
cab-np.json(references).
Code availability#
- Code
brain_model/layers/networks.py,brain_model/layers/cab_np.py,read_networksandbuild_cortexinbrain_model/build.py,cortical_network_compositionsinbrain_model/labels/nextbrain.py,transfer_annotationinscripts/prepare_subject.py- Configuration
networks.maximum_color_jitter,annotation_projection.verify_samplesand theschaeferatlas entry inconfig/model.yaml- Tests
tests/test_networks.py,tests/test_cab_np.py,web/src/lib/core/catalog/networks.test.ts,web/src/lib/engine/render/network-colors.test.ts
uv sync --locked
uv run python scripts/prepare_subject.py --anatomy cdmd # project the annotations from fsaverage
uv run python -m brain_model.build --anatomy cdmd # writes _NETWORK and cab-np.json
uv run python -m brain_model.validate --anatomy cdmd
uv run pytest tests/test_networks.py tests/test_cab_np.py
Figure state (panel b): https://planumatlas.com/#anatomy=cdmd&atlas=hcp-mmp&colors=cab-np&view=left&hemi=left&internal=0