cmp.pipelines.anatomical.anatomical module¶
Anatomical pipeline Class definition.
-
class
cmp.pipelines.anatomical.anatomical.
AnatomicalPipeline
(project_info)[source]¶ Bases:
cmp.pipelines.common.Pipeline
Class that extends a
Pipeline
and represents the processing pipeline for structural MRI.It is composed of the segmentation stage that performs FreeSurfer recon-all and the parcellation stage that creates the Lausanne brain parcellations.
See also
cmp.stages.segmentation.segmentation.SegmentationStage
,cmp.stages.parcellation.parcellation.ParcellationStage
-
check_config
()[source]¶ Check if custom white matter mask and custom atlas files specified in the configuration exist.
- Returns
message – String empty if all the checks pass, otherwise it contains the error message
- Return type
string
-
check_input
(layout, gui=True)[source]¶ Check if input of the anatomical pipeline are available.
- Parameters
layout (bids.BIDSLayout) – Instance of BIDSLayout
gui (traits.Bool) – Boolean used to display different messages but not really meaningful anymore since the GUI components have been migrated to
cmp.bidsappmanager
- Returns
valid_inputs – True if inputs are available
- Return type
traits.Bool
-
check_output
()[source]¶ Check if outputs of an
AnatomicalPipeline
are available.- Returns
valid_output <Bool> – True if all outputs are found
error_message <string> – Error message if an output is not found.
-
create_pipeline_flow
(cmp_deriv_subject_directory, nipype_deriv_subject_directory)[source]¶ Create the pipeline workflow.
- Parameters
<Directory> (nipype_deriv_subject_directory) – Main CMP output directory of a subject e.g.
/output_dir/cmp/sub-XX/(ses-YY)
<Directory> – Intermediate Nipype output directory of a subject e.g.
/output_dir/nipype/sub-XX/(ses-YY)
- Returns
An instance of
nipype.pipeline.engine.Workflow
- Return type
anat_flow <nipype.pipeline.engine.Workflow>
-
define_custom_mapping
(custom_last_stage)[source]¶ Define the pipeline to be executed until a specific stages.
Not used yet by CMP3.
- Parameters
custom_last_stage (string) – Last stage to execute. Valid values are “Segmentation” and “Parcellation”
-
global_conf
= <cmp.pipelines.anatomical.anatomical.Global_Configuration object>¶
-
input_folders
= ['anat']¶
-
now
= '20210308_0637'¶
-
ordered_stage_list
= ['Segmentation', 'Parcellation']¶
-
update_parcellation
()[source]¶ Update self.stages[‘Parcellation’].config.parcellation_scheme when
seg_tool
is updated.
-
-
class
cmp.pipelines.anatomical.anatomical.
Check_Input_Notification
[source]¶ Bases:
traits.has_traits.HasTraits
-
class
cmp.pipelines.anatomical.anatomical.
Global_Configuration
[source]¶ Bases:
traits.has_traits.HasTraits
Global pipeline configurations.
-
process_type
¶ Processing pipeline type
- Type
‘fMRI’
-
subjects
¶ List of subjects ID (in the form
sub-XX
)- Type
traits.List
-
subject
¶ Subject to be processed (in the form
sub-XX
)- Type
traits.Str
-
subject_session
¶ Subject session to be processed (in the form
ses-YY
)- Type
traits.Str
-