-
Notifications
You must be signed in to change notification settings - Fork 45
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CIL for MacOS (ARM) with astra-2.2.0 CPU #1973
base: master
Are you sure you want to change the base?
Conversation
There is a problem with numpy>=2.0. Running test_PluginsAstra_CPU.py, we get In the code below, dtype changes from float32 to float64. With numpy 2.0:
returns
with
Running again all the tests with numpy 1.26, there is no error about dtypes, but there are errors (expected) with libcilacc.
There are also some precision errors:
But also one Astra error
|
Maybe the
However, according to numpy's docs for both 1.26 and 2.0
@epapoutsellis can you please test the following: from cil.framework import AcquisitionGeometry
from cil.utilities.dataexample import SIMULATED_CONE_BEAM_DATA, SIMULATED_PARALLEL_BEAM_DATA
from cil.utilities.display import show2D
from cil.plugins.astra import ProjectionOperator
import numpy as np
data = SIMULATED_CONE_BEAM_DATA.get()
print (f"Orig data dtype {data.array.dtype} {data.dtype} {data.geometry.dtype}")
data.log(out=data)
print (f"Log dtype {data.array.dtype} {data.dtype} {data.geometry.dtype}")
data *=-1
print (f"Minus 1 dtype {data.array.dtype} {data.dtype} {data.geometry.dtype}")
axis = data.dimension_labels_list.index("vertical")
slicearr = np.take(data.array, axis=axis, indices=0)
print (f"numpy take {slicearr.dtype}")
data2D = data.get_slice(vertical=0)
print(data2D.dtype) |
Description
No Tigre, no Ipp, no ccpi-regularisation toolkit
Related #1916
Example Usage
❤️ Thanks for your contribution!