def randomize(self, weight_map: np.ndarray) -> None: self.centers = weighted_patch_samples( spatial_size=self.spatial_size, w=weight_map[0], n_samples=self.num_samples, r_state=self.R) # using only the first channel as weight map
def randomize(self, weight_map: np.ndarray) -> None: self.centers = weighted_patch_samples(spatial_size=self.spatial_size, w=weight_map[0], n_samples=self.num_samples, r_state=self.R)