19 #ifndef rtkSchlomka2008NegativeLogLikelihood_h 20 #define rtkSchlomka2008NegativeLogLikelihood_h 59 #ifdef itkOverrideGetNameOfClassMacro 105 vnl_vector<double> attenuationFactors;
108 vnl_vector<double> lambdas =
ForwardModel(lineIntegrals);
111 vnl_vector<double> weights;
117 vnl_vector<double> intermediate_a;
118 vnl_vector<double> partial_derivative_a;
127 derivatives[a] = dot_product(partial_derivative_a, weights);
138 long double measure = 0;
141 measure += forward[i] - std::log((
long double)forward[i]) *
m_MeasuredData[i];
149 vnl_vector<double> attenuationFactors;
152 vnl_vector<double> lambdas =
ForwardModel(lineIntegrals);
155 vnl_vector<double> weights;
161 vnl_vector<double> intermediate_a;
162 vnl_vector<double> intermediate_a_prime;
163 vnl_vector<double> partial_derivative_a;
164 vnl_vector<double> partial_derivative_a_prime;
180 partial_derivative_a_prime = element_product(partial_derivative_a, partial_derivative_a_prime);
181 m_Fischer[a][a_prime] = dot_product(partial_derivative_a_prime, weights);
virtual vnl_vector< double > ForwardModel(const ParametersType &lineIntegrals) const
MaterialAttenuationsType m_MaterialAttenuations
unsigned int m_NumberOfEnergies
Superclass::ParametersType ParametersType
unsigned int m_NumberOfSpectralBins
void ComputeFischerMatrix(const ParametersType &lineIntegrals) override
void GetAttenuationFactors(const ParametersType &lineIntegrals, vnl_vector< double > &attenuationFactors) const
MeasuredDataType m_MeasuredData
Schlomka2008NegativeLogLikelihood()
Superclass::DerivativeType DerivativeType
IncidentSpectrumType m_IncidentSpectrum
vnl_matrix< float > IncidentSpectrumType
itk::VariableSizeMatrix< float > m_Fischer
Superclass::MeasureType MeasureType
void GetDerivative(const ParametersType &lineIntegrals, DerivativeType &derivatives) const override
MeasureType GetValue(const ParametersType ¶meters) const override
~Schlomka2008NegativeLogLikelihood() override=default
vnl_matrix< double > MaterialAttenuationsType
DetectorResponseType m_DetectorResponse
void Initialize() override
Superclass::MeasureType MeasureType
unsigned int m_NumberOfMaterials
vnl_matrix< double > m_IncidentSpectrumAndDetectorResponseProduct
itk::VariableLengthVector< double > MeasuredDataType
vnl_matrix< double > DetectorResponseType