A comprehensive Python toolkit for neuroimaging data processing and analysis, specifically designed for working with brain connectivity data, BIDS datasets, and various neuroimaging formats.
Free software: Apache Software License 2.0
Documentation: https://clabtoolkit.readthedocs.io
Source Code: https://github.com/connectomicslab/clabtoolkit
Python versions: 3.9+
Installation
Install from PyPI:
pip install clabtoolkit
For development installation:
git clone https://github.com/connectomicslab/clabtoolkit.git cd clabtoolkit pip install -e .[dev]
Features
- BIDS Tools (clabtoolkit.bidstools)
BIDS dataset validation and manipulation
Entity extraction from BIDS filenames
Conversion between BIDS formats
Metadata handling for neuroimaging datasets
- Connectivity Tools (clabtoolkit.connectivitytools)
Brain connectivity matrix analysis
Network-based statistics
Graph theory metrics computation
Connectivity visualization utilities
- FreeSurfer Tools (clabtoolkit.freesurfertools)
FreeSurfer output parsing and processing
Surface-based analysis utilities
Cortical thickness and morphometry tools
Integration with FreeSurfer workflows
- Image Processing Tools (clabtoolkit.imagetools)
Neuroimaging data I/O operations
Image registration and transformation
Quality control and preprocessing utilities
Multi-modal image processing
- Parcellation Tools (clabtoolkit.parcellationtools)
Brain parcellation scheme handling
Region-of-interest (ROI) extraction
Atlas-based analysis tools
Custom parcellation creation
- Surface Tools (clabtoolkit.surfacetools)
Surface mesh processing and analysis
Cortical surface manipulation
Surface-based statistics
Visualization of surface data
- DWI Tools (clabtoolkit.dwitools)
Diffusion-weighted imaging analysis
Tractography processing utilities
DTI and advanced diffusion modeling
White matter analysis tools
- Quality Control Tools (clabtoolkit.qcqatools)
Automated quality assessment
Image artifact detection
Quality metrics computation
Reporting and visualization
- Visualization Tools (clabtoolkit.visualizationtools)
Brain visualization utilities
Interactive plotting capabilities
Publication-ready figures
Multi-modal data visualization
Quick Start
import clabtoolkit.bidstools as bids
import clabtoolkit.connectivitytools as conn
# Load BIDS configuration
config = bids.load_bids_json()
# Extract entities from BIDS filename
entities = bids.str2entity("sub-01_ses-M00_T1w.nii.gz")
print(entities) # {'sub': '01', 'ses': 'M00', 'suffix': 'T1w', 'extension': 'nii.gz'}
# Process connectivity data
# conn_matrix = conn.load_connectivity_matrix("path/to/connectivity.mat")
Contributing
Contributions are welcome! Please feel free to submit a Pull Request. For major changes, please open an issue first to discuss what you would like to change.
Fork the repository
Create your feature branch (git checkout -b feature/amazing-feature)
Commit your changes (git commit -m 'Add some amazing feature')
Push to the branch (git push origin feature/amazing-feature)
Open a Pull Request
Testing
Run tests with:
pytest
Run tests with coverage:
pytest --cov=clabtoolkit
Changelog
See HISTORY.rst for a detailed changelog.
Credits
This package was created with Cookiecutter and the audreyr/cookiecutter-pypackage project template.
Release files for clabtoolkit 0.4.5
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| clabtoolkit-0.4.5.tar.gz | 5.4 MB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| clabtoolkit-0.4.5-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 5.8 MB
Release files / clabtoolkit-0.4.5.tar.gz
| Download URL | clabtoolkit-0.4.5.tar.gz |
|---|---|
| Size | 5.4 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
b7ecc2867b89e75ea125e39e71279c6923783ab1a33225641de3fe9858cbd16c
|
|
BLAKE2b-256 checksum How to use checksums |
4245d319c9dd0819262bd4a5959861a0911e8ac666efb1547e7526ad9f06f97f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Release files / clabtoolkit-0.4.5-py3-none-any.whl
| Download URL | clabtoolkit-0.4.5-py3-none-any.whl |
|---|---|
| Size | 412.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
9a030f32d553a658ac484e3c171c05cdaf0ceb513b0442a4d2ecd3547e0a91c9
|
|
BLAKE2b-256 checksum How to use checksums |
7e2f1a8a3e71c9028ce8918d9f8bc9548823825dc90c6b2168d1d4da401b3e9a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|