diff --git a/examples/scripts/ct_projector_comparison.py b/examples/scripts/ct_projector_comparison.py index ab8c43cfa..eba3d8822 100644 --- a/examples/scripts/ct_projector_comparison.py +++ b/examples/scripts/ct_projector_comparison.py @@ -21,7 +21,7 @@ from xdesign import Foam, discrete_phantom from scico import plot -from scico.linop import ParallelFixedAxis2dProjector, XRayProject +from scico.linop import ParallelFixedAxis2dProjector, XRayTransform from scico.linop.radon_astra import TomographicProjector from scico.util import Timer @@ -49,7 +49,7 @@ projectors = {} timer.start("scico_init") -projectors["scico"] = XRayProject(ParallelFixedAxis2dProjector((N, N), angles)) +projectors["scico"] = XRayTransform(ParallelFixedAxis2dProjector((N, N), angles)) timer.stop("scico_init") timer.start("astra_init") @@ -93,7 +93,7 @@ 10% slower when both are run the CPU. On our server, using the GPU: -``` +``` Label Accum. Current ------------------------------------------- astra_avg_proj 4.62e-02 s Stopped diff --git a/scico/linop/__init__.py b/scico/linop/__init__.py index 0c14de950..4751d76a2 100644 --- a/scico/linop/__init__.py +++ b/scico/linop/__init__.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright (C) 2021-2022 by SCICO Developers +# Copyright (C) 2021-2023 by SCICO Developers # All rights reserved. BSD 3-clause License. # This file is part of the SCICO package. Details of the copyright and # user license can be found in the 'LICENSE' file distributed with the @@ -19,7 +19,7 @@ from ._matrix import MatrixOperator from ._stack import DiagonalStack, VerticalStack from ._util import jacobian, operator_norm, power_iteration, valid_adjoint -from ._xray import ParallelFixedAxis2dProjector, XRayProject +from ._xray import ParallelFixedAxis2dProjector, XRayTransform __all__ = [ "CircularConvolve", @@ -39,7 +39,7 @@ "Sum", "Transpose", "LinearOperator", - "XRayProject", + "XRayTransform", "ParallelFixedAxis2dProjector", "ComposedLinearOperator", "linop_from_function", diff --git a/scico/linop/_xray.py b/scico/linop/_xray.py index 7704d4bdc..520cfb446 100644 --- a/scico/linop/_xray.py +++ b/scico/linop/_xray.py @@ -23,7 +23,7 @@ from ._linop import LinearOperator -class XRayProject(LinearOperator): +class XRayTransform(LinearOperator): """X-ray projection operator. Wraps an X-ray projector object in a SCICO diff --git a/scico/test/linop/test_xray.py b/scico/test/linop/test_xray.py index 7733158dd..752a27927 100644 --- a/scico/test/linop/test_xray.py +++ b/scico/test/linop/test_xray.py @@ -1,6 +1,6 @@ import jax.numpy as jnp -from scico.linop import ParallelFixedAxis2dProjector, XRayProject +from scico.linop import ParallelFixedAxis2dProjector, XRayTransform def test_apply(): @@ -11,16 +11,16 @@ def test_apply(): angles = jnp.linspace(0, jnp.pi, num=num_angles, endpoint=False) # general projection - H = XRayProject(ParallelFixedAxis2dProjector(x.shape, angles)) + H = XRayTransform(ParallelFixedAxis2dProjector(x.shape, angles)) y = H @ x assert y.shape[0] == (num_angles) # fixed det_length det_length = 14 - H = XRayProject(ParallelFixedAxis2dProjector(x.shape, angles, det_length=det_length)) + H = XRayTransform(ParallelFixedAxis2dProjector(x.shape, angles, det_length=det_length)) y = H @ x assert y.shape[1] == det_length # dither off - H = XRayProject(ParallelFixedAxis2dProjector(x.shape, angles, do_dithering=False)) + H = XRayTransform(ParallelFixedAxis2dProjector(x.shape, angles, do_dithering=False)) y = H @ x