test
CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Functions | Variables
DeadROCCounter Namespace Reference

Functions

def GetNonZeroOccNumber
 
def getRunNumber
 

Variables

int bpixtot = 0
 
string clusstr = path+"charge_siPixelClusters"
 
tuple nclust = fin.Get(clusstr)
 
tuple nent = nclust.GetEntries()
 
tuple out_file = open(outname, "w")
 
list tmpstr = labels[k]
 

Function Documentation

def DeadROCCounter.GetNonZeroOccNumber (   histoname)

Definition at line 12 of file DeadROCCounter.py.

References getRunNumber().

12 
13 def GetNonZeroOccNumber(histoname):
14  global nrocs
15  global fin
16  nrocs=0
17  histo=fin.Get(histoname)
18  nx=histo.GetNbinsX()
19  ny=histo.GetNbinsY()
20  for i in range(1,nx+1):
21  for j in range(1,ny+1):
22  value=histo.GetBinContent(i,j)
23  if value>0:
24  nrocs += 1
25 
26 nrocs=0
27 fname=sys.argv[1]
28 
29 runNumber="0"
30 getRunNumber(fname)
31 
32 path="DQMData/Run " + runNumber +"/Pixel/Run summary/Clusters/OnTrack/"
33 
34 labels=["BPix L1: ", "BPix L2: ", "BPix L3: ", "FPix tot: "]
35 
36 histonames=[path + "pix_bar Occ_roc_ontracksiPixelDigis_layer_1",path + "pix_bar Occ_roc_ontracksiPixelDigis_layer_2",path + "pix_bar Occ_roc_ontracksiPixelDigis_layer_3",path + "ROC_endcap_occupancy"]
37 
38 TotROCs=[2560-256,4096-256,5632-256,4320] #total number of ROCs in the Pixel detector layers and the FPix, the factor 256 for BPix Layer derive by half modules, left there as a reminder
39 
40 DeadROCs=[0,0,0,0]
41 
42 fin= TFile(fname)
43 
44 #print type(fname)
45 
outname="PixZeroOccROCs_run" + runNumber + ".txt"
def DeadROCCounter.getRunNumber (   filename)

Definition at line 6 of file DeadROCCounter.py.

Referenced by ODCond2ConfInfo.fetchID(), SiStripBaseServiceFromDQM< T >.getMetaDataString(), popcon::EcalSRPHandler.getNewObjects(), popcon::EcalDAQHandler.getNewObjects(), GetNonZeroOccNumber(), and ODCond2ConfInfo.writeDB().

6 
7 def getRunNumber(filename):
8  global runNumber
9  pos=filename.find("__")
10  runNumber=filename[pos-6:pos]
11  #print runNumber

Variable Documentation

int DeadROCCounter.bpixtot = 0

Definition at line 49 of file DeadROCCounter.py.

string DeadROCCounter.clusstr = path+"charge_siPixelClusters"

Definition at line 61 of file DeadROCCounter.py.

tuple DeadROCCounter.nclust = fin.Get(clusstr)

Definition at line 62 of file DeadROCCounter.py.

Referenced by ClusterizingHistogram.clusterize(), and PFClusterWidthAlgo.PFClusterWidthAlgo().

tuple DeadROCCounter.nent = nclust.GetEntries()

Definition at line 63 of file DeadROCCounter.py.

Referenced by FittedEntriesSet.FillCorrelations(), and ErrorCorrelationMgr.readFromReportFile().

tuple DeadROCCounter.out_file = open(outname, "w")

Definition at line 46 of file DeadROCCounter.py.

Referenced by HOCalibAnalyzer.endJob(), HcalQIEManager.generateQieTable(), HcalLutManager.get_xml_files_from_db(), HcalQIEManager.getHfQieTable(), HcalQIEManager.getTableFromDb(), JsonOutputProducer.write(), SummaryOutputProducer.writeCSV_module(), SummaryOutputProducer.writeCSV_trigger(), and SummaryOutputProducer.writeHistograms().

list DeadROCCounter.tmpstr = labels[k]

Definition at line 56 of file DeadROCCounter.py.