def check_pipeline_parameters(self): """Check pipeline parameters.""" from clinica.utils.spm import get_tpm self.parameters.setdefault("tissue_classes", [1, 2, 3]) self.parameters.setdefault("dartel_tissues", [1, 2, 3]) self.parameters.setdefault("save_warped_unmodulated", True) self.parameters.setdefault("save_warped_modulated", False) self.parameters.setdefault("tissue_probability_maps", None) # Fetch the TPM in case none was passed explicitly. if not self.parameters["tissue_probability_maps"]: self.parameters["tissue_probability_maps"] = get_tpm()
def check_pipeline_parameters(self): """Check pipeline parameters.""" from clinica.utils.spm import get_tpm if 'tissue_classes' not in self.parameters.keys(): self.parameters['tissue_classes'] = [1, 2, 3] if 'dartel_tissues' not in self.parameters.keys(): self.parameters['dartel_tissues'] = [1, 2, 3] if 'tissue_probability_maps' not in self.parameters.keys(): self.parameters['tissue_probability_maps'] = None if 'save_warped_unmodulated' not in self.parameters.keys(): self.parameters['save_warped_unmodulated'] = True if 'save_warped_modulated' not in self.parameters.keys(): self.parameters['save_warped_modulated'] = False # Get Tissue Probability Map from SPM if self.parameters['tissue_probability_maps'] is None: self.parameters['tissue_probability_maps'] = get_tpm()