|
template<> |
void | fill_correction_map (TrackDetMatchInfo *info, std::map< uint32_t, float > *cor_map) |
|
template<> |
void | fill_correction_map (TrackDetMatchInfo *info, std::map< uint32_t, float > *cor_map) |
|
void | fill_correction_map (TrackDetMatchInfo *, std::map< uint32_t, float > *) |
|
template<> |
void | fill_correction_map (TrackDetMatchInfo *info, std::map< uint32_t, float > *cor_map) |
|
template<> |
void | fill_correction_map (TrackDetMatchInfo *info, std::map< uint32_t, float > *cor_map) |
|
template<> |
void | fill_correction_map (TrackDetMatchInfo *info, std::map< uint32_t, float > *cor_map) |
|
template<> |
void | fill_correction_map (TrackDetMatchInfo *info, std::map< uint32_t, float > *cor_map) |
|
void | produce (edm::Event &, const edm::EventSetup &) override |
|
template<typename T>
class CaloCleaner< T >
Clean collections of calorimeter recHits (detectors supported at the moment: EB/EE, HB/HE and HO)
- Author
- Tomasz Maciej Frueboes; Christian Veelken, LLR
Clean Up from STefan Wayand, KIT
Definition at line 37 of file CaloCleaner.h.
Definition at line 86 of file CaloCleaner.h.
References TrackDetectorAssociator::Any, TrackDetectorAssociator::associate(), edm::View< T >::begin(), edm::SortedCollection< T, SORT >::begin(), edm::View< T >::end(), edm::SortedCollection< T, SORT >::end(), Exception, CaloCleaner< T >::fill_correction_map(), edm::EventSetup::get(), edm::Event::getByToken(), info(), CaloCleaner< T >::inputs_, eostools::move(), CaloCleaner< T >::mu_input_, nano_cff::muons, CaloCleaner< T >::parameters_, edm::ESHandle< T >::product(), PhotonConversionTrajectorySeedProducerFromQuadruplets_cfi::propagator, edm::Event::put(), rpcPointValidation_cfi::recHit, TrackDetectorAssociator::setPropagator(), reco::TrackBase::standAloneMuon, HiIsolationCommonParameters_cff::track, and CaloCleaner< T >::trackAssociator_.
96 std::map<uint32_t, float> correction_map;
103 if ( iMuon->track().isNonnull() ) track = iMuon->track().get();
104 else if ( iMuon->standAloneMuon().isNonnull() ) track = iMuon->
standAloneMuon().get();
105 else throw cms::Exception(
"FatalError") <<
"Failed to fill muon id information for a muon with undefined references to tracks";
112 std::unique_ptr<RecHitCollection> recHitCollection_output(
new RecHitCollection());
115 iEvent.
getByToken(input_.second, recHitCollection);
117 if (correction_map[
recHit->detid().rawId()] > 0){
118 float new_energy =
recHit->energy() - correction_map[
recHit->detid().rawId()];
119 if (new_energy <= 0)
continue;
121 newRecHit.setEnergy(new_energy);
122 recHitCollection_output->push_back(newRecHit);
125 recHitCollection_output->push_back(*
recHit);
141 recHitCollection_output->sort();
142 iEvent.
put(
std::move(recHitCollection_output),input_.first);
OrphanHandle< PROD > put(std::unique_ptr< PROD > product)
Put a new product.
void fill_correction_map(TrackDetMatchInfo *, std::map< uint32_t, float > *)
bool getByToken(EDGetToken token, Handle< PROD > &result) const
std::vector< T >::const_iterator const_iterator
const edm::EDGetTokenT< edm::View< pat::Muon > > mu_input_
std::map< std::string, edm::EDGetTokenT< RecHitCollection > > inputs_
edm::SortedCollection< T > RecHitCollection
const_iterator begin() const
void setPropagator(const Propagator *)
use a user configured propagator
const_iterator end() const
TrackDetectorAssociator trackAssociator_
boost::indirect_iterator< typename seq_t::const_iterator > const_iterator
TrackAssociatorParameters parameters_
TrackDetMatchInfo associate(const edm::Event &, const edm::EventSetup &, const FreeTrajectoryState &, const AssociatorParameters &)
const_iterator end() const
T const * product() const
const_iterator begin() const