pyFSViz
Description
Python tools for FreeSurfer visualization and quality assurance. pyFSViz builds HTML reports
from existing recon-all output (individual screenshots and group metric
summaries). It does not run FreeSurfer reconstructions.
While manual QA of FreeSurfer data is always recommended, this workflow become untenable with larger datasets, especially longitudinal ones. Several tools are available (some of which are utilized by this package), however, after doing manual QA myself for years, I've found a few key pieces missing.
- The ability to check Talairach registrations (an important first step as this affects downstream processing and brain volume calculations)
- An easy way to check for outliers at a glance (can be done statistically later on but also useful in catching errors earlier on in the process, especially for large datasets)
- Comparison between groups (especially helpful for multi-site data that may have different scanner characteristics)
pyFSViz relies on code from Deep-MI's fsqc, as well as other neuroimaging python packages such as nipype and nireports.
FreeSurfer and FSL are not part of this install. Install those tools separately and source their setup scripts in the same shell or job before using pyFSViz. See Prerequisites.
Installation
Requires Python 3.10 or newer. This installs the Python package only.
pip install pyfsviz
With uv:
uv tool install pyfsviz
Usage
After FreeSurfer and FSL are initialized:
from pyfsviz import FreeSurfer
fs = FreeSurfer()
fs.gen_batch_reports("reports/")
fs.gen_group_report("reports/")
See the quick start for output layout, group comparisons, and batch flags.
Acknowledgements
Thanks to pawamoy's copier project for package templates!
AI Disclosure
Please note that the default Cursor Agent was used in this project. This included models suchs as Grok-4.6 and Composer-2.5. The agent was used to improve base code, add testing, help with html development, and documentation.
Release files for pyfsviz 0.6.17
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| pyfsviz-0.6.17.tar.gz | 9.1 MB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| pyfsviz-0.6.17-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 15.6 MB
Release files / pyfsviz-0.6.17.tar.gz
| Download URL | pyfsviz-0.6.17.tar.gz |
|---|---|
| Size | 9.1 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
8bb4b28e324cd2c899dfc2ee23f335a25b35f5c74d6d82b61585bb731d4c8451
|
|
BLAKE2b-256 checksum How to use checksums |
fd35993b17ed2118d4baba9ea42dce6a28cb4b6371bc6f8c90d61c2c56fcb5fb
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.12.12
|
Release files / pyfsviz-0.6.17-py3-none-any.whl
| Download URL | pyfsviz-0.6.17-py3-none-any.whl |
|---|---|
| Size | 6.6 MB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
4c5f9d768bb043ab4ae48affa0bcee437932dd0ecb0b0b54c95dc219c9f35747
|
|
BLAKE2b-256 checksum How to use checksums |
c10ab428f1ed94d00f24b1c10196f4a037aed2a3b0211bf303a6b45bfdae3a12
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.12.12
|