Champollion V1
Pre-trained Barlow Twins models for generating embeddings of cortical folding patterns from T1 MRI brain scans.
What is Champollion?
Champollion uses self-supervised learning (Barlow Twins) to produce compact vector representations of 28 sulcal regions per hemisphere (56 total) from 3D brain MRI data. These embeddings capture individual cortical folding variability and can be used for downstream tasks such as classification, clustering, or population-level analysis.
Each model fold corresponds to one sulcal region and hemisphere. Given a preprocessed brain crop, the model outputs a fixed-size embedding vector per subject.
How to use
Try it online
A live demo is available on Hugging Face Spaces. Upload a T1 MRI (.nii.gz) and get embeddings in minutes. The demo runs on 2 CPU cores and is suited for quick testing with a single subject.
Run at scale
For batch processing or production use, install the champollion_pipeline on your own infrastructure where it can leverage all available CPUs and GPUs.
# Install
git clone https://github.com/neurospin/champollion_pipeline.git
cd champollion_pipeline
pixi run install-all
# Generate embeddings (downloads models automatically)
pixi run embeddings \
neurospin/Champollion_V1 \
/path/to/MY_DATASET \
--masks-version canonical_corrected_26_1
neurospin/Champollion_V1 is this repository's Hugging Face ID (models are downloaded on first use), /path/to/MY_DATASET is your dataset root directory, and --masks-version selects the model subfolder (see Repository structure).
Instead of pixi run install-all, you can run ./install.sh (or pixi run setup once pixi install -e default has run) to use the pipeline's interactive setup wizard and pick the "Embeddings inference only" option — it installs only what this quickstart needs.
See the pipeline README for the full step-by-step guide (Morphologist graphs, cortical tiles, config generation, embeddings).
Model details
- Architecture: Barlow Twins (self-supervised learning) with CNN (convolutional neural network) backbone
- Input: 3D brain crops of sulcal regions (numpy arrays)
- Output: Fixed-size embedding vectors per subject
- Training data: UKBioBank
- Number of models: 56 (28 regions x 2 hemispheres)
Repository structure
Models are organised by mask version. Each version contains 56 region folders (28 regions × 2 hemispheres).
Champollion_V1/
canonical_corrected_26_1/ # Latest version
SC-sylv_left/
.hydra/config.yaml # Training configuration
logs/best_model_weights.pt
SC-sylv_right/
...
... (56 model folds total)
canonical_25/ # Previous version
...
Related resources
| Resource | Description |
|---|---|
| champollion_pipeline | Full pipeline for generating embeddings from raw T1 MRIs |
| Champollion Demo | Interactive demo on Hugging Face Spaces |
License
This model is released under the CeCILL-B license.