qsirecon.utils.ingress module
Utilities to handle data from other preprocessing pipelines
- qsirecon.utils.ingress.collect_ukb_participants(ukb_layout, participant_label)[source]
Collect all valid UKB participants.
- Parameters:
- Returns:
participants – A list of participant labels.
- Return type:
- qsirecon.utils.ingress.create_ukb_layout(ukb_dir, participant_label=None)[source]
Find all valid ukb directories under ukb_dir.
- Parameters:
ukb_dir (
pathlib.Path) – The path to the ukb directory.participant_label (
listofstr) – A list of participant labels to search for.
- Returns:
ukb_layout – A list of dictionaries containing the subject ID, session ID, path to the ukb directory, and the path to the fake dwi file.
- Return type:
- qsirecon.utils.ingress.missing_from_ukb_directory(ukb_subject_dir)[source]
Check for missing files in a ukb subject directory.
- Parameters:
ukb_subject_dir (
pathlib.Path) – The path to the ukb subject directory.- Returns:
missing_files – A list of missing files.
- Return type:
- qsirecon.utils.ingress.ukb_dirname_to_bids(ukb_dir)[source]
Convert a UKB directory name to a BIDS subject ID.
- Parameters:
ukb_dir (
pathlib.Path) – The path to the ukb directory.- Returns:
bids_subject_id – The BIDS subject ID and session ID, combined in a string.
- Return type: