46 src_( conf_.getParameter<edm::
InputTag>(
"src" ) ),
47 saveFile( conf_.getUntrackedParameter<bool>(
"saveFile",
false) ),
48 isPIB( conf_.getUntrackedParameter<bool>(
"isPIB",
false) ),
49 slowDown( conf_.getUntrackedParameter<bool>(
"slowDown",
false) ),
50 modOn( conf_.getUntrackedParameter<bool>(
"modOn",
true) ),
51 twoDimOn( conf_.getUntrackedParameter<bool>(
"twoDimOn",
true) ),
52 reducedSet( conf_.getUntrackedParameter<bool>(
"reducedSet",
false) ),
53 ladOn( conf_.getUntrackedParameter<bool>(
"ladOn",
false) ),
54 layOn( conf_.getUntrackedParameter<bool>(
"layOn",
false) ),
55 phiOn( conf_.getUntrackedParameter<bool>(
"phiOn",
false) ),
56 ringOn( conf_.getUntrackedParameter<bool>(
"ringOn",
false) ),
57 bladeOn( conf_.getUntrackedParameter<bool>(
"bladeOn",
false) ),
58 diskOn( conf_.getUntrackedParameter<bool>(
"diskOn",
false) ),
59 smileyOn(conf_.getUntrackedParameter<bool>(
"smileyOn",
false) ),
60 bigEventSize( conf_.getUntrackedParameter<int>(
"bigEventSize",100) )
63 LogInfo (
"PixelDQM") <<
"SiPixelClusterSource::SiPixelClusterSource: Got DQM BackEnd interface"<<endl;
74 LogInfo (
"PixelDQM") <<
"SiPixelClusterSource::~SiPixelClusterSource: Destructor"<<endl;
76 std::map<uint32_t,SiPixelClusterModule*>::iterator struct_iter;
78 delete struct_iter->second;
79 struct_iter->second = 0;
90 LogInfo (
"PixelDQM") <<
" SiPixelClusterSource::beginJob - Initialisation ... " << std::endl;
96 LogInfo (
"PixelDQM") <<
"Smiley (Cluster sizeY vs. Cluster eta) is " <<
smileyOn <<
"\n";
110 meClPosLayer1 =
theDMBE->
book2D(
"position_siPixelClusters_Layer_1",
"Clusters Layer1;Global Z (cm);Global #phi",200,-30.,30.,128,-3.2,3.2);
111 meClPosLayer2 =
theDMBE->
book2D(
"position_siPixelClusters_Layer_2",
"Clusters Layer2;Global Z (cm);Global #phi",200,-30.,30.,128,-3.2,3.2);
112 meClPosLayer3 =
theDMBE->
book2D(
"position_siPixelClusters_Layer_3",
"Clusters Layer3;Global Z (cm);Global #phi",200,-30.,30.,128,-3.2,3.2);
114 meClPosDisk1pz =
theDMBE->
book2D(
"position_siPixelClusters_pz_Disk_1",
"Clusters +Z Disk1;Global X (cm);Global Y (cm)",80,-20.,20.,80,-20.,20.);
115 meClPosDisk2pz =
theDMBE->
book2D(
"position_siPixelClusters_pz_Disk_2",
"Clusters +Z Disk2;Global X (cm);Global Y (cm)",80,-20.,20.,80,-20.,20.);
116 meClPosDisk1mz =
theDMBE->
book2D(
"position_siPixelClusters_mz_Disk_1",
"Clusters -Z Disk1;Global X (cm);Global Y (cm)",80,-20.,20.,80,-20.,20.);
117 meClPosDisk2mz =
theDMBE->
book2D(
"position_siPixelClusters_mz_Disk_2",
"Clusters -Z Disk2;Global X (cm);Global Y (cm)",80,-20.,20.,80,-20.,20.);
126 LogInfo (
"PixelDQM") <<
" SiPixelClusterSource::endJob - Saving Root File " << std::endl;
171 int nEventFpixClusters = 0;
174 std::map<uint32_t,SiPixelClusterModule*>::iterator struct_iter;
177 int numberOfFpixClusters = (*struct_iter).second->fill(*input, tracker,
modOn,
181 nEventFpixClusters = nEventFpixClusters + numberOfFpixClusters;
192 me->
Fill(lumiSection,1./23.);
207 LogInfo (
"PixelDQM") <<
" SiPixelClusterSource::buildStructure" ;
211 LogVerbatim (
"PixelDQM") <<
" *** Geometry node for TrackerGeom is "<<&(*pDD)<<std::endl;
212 LogVerbatim (
"PixelDQM") <<
" *** I have " << pDD->dets().size() <<
" detectors"<<std::endl;
213 LogVerbatim (
"PixelDQM") <<
" *** I have " << pDD->detTypes().size() <<
" types"<<std::endl;
215 for(TrackerGeometry::DetContainer::const_iterator it = pDD->dets().begin(); it != pDD->dets().end(); it++){
217 if(dynamic_cast<PixelGeomDetUnit*>((*it))!=0){
219 DetId detId = (*it)->geographicalId();
220 const GeomDetUnit * geoUnit = pDD->idToDetUnit( detId );
228 uint32_t
id = detId();
232 LogDebug (
"PixelDQM") <<
" ---> Adding Barrel Module " << detId.
rawId() << endl;
235 LogDebug (
"PixelDQM") <<
" ---> Adding Endcap Module " << detId.
rawId() << endl;
241 char sside[80]; sprintf(sside,
"HalfCylinder_%i",side);
242 char sdisk[80]; sprintf(sdisk,
"Disk_%i",disk);
243 char sblade[80]; sprintf(sblade,
"Blade_%02i",blade);
244 char spanel[80]; sprintf(spanel,
"Panel_%i",panel);
245 char smodule[80];sprintf(smodule,
"Module_%i",module);
248 bool mask = side_str.find(
"HalfCylinder_1")!=string::npos||
249 side_str.find(
"HalfCylinder_2")!=string::npos||
250 side_str.find(
"HalfCylinder_4")!=string::npos||
251 disk_str.find(
"Disk_2")!=string::npos;
254 if(
isPIB && mask)
continue;
270 char title[256]; snprintf(title, 256,
"Rate of events with >%i FPIX clusters;LumiSection;Rate of large FPIX events per LS [Hz]",
bigEventSize);
274 std::map<uint32_t,SiPixelClusterModule*>::iterator struct_iter;
287 <<
"[SiPixelClusterSource::bookMEs] Creation of DQM folder failed";
294 LogDebug (
"PixelDQM") <<
"PROBLEM WITH LADDER-FOLDER\n";
301 LogDebug (
"PixelDQM") <<
"PROBLEM WITH LAYER-FOLDER\n";
308 LogDebug (
"PixelDQM") <<
"PROBLEM WITH PHI-FOLDER\n";
315 LogDebug (
"PixelDQM") <<
"PROBLEM WITH BLADE-FOLDER\n";
322 LogDebug (
"PixelDQM") <<
"PROBLEM WITH DISK-FOLDER\n";
329 LogDebug (
"PixelDQM") <<
"PROBLEM WITH RING-FOLDER\n";
336 LogDebug (
"PixelDQM") <<
"PROBLEM WITH BARREL-FOLDER\n";
int plaquetteName() const
plaquetteId (in pannel)
virtual void buildStructure(edm::EventSetup const &)
T getParameter(std::string const &) const
MonitorElement * meClPosDisk2pz
virtual void analyze(const edm::Event &, const edm::EventSetup &)
MonitorElement * book1D(const char *name, const char *title, int nchX, double lowX, double highX)
Book 1D histogram.
bool getByToken(EDGetToken token, Handle< PROD > &result) const
#define DEFINE_FWK_MODULE(type)
edm::LuminosityBlockNumber_t luminosityBlock() const
double getEntries(void) const
get # of entries
edm::EDGetTokenT< edmNew::DetSetVector< SiPixelCluster > > srcToken_
SiPixelClusterSource(const edm::ParameterSet &conf)
static std::string const input
uint32_t rawId() const
get the raw id
MonitorElement * meClPosLayer3
int bladeName() const
blade id
virtual void beginRun(const edm::Run &, edm::EventSetup const &)
MonitorElement * meClPosLayer1
void save(const std::string &filename, const std::string &path="", const std::string &pattern="", const std::string &rewrite="", const uint32_t run=0, SaveReferenceTag ref=SaveWithReference, int minStatus=dqm::qstatus::STATUS_OK, const std::string &fileupdate="RECREATE")
MonitorElement * get(const std::string &path) const
get ME from full pathname (e.g. "my/long/dir/my_histo")
int subdetId() const
get the contents of the subdetector field (not cast into any detector's numbering enum) ...
virtual const PixelTopology & specificTopology() const
Returns a reference to the pixel proxy topology.
int pannelName() const
pannel id
MonitorElement * meClPosDisk2mz
int diskName() const
disk id
std::map< uint32_t, SiPixelClusterModule * > thePixelStructure
volatile std::atomic< bool > shutdown_flag false
MonitorElement * meClPosLayer2
HalfCylinder halfCylinder() const
MonitorElement * book2D(const char *name, const char *title, int nchX, double lowX, double highX, int nchY, double lowY, double highY)
Book 2D histogram.
void Reset(void)
reset ME (ie. contents, errors, etc)
MonitorElement * bigFpixClusterEventRate
MonitorElement * meClPosDisk1mz
void setCurrentFolder(const std::string &fullpath)
MonitorElement * meClPosDisk1pz
bool setModuleFolder(const uint32_t &rawdetid=0, int type=0)
Set folder name for a module or plaquette.