コード例 #1
0
 def intensity_postprocessing_mr(self, image):
     """
     Intensity postprocessing for MR input.
     :param image: The np input image.
     :return: The processed image.
     """
     image = normalize_robust(image)
     return ShiftScaleClamp(clamp_min=-1.0)(image)
コード例 #2
0
 def intensity_postprocessing(self, image):
     """
     Intensity postprocessing.
     :param image: The np input image.
     :return: The processed image.
     """
     normalized = normalize_robust(image)
     return normalized
コード例 #3
0
 def intensity_postprocessing_augmented(self, image):
     """
     Intensity postprocessing. Random augmentation version.
     :param image: The np input image.
     :return: The processed image.
     """
     normalized = normalize_robust(image)
     return ShiftScaleClamp(random_shift=0.15,
                            random_scale=0.15)(normalized)
コード例 #4
0
 def intensity_postprocessing_mr_random(self, image):
     """
     Intensity postprocessing for MR input. Random augmentation version.
     :param image: The np input image.
     :return: The processed image.
     """
     image = normalize_robust(image)
     return ShiftScaleClamp(random_shift=0.2,
                            random_scale=0.4,
                            clamp_min=-1.0)(image)
コード例 #5
0
 def intensity_postprocessing_mr_random(self, image):
     """
     Intensity postprocessing for MR input. Random augmentation version.
     :param image: The np input image.
     :return: The processed image.
     """
     image = change_gamma_unnormalized(image, float_uniform(0.5, 1.5))
     image = normalize_robust(image, consideration_factors=(0.1, 0.1))
     return ShiftScaleClamp(random_shift=0.6,
                            random_scale=0.6,
                            clamp_min=-1.0)(image)