summaryrefslogtreecommitdiffstats
path: root/python/astra/experimental.pyx
diff options
context:
space:
mode:
authorWillem Jan Palenstijn <Willem.Jan.Palenstijn@cwi.nl>2017-01-26 14:57:57 +0100
committerWillem Jan Palenstijn <Willem.Jan.Palenstijn@cwi.nl>2017-02-08 14:39:01 +0100
commitd85a660f064e8130b27e11c7fd762221c754c315 (patch)
tree72382e8414c8dc51a7a7ef45845b4c61b25dfed9 /python/astra/experimental.pyx
parentebd5fe932fd2d6c4a516bc1cdc69e37aa4f5cf55 (diff)
downloadastra-d85a660f064e8130b27e11c7fd762221c754c315.tar.gz
astra-d85a660f064e8130b27e11c7fd762221c754c315.tar.bz2
astra-d85a660f064e8130b27e11c7fd762221c754c315.tar.xz
astra-d85a660f064e8130b27e11c7fd762221c754c315.zip
Start work on CFloat32Data3DGPU to allow persistent/external GPU memory
Diffstat (limited to 'python/astra/experimental.pyx')
-rw-r--r--python/astra/experimental.pyx24
1 files changed, 16 insertions, 8 deletions
diff --git a/python/astra/experimental.pyx b/python/astra/experimental.pyx
index b6c7881..0af3118 100644
--- a/python/astra/experimental.pyx
+++ b/python/astra/experimental.pyx
@@ -36,12 +36,20 @@ IF HAVE_CUDA==True:
cdef extern from "astra/CompositeGeometryManager.h" namespace "astra":
cdef cppclass CCompositeGeometryManager:
- bool doFP(CProjector3D *, vector[CFloat32VolumeData3DMemory *], vector[CFloat32ProjectionData3DMemory *])
- bool doBP(CProjector3D *, vector[CFloat32VolumeData3DMemory *], vector[CFloat32ProjectionData3DMemory *])
+ bool doFP(CProjector3D *, vector[CFloat32VolumeData3D *], vector[CFloat32ProjectionData3D *])
+ bool doBP(CProjector3D *, vector[CFloat32VolumeData3D *], vector[CFloat32ProjectionData3D *])
cdef extern from *:
- CFloat32VolumeData3DMemory * dynamic_cast_vol_mem "dynamic_cast<astra::CFloat32VolumeData3DMemory*>" (CFloat32Data3D * ) except NULL
- CFloat32ProjectionData3DMemory * dynamic_cast_proj_mem "dynamic_cast<astra::CFloat32ProjectionData3DMemory*>" (CFloat32Data3D * ) except NULL
+ CFloat32VolumeData3D * dynamic_cast_vol_mem "dynamic_cast<astra::CFloat32VolumeData3D*>" (CFloat32Data3D * ) except NULL
+ CFloat32ProjectionData3D * dynamic_cast_proj_mem "dynamic_cast<astra::CFloat32ProjectionData3D*>" (CFloat32Data3D * ) except NULL
+
+ cdef extern from "astra/Float32ProjectionData3D.h" namespace "astra":
+ cdef cppclass CFloat32ProjectionData3D:
+ bool isInitialized()
+ cdef extern from "astra/Float32VolumeData3D.h" namespace "astra":
+ cdef cppclass CFloat32VolumeData3D:
+ bool isInitialized()
+
cimport PyProjector3DManager
from .PyProjector3DManager cimport CProjector3DManager
@@ -52,9 +60,9 @@ IF HAVE_CUDA==True:
cdef CData3DManager * man3d = <CData3DManager * >PyData3DManager.getSingletonPtr()
def do_composite(projector_id, vol_ids, proj_ids, t):
- cdef vector[CFloat32VolumeData3DMemory *] vol
- cdef CFloat32VolumeData3DMemory * pVolObject
- cdef CFloat32ProjectionData3DMemory * pProjObject
+ cdef vector[CFloat32VolumeData3D *] vol
+ cdef CFloat32VolumeData3D * pVolObject
+ cdef CFloat32ProjectionData3D * pProjObject
for v in vol_ids:
pVolObject = dynamic_cast_vol_mem(man3d.get(v))
if pVolObject == NULL:
@@ -62,7 +70,7 @@ IF HAVE_CUDA==True:
if not pVolObject.isInitialized():
raise Exception("Data object not initialized properly")
vol.push_back(pVolObject)
- cdef vector[CFloat32ProjectionData3DMemory *] proj
+ cdef vector[CFloat32ProjectionData3D *] proj
for v in proj_ids:
pProjObject = dynamic_cast_proj_mem(man3d.get(v))
if pProjObject == NULL: