Пример #1
0
    def emulate_readings(self, sinogram, level):
        if self._need_repacking or self._mu.device != sinogram.device:
            self.repack(sinogram.device)

        if isinstance(level, torch.Tensor):
            return torch_radon_cuda.emulate_readings_multilevel(
                sinogram, self.radon.noise_generator, self._signals,
                self._normal_stds, self._ks, level, self.bins)
        else:
            return torch_radon_cuda.emulate_readings_new(
                sinogram, self.radon.noise_generator, self.signals[level],
                self.normal_stds[level], self.ks[level], self.bins)
Пример #2
0
 def emulate_readings_new(self, x, signal, normal_std, k, bins):
     return torch_radon_cuda.emulate_readings_new(x, self.noise_generator,
                                                  signal, normal_std, k,
                                                  bins)