Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-02-14 14:31:39

0001 #ifndef Chi2Switching1DEstimator_H_
0002 #define Chi2Switching1DEstimator_H_
0003 
0004 /** \class Chi2Switching1DEstimator
0005  *  A measurement estimator that uses Chi2MeasurementEstimator for
0006  *  pixel and matched strip hits, and Chi2Strip1DEstimator for
0007  *  simple strip hits. Ported from ORCA.
0008  *
0009  *  \author todorov, cerati
0010  */
0011 
0012 #include "TrackingTools/DetLayers/interface/MeasurementEstimator.h"
0013 #include "TrackingTools/KalmanUpdators/interface/Chi2MeasurementEstimator.h"
0014 #include "TrackingTools/KalmanUpdators/interface/Chi2Strip1DEstimator.h"
0015 #include "DataFormats/GeometryCommonDetAlgo/interface/DeepCopyPointerByClone.h"
0016 
0017 class Chi2Switching1DEstimator final : public Chi2MeasurementEstimatorBase {
0018 public:
0019   explicit Chi2Switching1DEstimator(double aMaxChi2, double nSigma = 3.)
0020       : Chi2MeasurementEstimatorBase(aMaxChi2, nSigma),
0021         theLocalEstimator(aMaxChi2, nSigma),
0022         theStripEstimator(aMaxChi2, nSigma) {}
0023 
0024   /// implementation of MeasurementEstimator::estimate
0025   std::pair<bool, double> estimate(const TrajectoryStateOnSurface& aTsos, const TrackingRecHit& aHit) const override;
0026 
0027   Chi2Switching1DEstimator* clone() const override { return new Chi2Switching1DEstimator(*this); }
0028 
0029 private:
0030   /// estimator for 2D hits (matched or pixel)
0031   const Chi2MeasurementEstimator& localEstimator() const { return theLocalEstimator; }
0032   /// estimator for 1D hits (non-matched strips)
0033   const Chi2Strip1DEstimator& stripEstimator() const { return theStripEstimator; }
0034 
0035 private:
0036   const Chi2MeasurementEstimator theLocalEstimator;
0037   const Chi2Strip1DEstimator theStripEstimator;
0038 };
0039 #endif  //Chi2Switching1DEstimator_H_