diff options
author | Edoardo Pasca <edo.paskino@gmail.com> | 2017-10-27 12:39:59 +0100 |
---|---|---|
committer | Edoardo Pasca <edo.paskino@gmail.com> | 2018-01-19 14:26:06 +0000 |
commit | 34e00beb5c35068083fc4ecd5da5b93a504d62bf (patch) | |
tree | 165eecfedbe838199abb2617d5726ccef814b3c6 /src | |
parent | 647615fcce844907bcbe2a774ae3686863aa2d5d (diff) | |
download | regularization-34e00beb5c35068083fc4ecd5da5b93a504d62bf.tar.gz regularization-34e00beb5c35068083fc4ecd5da5b93a504d62bf.tar.bz2 regularization-34e00beb5c35068083fc4ecd5da5b93a504d62bf.tar.xz regularization-34e00beb5c35068083fc4ecd5da5b93a504d62bf.zip |
initializes R3
Bugfix, R2 was initialized twice, R3 never.
Diffstat (limited to 'src')
-rw-r--r-- | src/Python/fista_module.cpp | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/src/Python/fista_module.cpp b/src/Python/fista_module.cpp index aca3be0..f3add76 100644 --- a/src/Python/fista_module.cpp +++ b/src/Python/fista_module.cpp @@ -328,7 +328,6 @@ bp::list FGP_TV(np::ndarray input, double d_mu, int iter, double d_epsil, int me else { dim_array[2] = input.shape(2); } - // Parameter handling is be done in Python ///*Handling Matlab input data*/ //if ((nrhs < 2) || (nrhs > 5)) mexErrMsgTxt("At least 2 parameters is required: Image(2D/3D), Regularization parameter. The full list of parameters: Image(2D/3D), Regularization parameter, iterations number, tolerance, penalty type ('iso' or 'l1')"); @@ -513,13 +512,11 @@ bp::list FGP_TV(np::ndarray input, double d_mu, int iter, double d_epsil, int me P3_old = reinterpret_cast<float *>(npP3_old.get_data()); R1 = reinterpret_cast<float *>(npR1.get_data()); R2 = reinterpret_cast<float *>(npR2.get_data()); - R2 = reinterpret_cast<float *>(npR3.get_data()); + R3 = reinterpret_cast<float *>(npR3.get_data()); /* begin iterations */ for (ll = 0; ll<iter; ll++) { - /* computing the gradient of the objective function */ Obj_func3D(A, D, R1, R2, R3, lambda, dimX, dimY, dimZ); - /*Taking a step towards minus of the gradient*/ Grad_func3D(P1, P2, P3, D, R1, R2, R3, lambda, dimX, dimY, dimZ); |