Skip to content

Commit 386ac6f

Browse files
committed
tried playing with the parameter declaration…
1 parent c2f4507 commit 386ac6f

9 files changed

+218
-181
lines changed

src/Core/Algorithms/Legacy/Inverse/SolveInverseProblemWithTikhonovImpl_child.cc

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -85,11 +85,11 @@ using namespace SCIRun::Core::Algorithms::Inverse;
8585

8686
solution = M3 * b;
8787

88-
if (inverseCalculation)
89-
{
90-
inverseG = G.inverse().eval();
91-
inverseMatrix_.reset( new DenseMatrix( (M3 * inverseG) * M4) );
92-
}
88+
// if (inverseCalculation)
89+
// {
90+
// inverseG = G.inverse().eval();
91+
// inverseMatrix_.reset( new DenseMatrix( (M3 * inverseG) * M4) );
92+
// }
9393
// inverseSolution_.reset(new DenseMatrix(solution));
9494
return solution;
9595
}

src/Core/Algorithms/Legacy/Inverse/SolveInverseProblemWithTikhonovImpl_child.h

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -52,11 +52,7 @@ namespace SCIRun {
5252
{
5353

5454
public:
55-
SolveInverseProblemWithTikhonovImpl_child() : TikhonovAlgoAbstractBase()
56-
{
57-
// prealocate matrices needed for computation
58-
preAlocateInverseMatrices();
59-
};
55+
SolveInverseProblemWithTikhonovImpl_child() {};
6056

6157
private:
6258

src/Core/Algorithms/Legacy/Inverse/SolveInverseProblemWithTikhonovSVD_impl.cc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@
4545
#include <Core/Utils/Exception.h>
4646

4747
// Tikhonov inverse libraries
48-
#include <Core/Algorithms/Legacy/Inverse/TikhonovAlgoAbstractBase.h>
48+
// #include <Core/Algorithms/Legacy/Inverse/TikhonovAlgoAbstractBase.h>
4949
// #include <Modules/Legacy/Inverse/SolveInverseProblemWithTikhonovSVD.h>
5050
#include <Core/Algorithms/Legacy/Inverse/SolveInverseProblemWithTikhonovSVD_impl.h>
5151

@@ -121,8 +121,8 @@ SCIRun::Core::Datatypes::DenseColumnMatrix SolveInverseProblemWithTikhonovSVD_im
121121
}
122122

123123
// output solutions
124-
if (inverseCalculation)
125-
inverseMatrix_.reset( new SCIRun::Core::Datatypes::DenseMatrix(tempInverse) );
124+
// if (inverseCalculation)
125+
// inverseMatrix_.reset( new SCIRun::Core::Datatypes::DenseMatrix(tempInverse) );
126126

127127
return solution;
128128
}

src/Core/Algorithms/Legacy/Inverse/SolveInverseProblemWithTikhonovSVD_impl.h

Lines changed: 24 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -48,46 +48,39 @@
4848
#include <Core/Algorithms/Legacy/Inverse/share.h>
4949

5050

51-
namespace SCIRun
52-
{
53-
namespace Core
54-
{
55-
namespace Algorithms
56-
{
57-
namespace Inverse
58-
{
51+
namespace SCIRun {
52+
namespace Core {
53+
namespace Algorithms {
54+
namespace Inverse {
5955

60-
class SCISHARE SolveInverseProblemWithTikhonovSVD_impl : public TikhonovAlgoAbstractBase
61-
{
56+
class SCISHARE SolveInverseProblemWithTikhonovSVD_impl : public TikhonovAlgoAbstractBase
57+
{
6258

6359

64-
public:
65-
SolveInverseProblemWithTikhonovSVD_impl() : TikhonovAlgoAbstractBase()
66-
{
67-
rank = 0;
68-
};
60+
public:
61+
SolveInverseProblemWithTikhonovSVD_impl()
62+
{
63+
rank = 0;
64+
};
6965

7066

71-
private:
67+
private:
7268

73-
int rank;
74-
Eigen::JacobiSVD<SCIRun::Core::Datatypes::DenseMatrix::EigenBase> SVDdecomposition;
75-
// const SCIRun::Core::Datatypes::DenseMatrix matrixU_;
76-
// const SCIRun::Core::Datatypes::DenseColumnMatrix matrixS_;
77-
// const SCIRun::Core::Datatypes::DenseMatrix matrixV_;
78-
// SCIRun::Core::Datatypes::DenseMatrix y;
79-
SCIRun::Core::Datatypes::DenseColumnMatrix Uy;
69+
int rank;
70+
Eigen::JacobiSVD<SCIRun::Core::Datatypes::DenseMatrix::EigenBase> SVDdecomposition;
71+
// const SCIRun::Core::Datatypes::DenseMatrix matrixU_;
72+
// const SCIRun::Core::Datatypes::DenseColumnMatrix matrixS_;
73+
// const SCIRun::Core::Datatypes::DenseMatrix matrixV_;
74+
// SCIRun::Core::Datatypes::DenseMatrix y;
75+
SCIRun::Core::Datatypes::DenseColumnMatrix Uy;
8076

8177

82-
SCIRun::Core::Datatypes::DenseColumnMatrix computeInverseSolution( double lambda_sq, bool inverseCalculation);
83-
void preAlocateInverseMatrices(SCIRun::Core::Datatypes::DenseMatrix& forwardMatrix_,SCIRun::Core::Datatypes::DenseMatrix& measuredData_ ,SCIRun::Core::Datatypes::DenseMatrix& sourceWeighting_,SCIRun::Core::Datatypes::DenseMatrix& sensorWeighting_);
84-
// bool checkInputMatrixSizes(); // DEFINED IN PARENT, MIGHT WANT TO OVERRIDE SOME OTHER TIME
78+
SCIRun::Core::Datatypes::DenseColumnMatrix computeInverseSolution( double lambda_sq, bool inverseCalculation);
79+
void preAlocateInverseMatrices(SCIRun::Core::Datatypes::DenseMatrix& forwardMatrix_,SCIRun::Core::Datatypes::DenseMatrix& measuredData_ ,SCIRun::Core::Datatypes::DenseMatrix& sourceWeighting_,SCIRun::Core::Datatypes::DenseMatrix& sensorWeighting_);
80+
// bool checkInputMatrixSizes(); // DEFINED IN PARENT, MIGHT WANT TO OVERRIDE SOME OTHER TIME
8581

8682

87-
};
88-
}
89-
}
90-
}
91-
}
83+
};
84+
}}}}
9285

9386
#endif

0 commit comments

Comments
 (0)