Automatically create cortical flatmaps from FreeSurfer surfaces
Project description
autoflatten: automatically create cortical flatmaps from FreeSurfer surfaces
autoflatten is a Python pipeline for 🌟automatically🌟 flattening cortical surfaces generated by FreeSurfer
TL;DR: run autoflatten /path/to/your/freesufer/subject; done.
Features
- Automatic cut mapping from a template to individual subjects
- Two flattening backends: JAX-accelerated pyflatten (default) or FreeSurfer's
mris_flatten - Visualization with area distortion metrics
Quick Start
# Install
pip install autoflatten
# Run on a FreeSurfer subject (requires FreeSurfer 6.0+ for projection)
autoflatten /path/to/subjects/sub-01
Documentation
For full documentation, usage examples, and configuration options, visit the autoflatten website.
See example outputs to preview what autoflatten produces.
Citation
If you use autoflatten in your research, please cite both autoflatten and the original FreeSurfer flattening method:
Visconti di Oleggio Castello, M., & Gallant, J. L. (2025). autoflatten: automatically create cortical flatmaps from FreeSurfer surfaces. Zenodo. https://doi.org/10.5281/zenodo.17933205
@software{visconti_di_oleggio_castello_2025_autoflatten,
author = {Visconti di Oleggio Castello, Matteo and Gallant, Jack L.},
title = {autoflatten: automatically create cortical flatmaps from FreeSurfer surfaces},
year = 2025,
publisher = {Zenodo},
doi = {10.5281/zenodo.17933205},
url = {https://doi.org/10.5281/zenodo.17933205}
}
Fischl, B., Sereno, M. I., & Dale, A. M. (1999). Cortical surface-based analysis II: Inflation, flattening, and a surface-based coordinate system. NeuroImage, 9(2), 195-207. https://doi.org/10.1006/nimg.1998.0396
@article{fischl1999cortical,
author = {Fischl, Bruce and Sereno, Martin I. and Dale, Anders M.},
title = {Cortical surface-based analysis {II}: Inflation, flattening, and a surface-based coordinate system},
journal = {NeuroImage},
year = 1999,
volume = 9,
number = 2,
pages = {195--207},
doi = {10.1006/nimg.1998.0396}
}
License
BSD 2-Clause License. See LICENSE file for details.
Acknowledgments
- Default fsaverage template cuts by Mark Lescroart and Natalia Bilenko
- Geodesic refinement step inspired by code from Bhavin Gupta and Alex Huth
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file autoflatten-1.0.6.tar.gz.
File metadata
- Download URL: autoflatten-1.0.6.tar.gz
- Upload date:
- Size: 191.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
93576a0c2dd31607ad324ff1c90849fdfeb7726d2c95914514876b3e17971a49
|
|
| MD5 |
a9ac656658c92293f53603b4b7ce66d6
|
|
| BLAKE2b-256 |
6dd2c639a477cff630b09a20b78a914ab2000888da5affd609010fad4f88c66f
|
Provenance
The following attestation bundles were made for autoflatten-1.0.6.tar.gz:
Publisher:
publish.yml on gallantlab/autoflatten
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
autoflatten-1.0.6.tar.gz -
Subject digest:
93576a0c2dd31607ad324ff1c90849fdfeb7726d2c95914514876b3e17971a49 - Sigstore transparency entry: 774270832
- Sigstore integration time:
-
Permalink:
gallantlab/autoflatten@096148cc52cd2eeed3a0d0215366f17fea41cb5a -
Branch / Tag:
refs/tags/v1.0.6 - Owner: https://github.com/gallantlab
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@096148cc52cd2eeed3a0d0215366f17fea41cb5a -
Trigger Event:
release
-
Statement type:
File details
Details for the file autoflatten-1.0.6-py3-none-any.whl.
File metadata
- Download URL: autoflatten-1.0.6-py3-none-any.whl
- Upload date:
- Size: 196.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4f6e175e622dcd745e39f577b9a91a8f19f484bfcdc57609b80ba1d7fd7be0db
|
|
| MD5 |
d8c3de4efd1d5ad5df6c39d383d5eb27
|
|
| BLAKE2b-256 |
729dc77a757b0ae22ce9bf26d7202a12ee1c26c418536edf763e63b3fcda9ed1
|
Provenance
The following attestation bundles were made for autoflatten-1.0.6-py3-none-any.whl:
Publisher:
publish.yml on gallantlab/autoflatten
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
autoflatten-1.0.6-py3-none-any.whl -
Subject digest:
4f6e175e622dcd745e39f577b9a91a8f19f484bfcdc57609b80ba1d7fd7be0db - Sigstore transparency entry: 774270834
- Sigstore integration time:
-
Permalink:
gallantlab/autoflatten@096148cc52cd2eeed3a0d0215366f17fea41cb5a -
Branch / Tag:
refs/tags/v1.0.6 - Owner: https://github.com/gallantlab
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@096148cc52cd2eeed3a0d0215366f17fea41cb5a -
Trigger Event:
release
-
Statement type: