| 246 | } |
| 247 | |
| 248 | astra::CFloat32VolumeData2D* getDLTensor(PyObject *obj, const astra::CVolumeGeometry2D &pGeom, std::string &error) |
| 249 | { |
| 250 | if (!PyCapsule_CheckExact(obj)) |
| 251 | return nullptr; |
| 252 | |
| 253 | // x,y,z |
| 254 | std::array<int, 2> dims{pGeom.getGridColCount(), pGeom.getGridRowCount()}; |
| 255 | |
| 256 | astra::CDataStorage *storage = getDLTensorStorage(obj, dims, error); |
| 257 | if (!storage) |
| 258 | return nullptr; |
| 259 | |
| 260 | return new astra::CFloat32VolumeData2D(pGeom, storage); |
| 261 | } |
| 262 | astra::CFloat32ProjectionData2D* getDLTensor(PyObject *obj, const astra::CProjectionGeometry2D &pGeom, std::string &error) |
| 263 | { |
| 264 | if (!PyCapsule_CheckExact(obj)) |
nothing calls this directly
no test coverage detected