예제 #1
0
 def __init__(
     self,
     keys: KeysCollection,
     sigma1: Union[Sequence[float], float] = 3.0,
     sigma2: Union[Sequence[float], float] = 1.0,
     alpha: float = 30.0,
 ) -> None:
     super().__init__(keys)
     self.converter = GaussianSharpen(sigma1, sigma2, alpha)
예제 #2
0
파일: dictionary.py 프로젝트: walehn/MONAI
 def __call__(self, data):
     d = dict(data)
     self.randomize()
     if not self._do_transform:
         return d
     for key in self.keys:
         sigma1 = ensure_tuple_size(tup=(self.x1, self.y1, self.z1), dim=d[key].ndim - 1)
         sigma2 = ensure_tuple_size(tup=(self.x2, self.y2, self.z2), dim=d[key].ndim - 1)
         d[key] = GaussianSharpen(sigma1=sigma1, sigma2=sigma2, alpha=self.a, approx=self.approx)(d[key])
     return d
예제 #3
0
 def __init__(
     self,
     keys: KeysCollection,
     sigma1: Union[Sequence[float], float] = 3.0,
     sigma2: Union[Sequence[float], float] = 1.0,
     alpha: float = 30.0,
     approx: str = "erf",
     allow_missing_keys: bool = False,
 ) -> None:
     super().__init__(keys, allow_missing_keys)
     self.converter = GaussianSharpen(sigma1, sigma2, alpha, approx=approx)