summaryrefslogtreecommitdiffstats
path: root/Wrappers/Python
diff options
context:
space:
mode:
authorEdoardo Pasca <edo.paskino@gmail.com>2018-03-08 11:11:38 +0000
committerEdoardo Pasca <edo.paskino@gmail.com>2018-03-08 11:11:38 +0000
commit8b3c127facf22d99280257ab81428ce3d72cbd01 (patch)
tree6231cb0a2cf182e9eb26030b43a4a23dfa2b58db /Wrappers/Python
parent406b04e44435dee2b5980512ae484dd816e9332f (diff)
downloadframework-8b3c127facf22d99280257ab81428ce3d72cbd01.tar.gz
framework-8b3c127facf22d99280257ab81428ce3d72cbd01.tar.bz2
framework-8b3c127facf22d99280257ab81428ce3d72cbd01.tar.xz
framework-8b3c127facf22d99280257ab81428ce3d72cbd01.zip
moved files and use SinogramData/VolumeData and Geometries
Diffstat (limited to 'Wrappers/Python')
-rw-r--r--Wrappers/Python/wip/simple_demo.py4
-rwxr-xr-xWrappers/Python/wip/simple_mc_demo.py5
2 files changed, 5 insertions, 4 deletions
diff --git a/Wrappers/Python/wip/simple_demo.py b/Wrappers/Python/wip/simple_demo.py
index 1046e7b..a970b3e 100644
--- a/Wrappers/Python/wip/simple_demo.py
+++ b/Wrappers/Python/wip/simple_demo.py
@@ -13,7 +13,7 @@ from ccpi.reconstruction.geoms import *
import numpy as np
import matplotlib.pyplot as plt
-test_case = 2 # 1=parallel2D, 2=cone2D
+test_case = 1 # 1=parallel2D, 2=cone2D
# Set up phantom
N = 128
@@ -60,7 +60,7 @@ elif test_case==2:
dist_center_detector=OrigDetec)
# ASTRA operator using volume and sinogram geometries
-Aop = AstraProjectorSimple(vg, pg, 'gpu')
+Aop = AstraProjectorSimple(vg, pg, 'cpu')
# Unused old astra projector without geometry
# Aop_old = AstraProjector(det_w, det_num, SourceOrig,
diff --git a/Wrappers/Python/wip/simple_mc_demo.py b/Wrappers/Python/wip/simple_mc_demo.py
index 54c9134..beec717 100755
--- a/Wrappers/Python/wip/simple_mc_demo.py
+++ b/Wrappers/Python/wip/simple_mc_demo.py
@@ -4,12 +4,12 @@ import sys
sys.path.append("..")
-from ccpi.framework import *
+from ccpi.framework import VolumeData, SinogramData
from ccpi.reconstruction.algs import *
from ccpi.reconstruction.funcs import *
from ccpi.reconstruction.ops import *
from ccpi.reconstruction.astra_ops import *
-from ccpi.reconstruction.geoms import *
+from ccpi.reconstruction.geoms import VolumeGeometry, SinogramGeometry
import numpy
import matplotlib.pyplot as plt
@@ -89,6 +89,7 @@ elif test_case==2:
channels=numchannels)
# ASTRA operator using volume and sinogram geometries
+print("create Projector")
Aop = AstraProjectorMC(vg, pg, 'cpu')