CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
RPixPileUpSignals Class Reference

#include <RPixPileUpSignals.h>

Public Member Functions

void add (const std::map< unsigned short, double > &charge_induced, int PSimHitIndex)
 
std::map< unsigned short, std::vector< std::pair< int, double > > > & dumpLinks ()
 
const std::map< unsigned short, double > & dumpSignal ()
 
void reset ()
 
 RPixPileUpSignals (const edm::ParameterSet &params, uint32_t det_id)
 

Private Attributes

uint32_t det_id_
 
bool links_persistence_
 
std::map< unsigned short, double > the_pixel_charge_piled_up_map_
 
std::map< unsigned short, std::vector< std::pair< int, double > > > the_pixel_charge_piled_up_map_links_
 
bool verbosity_
 

Detailed Description

Definition at line 7 of file RPixPileUpSignals.h.

Constructor & Destructor Documentation

◆ RPixPileUpSignals()

RPixPileUpSignals::RPixPileUpSignals ( const edm::ParameterSet params,
uint32_t  det_id 
)

Definition at line 4 of file RPixPileUpSignals.cc.

4  : det_id_(det_id) {
5  links_persistence_ = params.getParameter<bool>("CTPPSPixelDigiSimHitRelationsPersistence");
6  verbosity_ = params.getParameter<int>("RPixVerbosity");
7 }

References links_persistence_, CalibrationSummaryClient_cfi::params, and verbosity_.

Member Function Documentation

◆ add()

void RPixPileUpSignals::add ( const std::map< unsigned short, double > &  charge_induced,
int  PSimHitIndex 
)

Definition at line 14 of file RPixPileUpSignals.cc.

14  {
15  for (std::map<unsigned short, double>::const_iterator i = charge_induced.begin(); i != charge_induced.end(); ++i) {
16  the_pixel_charge_piled_up_map_[i->first] += i->second;
17  if (links_persistence_ && i->second > 0) {
18  the_pixel_charge_piled_up_map_links_[i->first].push_back(std::pair<int, double>(PSimHitIndex, i->second));
19  if (verbosity_) {
20  edm::LogInfo("RPixPileUpSignals") << "Det id=" << det_id_ << " pixel=" << i->first << " charge=" << i->second;
21  }
22  }
23  }
24 }

References det_id_, mps_fire::i, links_persistence_, the_pixel_charge_piled_up_map_, the_pixel_charge_piled_up_map_links_, and verbosity_.

Referenced by counter.Counter::register().

◆ dumpLinks()

std::map<unsigned short, std::vector<std::pair<int, double> > >& RPixPileUpSignals::dumpLinks ( )
inline

Definition at line 18 of file RPixPileUpSignals.h.

18  {
20  }

References the_pixel_charge_piled_up_map_links_.

◆ dumpSignal()

const std::map<unsigned short, double>& RPixPileUpSignals::dumpSignal ( )
inline

Definition at line 15 of file RPixPileUpSignals.h.

References the_pixel_charge_piled_up_map_.

◆ reset()

void RPixPileUpSignals::reset ( void  )

Member Data Documentation

◆ det_id_

uint32_t RPixPileUpSignals::det_id_
private

Definition at line 26 of file RPixPileUpSignals.h.

Referenced by add().

◆ links_persistence_

bool RPixPileUpSignals::links_persistence_
private

Definition at line 25 of file RPixPileUpSignals.h.

Referenced by add(), and RPixPileUpSignals().

◆ the_pixel_charge_piled_up_map_

std::map<unsigned short, double> RPixPileUpSignals::the_pixel_charge_piled_up_map_
private

Definition at line 23 of file RPixPileUpSignals.h.

Referenced by add(), dumpSignal(), and reset().

◆ the_pixel_charge_piled_up_map_links_

std::map<unsigned short, std::vector<std::pair<int, double> > > RPixPileUpSignals::the_pixel_charge_piled_up_map_links_
private

Definition at line 24 of file RPixPileUpSignals.h.

Referenced by add(), dumpLinks(), and reset().

◆ verbosity_

bool RPixPileUpSignals::verbosity_
private

Definition at line 27 of file RPixPileUpSignals.h.

Referenced by add(), and RPixPileUpSignals().

mps_fire.i
i
Definition: mps_fire.py:355
CalibrationSummaryClient_cfi.params
params
Definition: CalibrationSummaryClient_cfi.py:14
edm::LogInfo
Definition: MessageLogger.h:254
RPixPileUpSignals::det_id_
uint32_t det_id_
Definition: RPixPileUpSignals.h:26
RPixPileUpSignals::the_pixel_charge_piled_up_map_
std::map< unsigned short, double > the_pixel_charge_piled_up_map_
Definition: RPixPileUpSignals.h:23
RPixPileUpSignals::the_pixel_charge_piled_up_map_links_
std::map< unsigned short, std::vector< std::pair< int, double > > > the_pixel_charge_piled_up_map_links_
Definition: RPixPileUpSignals.h:24
RPixPileUpSignals::links_persistence_
bool links_persistence_
Definition: RPixPileUpSignals.h:25
RPixPileUpSignals::verbosity_
bool verbosity_
Definition: RPixPileUpSignals.h:27