3 #include <itkSingleValuedCostFunction.h> 4 #include <AnimaMCMSimilarityExport.h> 32 virtual MeasureType GetValue(const ParametersType ¶meters) const ITK_OVERRIDE;
33 virtual
void GetDerivative(const ParametersType ¶meters, DerivativeType &derivative) const ITK_OVERRIDE;
35 void SetReferenceModels(const
std::vector <MCMPointer> &refModels);
36 void SetMovingModels(const
std::vector <MCMPointer> &movingModels);
38 itkSetMacro(TensorsScale,
double)
39 itkSetMacro(LowPassGaussianSigma,
double)
41 unsigned int GetNumberOfParameters() const ITK_OVERRIDE {
return 1;}
46 m_UpdatedReferenceData =
false;
47 m_UpdatedMovingData =
false;
48 m_RecomputeConstantTerm =
true;
51 m_TensorsScale = 1000;
52 m_LowPassGaussianSigma = 2000;
57 void UpdateDeterminants()
const;
58 void ComputeMatrixTraces(
const TensorType &matrix,
double &matrixTrace,
double &squaredMatrixTrace)
const;
62 void operator=(
const Self&);
64 std::vector < std::vector <TensorType> > m_ReferenceModels;
65 std::vector < std::vector <double> > m_ReferenceModelWeights;
66 std::vector <double> m_ReferenceNumberOfIsotropicCompartments;
67 std::vector < std::vector <TensorType> > m_MovingModels;
68 std::vector < std::vector <double> > m_MovingModelWeights;
70 mutable std::vector < std::vector <double> > m_ReferenceReferenceDeterminants, m_ReferenceMovingDeterminants, m_MovingMovingDeterminants;
71 mutable std::vector < std::vector <double> > m_ReferenceReferenceTraces, m_ReferenceMovingTraces;
72 mutable std::vector < std::vector <double> > m_ReferenceReferenceTraceDifferences, m_ReferenceMovingTraceDifferences;
74 mutable bool m_UpdatedReferenceData;
75 mutable bool m_UpdatedMovingData;
76 mutable bool m_RecomputeConstantTerm;
78 mutable double m_ConstantTerm;
79 double m_TensorsScale;
80 double m_LowPassGaussianSigma;
itk::SingleValuedCostFunction Superclass
itk::SmartPointer< const Self > ConstPointer
itk::SmartPointer< Self > Pointer
MultiTensorSmoothingCostFunction Self
Superclass::ParametersType ParametersType
MultiTensorSmoothingCostFunction()
Superclass::MeasureType MeasureType
Superclass::DerivativeType DerivativeType
MultiCompartmentModel: holds several diffusion compartments, ordered by type It also handles weights ...
anima::BaseCompartment::Matrix3DType TensorType
virtual ~MultiTensorSmoothingCostFunction()
MCModelType::Pointer MCMPointer