CMS 3D CMS Logo

Public Member Functions | Private Attributes

GsfTrajectoryFitterESProducer Class Reference

#include <GsfTrajectoryFitterESProducer.h>

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

List of all members.

Public Member Functions

 GsfTrajectoryFitterESProducer (const edm::ParameterSet &p)
boost::shared_ptr
< TrajectoryFitter
produce (const TrajectoryFitterRecord &)
virtual ~GsfTrajectoryFitterESProducer ()

Private Attributes

edm::ParameterSet pset_

Detailed Description

Provides a GSF fitter algorithm

Definition at line 13 of file GsfTrajectoryFitterESProducer.h.


Constructor & Destructor Documentation

GsfTrajectoryFitterESProducer::GsfTrajectoryFitterESProducer ( const edm::ParameterSet p)

Definition at line 23 of file GsfTrajectoryFitterESProducer.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);
}
GsfTrajectoryFitterESProducer::~GsfTrajectoryFitterESProducer ( ) [virtual]

Definition at line 30 of file GsfTrajectoryFitterESProducer.cc.

{}

Member Function Documentation

boost::shared_ptr< TrajectoryFitter > GsfTrajectoryFitterESProducer::produce ( const TrajectoryFitterRecord iRecord)

Definition at line 33 of file GsfTrajectoryFitterESProducer.cc.

References ExpressReco_HICollisions_FallBack::estimator, edm::ParameterSet::getParameter(), edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::getRecord(), GsfElectronTrajectoryFitter_cfi::GsfTrajectoryFitter, 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
  //
  return boost::shared_ptr<TrajectoryFitter>(new GsfTrajectoryFitter(propagator,
                                                                     GsfMultiStateUpdator(), 
                                                                     estimator,merger,
                                                                     geo.product()));
}

Member Data Documentation

Definition at line 19 of file GsfTrajectoryFitterESProducer.h.

Referenced by GsfTrajectoryFitterESProducer(), and produce().