From c409bd46a39357ca14b8ae48f6242700b1576396 Mon Sep 17 00:00:00 2001 From: algol Date: Tue, 10 Apr 2018 10:45:41 +0100 Subject: #43 all python/matlab 2d/3d DEMOS work OK --- Wrappers/Python/src/cpu_regularisers.pyx | 6 +++--- Wrappers/Python/src/gpu_regularisers.pyx | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) (limited to 'Wrappers/Python/src') diff --git a/Wrappers/Python/src/cpu_regularisers.pyx b/Wrappers/Python/src/cpu_regularisers.pyx index 248bad1..0f08f7f 100644 --- a/Wrappers/Python/src/cpu_regularisers.pyx +++ b/Wrappers/Python/src/cpu_regularisers.pyx @@ -48,8 +48,8 @@ def TV_ROF_2D(np.ndarray[np.float32_t, ndim=2, mode="c"] inputData, return outputData def TV_ROF_3D(np.ndarray[np.float32_t, ndim=3, mode="c"] inputData, - int iterationsNumb, float regularisation_parameter, + int iterationsNumb, float marching_step_parameter): cdef long dims[3] dims[0] = inputData.shape[0] @@ -60,7 +60,7 @@ def TV_ROF_3D(np.ndarray[np.float32_t, ndim=3, mode="c"] inputData, np.zeros([dims[0],dims[1],dims[2]], dtype='float32') # Run ROF iterations for 3D data - TV_ROF_CPU_main(&inputData[0,0,0], &outputData[0,0,0], regularisation_parameter, iterationsNumb, marching_step_parameter, dims[0], dims[1], dims[2]) + TV_ROF_CPU_main(&inputData[0,0,0], &outputData[0,0,0], regularisation_parameter, iterationsNumb, marching_step_parameter, dims[2], dims[1], dims[0]) return outputData @@ -122,5 +122,5 @@ def TV_FGP_3D(np.ndarray[np.float32_t, ndim=3, mode="c"] inputData, methodTV, nonneg, printM, - dims[0], dims[1], dims[2]) + dims[2], dims[1], dims[0]) return outputData diff --git a/Wrappers/Python/src/gpu_regularisers.pyx b/Wrappers/Python/src/gpu_regularisers.pyx index 7ebd011..ea746d3 100644 --- a/Wrappers/Python/src/gpu_regularisers.pyx +++ b/Wrappers/Python/src/gpu_regularisers.pyx @@ -106,7 +106,7 @@ def ROFTV3D(np.ndarray[np.float32_t, ndim=3, mode="c"] inputData, regularisation_parameter, iterations , time_marching_parameter, - dims[0], dims[1], dims[2]); + dims[2], dims[1], dims[0]); return outputData #****************************************************************# @@ -165,6 +165,6 @@ def FGPTV3D(np.ndarray[np.float32_t, ndim=3, mode="c"] inputData, methodTV, nonneg, printM, - dims[0], dims[1], dims[2]); + dims[2], dims[1], dims[0]); return outputData -- cgit v1.2.3