CMS 3D CMS Logo

Public Member Functions | Private Attributes

GsfTrajectorySmootherESProducer Class Reference

#include <GsfTrajectorySmootherESProducer.h>

Inheritance diagram for GsfTrajectorySmootherESProducer:
edm::ESProducer edm::ESProxyFactoryProducer edm::eventsetup::DataProxyProvider

List of all members.

Public Member Functions

 GsfTrajectorySmootherESProducer (const edm::ParameterSet &p)
boost::shared_ptr
< TrajectorySmoother
produce (const TrajectoryFitterRecord &)
virtual ~GsfTrajectorySmootherESProducer ()

Private Attributes

edm::ParameterSet pset_

Detailed Description

Provides a GSF smoother algorithm

Definition at line 13 of file GsfTrajectorySmootherESProducer.h.


Constructor & Destructor Documentation

GsfTrajectorySmootherESProducer::GsfTrajectorySmootherESProducer ( const edm::ParameterSet p)

Definition at line 21 of file GsfTrajectorySmootherESProducer.cc.

References edm::ParameterSet::getParameter(), L1TEmulatorMonitor_cff::p, pset_, and edm::ESProducer::setWhatProduced().

{
  std::string myname = p.getParameter<std::string>("ComponentName");
  pset_ = p;
  setWhatProduced(this,myname);
}
GsfTrajectorySmootherESProducer::~GsfTrajectorySmootherESProducer ( ) [virtual]

Definition at line 28 of file GsfTrajectorySmootherESProducer.cc.

{}

Member Function Documentation

boost::shared_ptr< TrajectorySmoother > GsfTrajectorySmootherESProducer::produce ( const TrajectoryFitterRecord iRecord)

Definition at line 31 of file GsfTrajectorySmootherESProducer.cc.

References ExpressReco_HICollisions_FallBack::estimator, edm::ParameterSet::getParameter(), edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::getRecord(), GsfElectronTrajectorySmoother_cfi::GsfTrajectorySmoother, LargeD0_PixelPairStep_cff::propagator, and pset_.

                                                                              { 
  //
  // material effects
  //
  std::string matName = pset_.getParameter<std::string>("MaterialEffectsUpdator");
  edm::ESHandle<GsfMaterialEffectsUpdator> matProducer;
  iRecord.getRecord<TrackingComponentsRecord>().get(matName,matProducer);
  //
  // propagator
  //
  std::string geomName = pset_.getParameter<std::string>("GeometricalPropagator");
  edm::ESHandle<Propagator> geomProducer;
  iRecord.getRecord<TrackingComponentsRecord>().get(geomName,geomProducer);
  GsfPropagatorWithMaterial propagator(*geomProducer.product(),*matProducer.product());
  //
  // merger
  //
  std::string mergerName = pset_.getParameter<std::string>("Merger");
//   edm::ESHandle<MultiTrajectoryStateMerger> mergerProducer;
//   iRecord.get(mergerName,mergerProducer);
  edm::ESHandle< MultiGaussianStateMerger<5> > mergerProducer;
  iRecord.getRecord<TrackingComponentsRecord>().get(mergerName,mergerProducer);
  MultiTrajectoryStateMerger merger(*mergerProducer.product());
  //
  // estimator
  //
  //   double chi2Cut = pset_.getParameter<double>("ChiSquarCut");
  double chi2Cut(100.);
  GsfChi2MeasurementEstimator estimator(chi2Cut);
  //
  // geometry
  std::string gname = pset_.getParameter<std::string>("RecoGeometry");
  edm::ESHandle<DetLayerGeometry> geo;
  iRecord.getRecord<RecoGeometryRecord>().get(gname,geo);
  // create algorithm
  //
  //   bool matBefUpd = pset_.getParameter<bool>("MaterialBeforeUpdate");
  double scale = pset_.getParameter<double>("ErrorRescaling");
  return boost::shared_ptr<TrajectorySmoother>(new GsfTrajectorySmoother(propagator,
                                                                         GsfMultiStateUpdator(), 
                                                                         estimator,merger,
//                                                                       matBefUpd,
                                                                         scale,
                                                                         true,//BM should this be taken from parameterSet?
                                                                         geo.product()));
}

Member Data Documentation

Definition at line 19 of file GsfTrajectorySmootherESProducer.h.

Referenced by GsfTrajectorySmootherESProducer(), and produce().