CMS 3D CMS Logo

Public Member Functions | Protected Types | Protected Member Functions | Protected Attributes

PFRecHitProducer Class Reference

Base producer for particle flow rechits (PFRecHit) More...

#include <PFRecHitProducer.h>

Inheritance diagram for PFRecHitProducer:
edm::EDProducer edm::ProducerBase edm::ProductRegistryHelper PFRecHitProducerECAL PFRecHitProducerHCAL PFRecHitProducerPS

List of all members.

Public Member Functions

virtual void beginRun (edm::Run &run, const edm::EventSetup &es)
virtual void endRun ()
 PFRecHitProducer (const edm::ParameterSet &)
void produce (edm::Event &iEvent, const edm::EventSetup &iSetup)
 ~PFRecHitProducer ()

Protected Types

typedef std::map< unsigned,
unsigned >::const_iterator 
IDH

Protected Member Functions

virtual void createRecHits (std::vector< reco::PFRecHit > &rechits, std::vector< reco::PFRecHit > &rechitsCleaned, edm::Event &, const edm::EventSetup &)=0

Protected Attributes

const HcalPFCorrsmyPFCorr
const EcalChannelStatustheEcalChStatus
const HcalChannelQualitytheHcalChStatus
const CaloTowerConstituentsMaptheTowerConstituentsMap
double thresh_Barrel_
 rechits with E < threshold will not give rise to a PFRecHit
double thresh_Endcap_
bool verbose_
 verbose ?

Detailed Description

Base producer for particle flow rechits (PFRecHit)

Author:
Colin Bernet
Date:
february 2008

Definition at line 33 of file PFRecHitProducer.h.


Member Typedef Documentation

typedef std::map<unsigned, unsigned >::const_iterator PFRecHitProducer::IDH [protected]

Definition at line 48 of file PFRecHitProducer.h.


Constructor & Destructor Documentation

PFRecHitProducer::PFRecHitProducer ( const edm::ParameterSet iConfig) [explicit]

Definition at line 21 of file PFRecHitProducer.cc.

References edm::ParameterSet::getParameter(), and edm::ParameterSet::getUntrackedParameter().

{

    
  verbose_ = 
    iConfig.getUntrackedParameter<bool>("verbose",false);

  thresh_Barrel_ = 
    iConfig.getParameter<double>("thresh_Barrel");
  thresh_Endcap_ = 
    iConfig.getParameter<double>("thresh_Endcap");
    
    
  
  //register products
  produces<reco::PFRecHitCollection>();
  produces<reco::PFRecHitCollection>("Cleaned");
  
}
PFRecHitProducer::~PFRecHitProducer ( )

Definition at line 58 of file PFRecHitProducer.cc.

{}

Member Function Documentation

void PFRecHitProducer::beginRun ( edm::Run run,
const edm::EventSetup es 
) [virtual]

Reimplemented from edm::EDProducer.

Definition at line 62 of file PFRecHitProducer.cc.

References edm::EventSetup::get(), and edm::ESHandle< T >::product().

                                                 {

  // get the HCAL RecHits correction factors
  // edm::ESHandle<HcalRespCorrs> rchandle;
  // es.get<HcalRespCorrsRcd>().get(rchandle);
  // myRespCorr= rchandle.product();
  // And the PF-specific ones
  edm::ESHandle<HcalPFCorrs> pfrchandle;
  es.get<HcalPFCorrsRcd>().get(pfrchandle);
  myPFCorr= pfrchandle.product();

  // Get cleaned channels in the HCAL and HF 
  // HCAL channel status map ****************************************
  edm::ESHandle<HcalChannelQuality> hcalChStatus;    
  es.get<HcalChannelQualityRcd>().get( hcalChStatus );
  theHcalChStatus = hcalChStatus.product();

  // Retrieve the good/bad ECAL channels from the DB
  edm::ESHandle<EcalChannelStatus> ecalChStatus;
  es.get<EcalChannelStatusRcd>().get(ecalChStatus);
  theEcalChStatus = ecalChStatus.product();

  edm::ESHandle<CaloTowerConstituentsMap> cttopo;
  es.get<IdealGeometryRecord>().get(cttopo);
  theTowerConstituentsMap = cttopo.product();
}
virtual void PFRecHitProducer::createRecHits ( std::vector< reco::PFRecHit > &  rechits,
std::vector< reco::PFRecHit > &  rechitsCleaned,
edm::Event ,
const edm::EventSetup  
) [protected, pure virtual]

translate the standard rechits ( or calotowers) them to PFRecHits, which are stored in the rechits vector

Implemented in PFRecHitProducerECAL, PFRecHitProducerHCAL, and PFRecHitProducerPS.

void PFRecHitProducer::endRun ( void  ) [virtual]

Definition at line 92 of file PFRecHitProducer.cc.

{}
void PFRecHitProducer::produce ( edm::Event iEvent,
const edm::EventSetup iSetup 
) [virtual]

Implements edm::EDProducer.

Definition at line 42 of file PFRecHitProducer.cc.

References edm::Event::put().

                                                            {


  auto_ptr< vector<reco::PFRecHit> > recHits( new vector<reco::PFRecHit> ); 
  auto_ptr< vector<reco::PFRecHit> > recHitsCleaned( new vector<reco::PFRecHit> ); 
  
  // fill the collection of rechits (see child classes)
  createRecHits( *recHits, *recHitsCleaned, iEvent, iSetup);

  iEvent.put( recHits );
  iEvent.put( recHitsCleaned, "Cleaned" );

}

Member Data Documentation

Definition at line 69 of file PFRecHitProducer.h.

Definition at line 71 of file PFRecHitProducer.h.

Definition at line 70 of file PFRecHitProducer.h.

Definition at line 72 of file PFRecHitProducer.h.

rechits with E < threshold will not give rise to a PFRecHit

Definition at line 64 of file PFRecHitProducer.h.

Referenced by PFRecHitProducerPS::createRecHits().

Definition at line 65 of file PFRecHitProducer.h.

Referenced by PFRecHitProducerPS::createRecHits().

bool PFRecHitProducer::verbose_ [protected]

verbose ?

Definition at line 61 of file PFRecHitProducer.h.