Skip to article frontmatterSkip to article content
Site not loading correctly?

This may be due to an incorrect BASE_URL configuration. See the MyST Documentation for reference.

neuropipe run

neuropipe run [OPTIONS]

Required Arguments

ArgumentDescriptionExample
--subjectsSubject IDs — comma-separated string or path to a text file (one ID per line, or comma-separated)001,002 or subjects.txt
--inputInput data directory/data/BIDS
--outputOutput base directory/data/processed
--workWork base directory (logs, database, temp files)/data/work
--config-dirPath to config directory — must contain config.yaml, hpc_config.yaml, and project_config/. Optional if $NEUROPIPE_CONFIG_DIR is set./data/config
--projectProject name — loads {project}_config.yaml from --config-dir/project_config/my_study
--sessionSession or wave ID01

Processing Options

The pipeline uses two categories of multi-step pipelines:

OptionValuesDescription
--prepunzip | recon | unzip_reconData preparation
--intermedvolume | volume,bfc | ...Intermed tasks (comma-separated); required before --staged-prep
--bids-preprest | dwi | rest,dwiBIDS pipeline preprocessing
--bids-postrest | dwi | rest,dwiBIDS pipeline postprocessing
--staged-prepcards | kidvid | cards,kidvidStaged pipeline preprocessing
--staged-postcards | kidvid | cards,kidvidStaged pipeline postprocessing
--mriqcindividual | group | allQuality control (MRIQC)

Pipeline section names (e.g. rest, dwi, cards) must match section names defined in config.yaml.


Task Expansion Rules

For full dependency and parallel execution behavior, see Pipeline Reference → CLI Flags Overview.


Execution Options

OptionDescription
--dry-runPrint SLURM commands without submitting. Wrapper scripts are still written to log/wrapper/ so you can inspect them.
--resumeSkip subjects whose outputs already pass checks in {project}_checks.yaml. Submits full count with warning if file is missing.
--skip-preflightSkip pre-flight config schema and filesystem checks.
--skip-bids-validationSkip BIDS format validation (runs automatically when --bids-prep or --mriqc individual/all is used).
--waitWait for all submitted jobs to complete before exiting
--polling-interval NSeconds between SLURM status polls when --wait is active (default: 60)

Passing Subjects

Comma-separated:

--subjects 001,002,003

Repeated flags (both forms are equivalent):

--staged-prep cards,kidvid
--staged-prep cards --staged-prep kidvid

From a text file (one ID per line, or comma-separated):

# one per line
printf "001\n002\n003" > subjects.txt

# or comma-separated
echo "001,002,003" > subjects.txt

neuropipe run --subjects subjects.txt ...

The subject prefix (sub-) comes from the project config prefix field; do not include it in subject IDs.


--dry-run

Generates all wrapper scripts and prints the exact sbatch commands, but does not queue anything. Use it to:


--resume

Before submitting each task’s array job, the pipeline calls OutputChecker to find which subjects already have valid outputs. Only pending subjects are included in the array. If a task has no pending subjects at all, it is skipped entirely and downstream tasks lose their afterok dependency on it.

If {project}_checks.yaml is missing, --resume is silently ignored (with a warning) and all subjects are submitted.