def test_load_allowed_recon_args_with_cuda(self):
     allowed_args = tomopy_allowed_kwargs()
     allowed_args.update(astra_allowed_kwargs())
     allowed_args.update(cil_allowed_kwargs())
     with mock.patch(
             "mantidimaging.gui.windows.recon.model.CudaChecker.cuda_is_present",
             return_value=True):
         assert self.model.load_allowed_recon_kwargs() == allowed_args
Exemple #2
0
 def load_allowed_recon_kwargs():
     d = tomopy_allowed_kwargs()
     if CudaChecker().cuda_is_present():
         d.update(astra_allowed_kwargs())
         d.update(cil_allowed_kwargs())
     return d
 def test_load_allowed_recon_args_no_cuda(self):
     with mock.patch(
             "mantidimaging.gui.windows.recon.model.CudaChecker.cuda_is_present",
             return_value=False):
         assert self.model.load_allowed_recon_kwargs(
         ) == tomopy_allowed_kwargs()
Exemple #4
0
 def load_allowed_recon_kwargs():
     d = tomopy_allowed_kwargs()
     d.update(astra_allowed_kwargs())
     return d