CMS 3D CMS Logo

SiStripThresholdReader Class Reference

#include <CondTools/SiStrip/plugins/SiStripThresholdReader.h>

Inheritance diagram for SiStripThresholdReader:

edm::EDAnalyzer

List of all members.

Public Member Functions

void analyze (const edm::Event &, const edm::EventSetup &)
 SiStripThresholdReader (const edm::ParameterSet &)
 ~SiStripThresholdReader ()

Private Attributes

uint32_t printdebug_


Detailed Description

Definition at line 25 of file SiStripThresholdReader.h.


Constructor & Destructor Documentation

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

Definition at line 7 of file SiStripThresholdReader.cc.

00007                                                                               :
00008   printdebug_(iConfig.getUntrackedParameter<uint32_t>("printDebug",3)){}

SiStripThresholdReader::~SiStripThresholdReader (  ) 

Definition at line 10 of file SiStripThresholdReader.cc.

00010 {}


Member Function Documentation

void SiStripThresholdReader::analyze ( const edm::Event e,
const edm::EventSetup iSetup 
) [virtual]

Implements edm::EDAnalyzer.

Definition at line 12 of file SiStripThresholdReader.cc.

References data, lat::endl(), SiStripThreshold::Data::FirstStrip_and_Hth, edm::EventSetup::get(), SiStripThreshold::Data::getFirstStrip(), SiStripThreshold::Data::getHth(), SiStripThreshold::Data::getLth(), it, printdebug_, and range.

00012                                                                                    {
00013 
00014   edm::ESHandle<SiStripThreshold> SiStripThreshold_;
00015   iSetup.get<SiStripThresholdRcd>().get(SiStripThreshold_);
00016   edm::LogInfo("SiStripThresholdReader") << "[SiStripThresholdReader::analyze] End Reading SiStripThreshold" << std::endl;
00017   
00018   std::vector<uint32_t> detid;
00019   SiStripThreshold_->getDetIds(detid);
00020   edm::LogInfo("Number of detids ")  << detid.size() << std::endl;
00021   if (printdebug_)
00022     for (size_t id=0;id<detid.size() && id<printdebug_;id++)
00023       {
00024         SiStripThreshold::Range range=SiStripThreshold_->getRange(detid[id]);
00025         
00026         //int strip=0;
00027         float old_lowTh=-1, old_highTh=-1, old_FirstStrip=-1;
00028         for(int it=0;it<768;it++){
00029           SiStripThreshold::Data data=SiStripThreshold_->getData(it,range);
00030           if (old_lowTh!=data.getLth() || old_highTh!=data.getHth() || old_FirstStrip!=data.getFirstStrip()){
00031             edm::LogInfo("SiStripThresholdReader")  << "detid: " << detid[id] << " \t"
00032                                                     << "strip: " << it << " \t" 
00033                                                     << "firstStrip: " <<  data.getFirstStrip() << " \t"
00034                                                     << "lTh: " << data.getLth()  << " \t" 
00035                                                     << "hTh: " << data.getHth()   << " \t" 
00036                                                     << "FirstStrip_and_Hth: " << data.FirstStrip_and_Hth << " \t"
00037                                                     << std::endl;           
00038             old_lowTh=data.getLth();
00039             old_highTh=data.getHth();
00040             old_FirstStrip=data.getFirstStrip();
00041           }
00042         } 
00043       }
00044 }


Member Data Documentation

uint32_t SiStripThresholdReader::printdebug_ [private]

Definition at line 34 of file SiStripThresholdReader.h.

Referenced by analyze().


The documentation for this class was generated from the following files:
Generated on Tue Jun 9 18:32:35 2009 for CMSSW by  doxygen 1.5.4