diff --git a/corrct/_projector_backends.py b/corrct/_projector_backends.py index 15ef1c8..68639e0 100644 --- a/corrct/_projector_backends.py +++ b/corrct/_projector_backends.py @@ -126,7 +126,7 @@ def initialize_geometry( angles_rot_rad: Union[ArrayLike, NDArray], rot_axis_shift_pix: Union[ArrayLike, NDArray, None] = None, prj_geom: Optional[ProjectionGeometry] = None, - create_single_projs: bool = True, + create_single_projs: bool = False, ): """Initialize the projector geometry. @@ -142,7 +142,7 @@ def initialize_geometry( The fully specified projection geometry. When active, the rotation axis shift is ignored. The default is None. create_single_projs : bool, optional - Whether to create projectors for single projections. Used for corrections and SART. The default is True. + Whether to create projectors for single projections. Used for corrections and SART. The default is False. """ self.vol_geom = vol_geom @@ -276,7 +276,7 @@ def initialize_geometry( angles_rot_rad: Union[ArrayLike, NDArray], rot_axis_shift_pix: Union[ArrayLike, NDArray, None] = None, prj_geom: Optional[ProjectionGeometry] = None, - create_single_projs: bool = True, + create_single_projs: bool = False, ): """Initialize projector backend based on scikit-image. @@ -294,7 +294,7 @@ def initialize_geometry( When active, the rotation axis shift is ignored. The default is None. NOT SUPPORTED: if anything else than None is passed, it will throw an error! create_single_projs : bool, optional - Whether to create projectors for single projections. Used for corrections and SART. The default is True. + Whether to create projectors for single projections. Used for corrections and SART. The default is False. Raises ------ @@ -433,7 +433,7 @@ def initialize_geometry( angles_rot_rad: Union[ArrayLike, NDArray], rot_axis_shift_pix: Union[ArrayLike, NDArray, None] = None, prj_geom: Optional[ProjectionGeometry] = None, - create_single_projs: bool = True, + create_single_projs: bool = False, ): """Initialize geometry of projector backend based on astra-toolbox. @@ -449,7 +449,7 @@ def initialize_geometry( The fully specified projection geometry. When active, the rotation axis shift is ignored. The default is None. create_single_projs : bool, optional - Whether to create projectors for single projections. Used for corrections and SART. The default is True. + Whether to create projectors for single projections. Used for corrections and SART. The default is False. Raises ------ @@ -753,7 +753,7 @@ def initialize_geometry( angles_rot_rad: Union[ArrayLike, NDArray], rot_axis_shift_pix: Union[ArrayLike, NDArray, None] = None, prj_geom: Optional[ProjectionGeometry] = None, - create_single_projs: bool = True, + create_single_projs: bool = False, ): """Initialize projector backend based on experimental astra-toolbox functions. @@ -769,7 +769,7 @@ def initialize_geometry( The fully specified projection geometry. When active, the rotation axis shift is ignored. The default is None. create_single_projs : bool, optional - Whether to create projectors for single projections. Used for corrections and SART. The default is True. + Whether to create projectors for single projections. Used for corrections and SART. The default is False. Raises ------ diff --git a/corrct/projectors.py b/corrct/projectors.py index b705cd9..5248b55 100755 --- a/corrct/projectors.py +++ b/corrct/projectors.py @@ -124,7 +124,7 @@ def __init__( prj_intensities: Optional[ArrayLike] = None, psf: Optional[ArrayLike] = None, backend: Union[str, prj_backends.ProjectorBackend] = "astra" if astra_available else "skimage", - create_single_projs: bool = True, + create_single_projs: bool = False, ): """Initialize the base projection class. @@ -152,7 +152,7 @@ def __init__( The default is True if CUDA and ASTRA are available, otherwise False. create_single_projs : bool, optional Whether to create projectors for single projections. - Used for corrections and SART, by default True. + Used for corrections and SART, by default False. Raises ------ @@ -168,7 +168,7 @@ def __init__( raise ValueError(f"Passed ASTRA projector, but astra not available ({astra_status}).") if not isinstance(vol_geom, models.VolumeGeometry): - vol_geom = models.VolumeGeometry(vol_shape_xyz=np.array(vol_geom)) + vol_geom = models.VolumeGeometry(_vol_shape_xyz=np.array(vol_geom)) self.vol_geom = vol_geom if not len(self.vol_geom.shape_xyz) in (2, 3): @@ -448,6 +448,7 @@ def __init__( psf=psf, prj_intensities=prj_intensities, backend=backend, + create_single_projs=True, ) self.data_type = data_type