From 808df464502aa0ca7aac88574ed95b4e6fc192bb Mon Sep 17 00:00:00 2001 From: "Matthias J. Ehrhardt" Date: Wed, 14 Feb 2018 09:31:55 +0000 Subject: [PATCH] Improve saving of data --- odl/contrib/solvers/spdhg/examples/PET_1k.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/odl/contrib/solvers/spdhg/examples/PET_1k.py b/odl/contrib/solvers/spdhg/examples/PET_1k.py index 63a038c5391..1d6b87a60cb 100644 --- a/odl/contrib/solvers/spdhg/examples/PET_1k.py +++ b/odl/contrib/solvers/spdhg/examples/PET_1k.py @@ -100,8 +100,12 @@ data = odl.phantom.poisson_noise(factors * sinogram + background, seed=1807) - np.save(file_data, (data, factors, background)) - np.save(file_data, (data, factors, background)) + arr = np.empty(3, dtype=object) + arr[0] = data + arr[1] = factors + arr[2] = background + np.save(file_data, arr) +# np.save(file_data, (data, factors, background)) fig1 = plt.figure(1) groundtruth.show('groundtruth', clim=clim, fig=fig1)