Pydra tasks for TemplateFlow
Project description
pydra-templateflow
Pydra tasks for TemplateFlow.
Pydra is a dataflow engine which provides a set of lightweight abstractions for DAG construction, manipulation, and distributed execution.
TemplateFlow provides a framework for publicly hosting and distributing neuroimaging templates for human and nonhuman brains.
Table of contents
Available tasks
This package provides a get_template
task, which takes a mandatory template_id
argument
and an optional output_queries
mapping from output names to their respective query entities.
The following example showcases using get_template
to download the template image,
brain and head masks for the Linear ICBM Average Brain (ICBM152).
from pydra.tasks import templateflow
task = templateflow.get_template(
template_id="MNI152Lin",
output_queries={
"brain_mask": {"resolution": "1", "suffix": "mask", "desc": "head"},
"head_mask": {"resolution": 1, "suffix": "mask", "desc": "brain"},
"t1w_image": {"resolution": "1", "suffix": "T1w"},
},
)
result = task()
Please check the list of available templates here.
Installation
pip install pydra-templateflow
Development
This project is managed with Hatch:
pipx install hatch
To run the test suite:
hatch run test
To fix linting issues:
hatch run lint:fix
License
This project is distributed under the terms of the Apache License, Version 2.0.
Project details
Release history Release notifications | RSS feed
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
Hashes for pydra_templateflow-0.0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | bc9ad8fa3390c4b7d27a55b499ca3ce0197a0d5a1822e7667114a801354f8558 |
|
MD5 | 8bb1cafd7a424e63a6e209ffb59261d6 |
|
BLAKE2b-256 | 0fcfe9a7c0f3e7a1652ea5b371598e9e02679e0955debd44088618498e5c7ee7 |