Commit 9ba6e7e2 authored by Cédric Traizet's avatar Cédric Traizet

ENH: add background value handling for stat estimation in mnf/napca

parent 9ca8aee7
......@@ -348,6 +348,11 @@ private:
filter->SetUseNormalization(normalize);
filter->GetNoiseImageFilter()->SetRadius(radius);
if( HasValue( "bv" ) )
{
filter->SetStatisticsUserIgnoredValue(GetParameterFloat("bv"));
}
m_ForwardFilter->GetOutput()->UpdateOutputInformation();
if (invTransform)
......
......@@ -145,6 +145,19 @@ public:
m_IsTransformationMatrixForward = isForward;
}
void SetStatisticsUserIgnoredValue ( RealType value )
{
/** User ignored value for the normalizer */
m_Normalizer->GetCovarianceEstimator()->SetUserIgnoredValue(value);
m_Normalizer->GetCovarianceEstimator()->SetIgnoreUserDefinedValue(true);
/** User ignored value for the covariance estimator */
m_CovarianceEstimator->SetUserIgnoredValue(value);
m_CovarianceEstimator->SetIgnoreUserDefinedValue(true);
/** User ignored value for the noise covariance estimator */
m_NoiseCovarianceEstimator->SetUserIgnoredValue(value);
m_NoiseCovarianceEstimator->SetIgnoreUserDefinedValue(true);
}
itkGetConstMacro(EigenValues, VectorType);
protected:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment