SKULLSTRIP(1)
πβ¨ SKULLSTRIP β¨π
ok so this is the skullstrip page from the Generated Python Manual, and bestie, it's giving "delete the skull, keep the brain" energy and honestly? iconic. π
πΈ SYNOPSIS πΈ
skullstrip [-h] [-p LABEL [LABEL ...]] [-m PATTERN] [-o DESTINATION
[DESTINATION ...]] [-f] [-a ARGS] [-c [SPECS]] bidsfolder pattern
π§ DESCRIPTION π§
It's a lil wrapper around FreeSurfer's synthstrip skull stripping tool (<https://surfer.nmr.mgh.harvard.edu/docs/synthstrip>). Not a link in the "click me" sense but you get it, that's the docs URL, go read it.
Except for BIDS inheritances, this wrapper is BIDS-aware (a bidsapp) and writes BIDS compliant output. no cap, it plays by the BIDS rules. π
The corresponding brain mask gets saved in the bids/derivatives/synthstrip folder. that's where the mask lives now, periodt.
Assumes the installation of FreeSurfer v7.3.2 or higher β like, if you're on an older one, this is not the vibe, upgrade bestie. π«Ά
bidsfolder The bids-directory with the subject data. it's the folder, it's got the subjects, that's the whole thing. π
pattern Globlike search pattern (relative to the subject/session folder) to select the (3D) images that need to be skullstripped, e.g. 'anat/*_T1w*'. so like, you glob it, it picks the pics, we strip the skulls. β¨
π OPTIONS π
-p LABEL [LABEL ...],--participant LABEL [LABEL ...]β Space separated list ofsub-#identifiers to be processed (thesub-prefix can be left out, so you can be lazy, it's fine π). If not specified then all participants will be processed. everyone's getting the treatment. π-m PATTERN,--masked PATTERNβ Globlike search pattern (relative to the subject/session folder) to select additional (3D/4D) images from the same space that need to be masked with the same mask, e.g.'fmap/*_phasediff'. same mask, more images, efficient queen behaviour. π¦ NB: This option can only be used ifpatternyields a single file per session. one file per session or it simply does not work, no exceptions.-o DESTINATION [DESTINATION ...],--output DESTINATION [DESTINATION ...]β One or two output strings that determine where the skullstripped + additional masked images are saved. Each output string can be the name of a BIDS datatype folder, such as'anat', or of the derivatives folder, i.e.'derivatives'(default). β¨ If the output string is the same as the datatype then the original images are replaced by the skullstripped images. β οΈ like, replaced replaced. heads up.-f,--forceβ Process images, regardless whether images have already been skullstripped (i.e. if{'SkullStripped': True}in the json sidecar file). it doesn't care that you already did it, it's doing it again. main character energy. π₯-a ARGS,--args ARGSβ Additional arguments that are passed tosynthstrip. NB: Use quotes and include at least one space character to prevent premature parsing. quotes + a space, bestie, or the parser gets confused and we all cry. π-c [SPECS],--cluster [SPECS]β Use the DRMAA library to submit the skullstrip jobs to a high-performance compute (HPC) cluster. π You can add an opaque DRMAA argument with native specifications for your HPC resource manager. NB: Use quotes and include at least one space character to prevent premature parsing β see examples. same deal as before: quotes, space, or chaos. π
π COMMENTS π
examples, aka the receipts:
skullstrip myproject/bids anat/*_T1w*
skullstrip myproject/bids anat/*_T1w* -p 001 003 -a " --no-csf"
skullstrip myproject/bids fmap/*_magnitude1* -m fmap/*_phasediff* -o
extra_data fmap
skullstrip myproject/bids fmap/*_acq-mylabel*_magnitude1* -m
fmap/*_acq-mylabel_* -o fmap
ok notice how in example two the-avalue starts with a space inside the quotes? and in example three the-oline wraps ontoextra_data fmap? that's the "include at least one space character" thing in action, don't @ me, that's just how it is. π
π AUTHOR π
Marcel Zwiers <m.zwiers@donders.ru.nl> β the legend who wrote this, respect. π
and that's the whole page bestie!! π the footer said it's bidscoin 4.6.2 and it's dated 2025-11-06, so yeah, that's the version and the date, slay, go strip some skulls, you got this ππ¦β¨
π¦ where this page comes from
- fedora 43: bidscoin 4.6.2-1.fc43 Β· GPL-3.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms