CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Private Attributes
CaloMiscalibMapHcal Class Reference

#include <CaloMiscalibMapHcal.h>

Inheritance diagram for CaloMiscalibMapHcal:
CaloMiscalibMap

Public Member Functions

virtual void addCell (const DetId &cell, float scaling_factor)
 
 CaloMiscalibMapHcal ()
 
const std::map< uint32_t, float > & get ()
 
void prefillMap (const HcalTopology &topology)
 
void print ()
 
- Public Member Functions inherited from CaloMiscalibMap
 CaloMiscalibMap ()
 
virtual ~CaloMiscalibMap ()
 

Private Attributes

std::map< uint32_t, float > mapHcal_
 

Detailed Description

Definition at line 16 of file CaloMiscalibMapHcal.h.

Constructor & Destructor Documentation

CaloMiscalibMapHcal::CaloMiscalibMapHcal ( )
inline

Definition at line 18 of file CaloMiscalibMapHcal.h.

18  {
19  }

Member Function Documentation

virtual void CaloMiscalibMapHcal::addCell ( const DetId cell,
float  scaling_factor 
)
inlinevirtual

Implements CaloMiscalibMap.

Definition at line 47 of file CaloMiscalibMapHcal.h.

References mapHcal_, and DetId::rawId().

48 {
49  //mapHcal_.setValue(cell.rawId(),scaling_factor);
50  mapHcal_[cell.rawId()]=scaling_factor;
51 }
uint32_t rawId() const
get the raw id
Definition: DetId.h:43
std::map< uint32_t, float > mapHcal_
const std::map<uint32_t, float>& CaloMiscalibMapHcal::get ( )
inline
void CaloMiscalibMapHcal::prefillMap ( const HcalTopology topology)
inline

Definition at line 21 of file CaloMiscalibMapHcal.h.

References HLT_25ns14e33_v1_cff::depth, eta, mapHcal_, phi, DetId::rawId(), and HcalTopology::valid().

Referenced by HcalRecHitRecalib::beginRun().

21  {
22 
23  for (int det = 1; det < 5; det++) {
24  for (int eta = -63; eta < 64; eta++) {
25  for (int phi = 0; phi < 128; phi++) {
26  for (int depth = 1; depth < 5; depth++) {
27 
28  try {
29  HcalDetId hcaldetid ((HcalSubdetector) det, eta, phi, depth);
30  if (topology.valid(hcaldetid))
31  // mapHcal_.setValue(hcaldetid.rawId(),1.0);
32  {
33  mapHcal_[hcaldetid.rawId()]=1.0;
34  // std::cout << "Valid cell found: " << det << " " << eta << " " << phi << " " << depth << std::endl;
35  }
36 
37  }
38  catch (...) {
39  }
40  }
41  }
42  }
43  }
44 }
std::map< uint32_t, float > mapHcal_
HcalSubdetector
Definition: HcalAssistant.h:31
virtual bool valid(const DetId &id) const
Definition: HcalTopology.cc:58
void CaloMiscalibMapHcal::print ( void  )
inline

Definition at line 53 of file CaloMiscalibMapHcal.h.

References mapHcal_.

Referenced by HcalRecHitRecalib::beginRun().

54  {
55 
56  std::map<uint32_t,float>::const_iterator it;
57 
58  // for(it=mapHcal_.getMap().begin();it!=mapHcal_.getMap().end();it++){
59  // }
60  for(it=mapHcal_.begin();it!=mapHcal_.end();it++){
61  }
62 
63 }
std::map< uint32_t, float > mapHcal_

Member Data Documentation

std::map<uint32_t, float> CaloMiscalibMapHcal::mapHcal_
private

Definition at line 71 of file CaloMiscalibMapHcal.h.

Referenced by addCell(), get(), prefillMap(), and print().