npstat is hosted by Hepforge, IPPP Durham
NPStat  5.10.0
npstat::SmoothedEMUnfoldND Class Reference
Inheritance diagram for npstat::SmoothedEMUnfoldND:
npstat::AbsUnfoldND

Public Types

typedef AbsUnfoldND Base
 
- Public Types inherited from npstat::AbsUnfoldND
typedef ResponseMatrix response_matrix_type
 
typedef Matrix< double > input_covariance_type
 
typedef Matrix< double > output_covariance_type
 
typedef AbsUnfoldingFilterND filter_type
 

Public Member Functions

 SmoothedEMUnfoldND (const ResponseMatrix &responseMatrix, const AbsUnfoldingFilterND &filter, bool useConvolutions, bool useMultinomialCovariance=false, bool smoothLastIter=true, double convergenceEpsilon=1.0e-10, unsigned maxIterations=100000U)
 
void setMaxIterations (const unsigned u)
 
void useMultinomialCovariance (const bool b)
 
void smoothLastIteration (const bool b)
 
void setConvergenceEpsilon (double eps)
 
double convergenceEpsilon () const
 
unsigned maxIterations () const
 
bool usingMultinomialCovariance () const
 
bool smoothingLastIteration () const
 
unsigned lastNIterations () const
 
unsigned lastEPIterations () const
 
double lastSmoothingNormfactor () const
 
virtual bool unfold (const ArrayND< double > &observed, const Matrix< double > *observationCovarianceMatrix, ArrayND< double > *unfolded, Matrix< double > *unfoldedCovarianceMatrix)
 
- Public Member Functions inherited from npstat::AbsUnfoldND
 AbsUnfoldND (const ResponseMatrix &responseMatrix)
 
const ResponseMatrixresponseMatrix () const
 
const ArrayND< double > & efficiency () const
 
virtual void setInitialApproximation (const ArrayND< double > &approx)
 
virtual void clearInitialApproximation ()
 
virtual const ArrayND< double > & getInitialApproximation () const
 
virtual void setFilter (const AbsUnfoldingFilterND *f)
 
virtual const AbsUnfoldingFilterNDgetFilter (bool throwIfNull=false) const
 
virtual void useConvolutions (const bool b)
 
bool usingConvolutions () const
 
ArrayShape getObservedShape () const
 
ArrayShape getUnfoldedShape () const
 
void validateUnfoldedShape (const ArrayND< double > &unfolded) const
 
void validateUnfoldedShape (const ArrayShape &unfoldedShape) const
 
void validateObservedShape (const ArrayND< double > &observed) const
 
void validateObservedShape (const ArrayShape &observedShape) const
 

Protected Member Functions

void update (const ArrayND< double > &observed, const ArrayND< double > *prev, ArrayND< double > *next, bool performSmoothing) const
 
- Protected Member Functions inherited from npstat::AbsUnfoldND
void buildUniformInitialApproximation (const ArrayND< double > &observed, ArrayND< double > *result) const
 

Additional Inherited Members

- Static Public Member Functions inherited from npstat::AbsUnfoldND
static double probDelta (const ArrayND< double > &prev, const ArrayND< double > &next)
 

Constructor & Destructor Documentation

◆ SmoothedEMUnfoldND()

npstat::SmoothedEMUnfoldND::SmoothedEMUnfoldND ( const ResponseMatrix responseMatrix,
const AbsUnfoldingFilterND filter,
bool  useConvolutions,
bool  useMultinomialCovariance = false,
bool  smoothLastIter = true,
double  convergenceEpsilon = 1.0e-10,
unsigned  maxIterations = 100000U 
)

The constructor arguments are:

responseMatrix – Naturally, the problem response matrix.

filter – The filter to use for smoothing the unfolded values. This object will not make a copy of the filter. It is the responsibility of the caller to ensure that the argument filter exists while this object is in use.

useConvolutions – If "true", the code will call the "convolve" method of the filter rather than its "filter" method.

useMultinomialCovariance – Specifies whether we should use multinomial distribution to estimate covariance of fitted observations (otherwise Poisson assumption is used).

smoothLastIter – If "false", smoothing will not be applied after the last iteration. Setting this parameter to "false" is not recommended for production results because it is unclear how to compare such results with models.

convergenceEpsilon – Convergence criterion parameter for various iterations.

maxIterations – Maximum number of iterations allowed (both for the expectation-maximization iterations and for the code estimating the error propagation matrix).

Member Function Documentation

◆ convergenceEpsilon()

double npstat::SmoothedEMUnfoldND::convergenceEpsilon ( ) const
inline

Simple inspector of object properties

◆ lastEPIterations()

unsigned npstat::SmoothedEMUnfoldND::lastEPIterations ( ) const
inline

The last number of iterations used to calculate the error propagation matrix

◆ lastNIterations()

unsigned npstat::SmoothedEMUnfoldND::lastNIterations ( ) const
inline

Returns the last number of iterations used to calculate the unfolded results. This number will be filled after each "unfold" call.

◆ lastSmoothingNormfactor()

double npstat::SmoothedEMUnfoldND::lastSmoothingNormfactor ( ) const
inline

The normalization factor applied during the last smoothing step

◆ setConvergenceEpsilon()

void npstat::SmoothedEMUnfoldND::setConvergenceEpsilon ( double  eps)

Change the convergence criterion

◆ setMaxIterations()

void npstat::SmoothedEMUnfoldND::setMaxIterations ( const unsigned  u)
inline

Change maximum number of allowed iterations

◆ smoothLastIteration()

void npstat::SmoothedEMUnfoldND::smoothLastIteration ( const bool  b)
inline

Switch between smoothing/not smoothing the last iteration

◆ unfold()

virtual bool npstat::SmoothedEMUnfoldND::unfold ( const ArrayND< double > &  observed,
const Matrix< double > *  observationCovarianceMatrix,
ArrayND< double > *  unfolded,
Matrix< double > *  unfoldedCovarianceMatrix 
)
virtual

The main unfolding method

Implements npstat::AbsUnfoldND.

◆ update()

void npstat::SmoothedEMUnfoldND::update ( const ArrayND< double > &  observed,
const ArrayND< double > *  prev,
ArrayND< double > *  next,
bool  performSmoothing 
) const
protected

Single expectation-maximization (a.k.a. D'Agostini) iteration

◆ useMultinomialCovariance()

void npstat::SmoothedEMUnfoldND::useMultinomialCovariance ( const bool  b)
inline

Switch between multinomial/Poisson covariance for observed space


The documentation for this class was generated from the following file: