diff options
author | Willem Jan Palenstijn <Willem.Jan.Palenstijn@cwi.nl> | 2017-02-08 10:43:35 +0100 |
---|---|---|
committer | Willem Jan Palenstijn <Willem.Jan.Palenstijn@cwi.nl> | 2017-02-08 14:39:00 +0100 |
commit | ebd5fe932fd2d6c4a516bc1cdc69e37aa4f5cf55 (patch) | |
tree | a1e6c2bc3413e5a06d1e6d77a13dc2c2c9146421 /python/astra/data3d_c.pyx | |
parent | 1d851f0a8fa093e044c7264569cc6f88df39a16e (diff) | |
download | astra-ebd5fe932fd2d6c4a516bc1cdc69e37aa4f5cf55.tar.gz astra-ebd5fe932fd2d6c4a516bc1cdc69e37aa4f5cf55.tar.bz2 astra-ebd5fe932fd2d6c4a516bc1cdc69e37aa4f5cf55.tar.xz astra-ebd5fe932fd2d6c4a516bc1cdc69e37aa4f5cf55.zip |
Make python -sinocone a synonym of -sino.
The matlab interface already behaves like this.
Diffstat (limited to 'python/astra/data3d_c.pyx')
-rw-r--r-- | python/astra/data3d_c.pyx | 14 |
1 files changed, 1 insertions, 13 deletions
diff --git a/python/astra/data3d_c.pyx b/python/astra/data3d_c.pyx index 1b9293a..3934f22 100644 --- a/python/astra/data3d_c.pyx +++ b/python/astra/data3d_c.pyx @@ -86,7 +86,7 @@ def create(datatype,geometry,data=None, link=False): pDataObject3D = <CFloat32Data3DMemory * > new CFloat32VolumeData3DMemory(pGeometry) del cfg del pGeometry - elif datatype == '-sino' or datatype == '-proj3d': + elif datatype == '-sino' or datatype == '-proj3d' or datatype == '-sinocone': cfg = utils.dictToConfig(six.b('ProjectionGeometry'), geometry) tpe = wrap_from_bytes(cfg.self.getAttribute(six.b('type'))) if (tpe == "parallel3d"): @@ -111,18 +111,6 @@ def create(datatype,geometry,data=None, link=False): pDataObject3D = <CFloat32Data3DMemory * > new CFloat32ProjectionData3DMemory(ppGeometry) del ppGeometry del cfg - elif datatype == "-sinocone": - cfg = utils.dictToConfig(six.b('ProjectionGeometry'), geometry) - pppGeometry = new CConeProjectionGeometry3D() - if not pppGeometry.initialize(cfg[0]): - del cfg - del pppGeometry - raise Exception('Geometry class not initialized.') - if link: - pCustom = <CFloat32CustomMemory*> new CFloat32CustomPython(data) - pDataObject3D = <CFloat32Data3DMemory * > new CFloat32ProjectionData3DMemory(pppGeometry, pCustom) - else: - pDataObject3D = <CFloat32Data3DMemory * > new CFloat32ProjectionData3DMemory(pppGeometry) else: raise Exception("Invalid datatype. Please specify '-vol' or '-proj3d'.") |