CMS 3D CMS Logo

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

#include <Alignment/Validator/src/TrackerOfflineValidation.cc>

Inheritance diagram for TrackerOfflineValidation:
edm::EDAnalyzer edm::EDConsumerBase

Classes

struct  DirectoryWrapper
 
struct  ModuleHistos
 
struct  SummaryContainer
 

Public Types

enum  HistogrammType {
  XResidual, NormXResidual, YResidual, XprimeResidual,
  NormXprimeResidual, YprimeResidual, NormYprimeResidual, XResidualProfile,
  YResidualProfile
}
 
- Public Types inherited from edm::EDAnalyzer
typedef EDAnalyzer ModuleType
 

Public Member Functions

 TrackerOfflineValidation (const edm::ParameterSet &)
 
 ~TrackerOfflineValidation ()
 
- Public Member Functions inherited from edm::EDAnalyzer
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
 EDAnalyzer ()
 
ModuleDescription const & moduleDescription () const
 
std::string workerType () const
 
virtual ~EDAnalyzer ()
 
- Public Member Functions inherited from edm::EDConsumerBase
std::vector< ConsumesInfoconsumesInfo () const
 
 EDConsumerBase ()
 
ProductHolderIndexAndSkipBit indexFrom (EDGetToken, BranchType, TypeID const &) const
 
void itemsMayGet (BranchType, std::vector< ProductHolderIndexAndSkipBit > &) const
 
void itemsToGet (BranchType, std::vector< ProductHolderIndexAndSkipBit > &) const
 
std::vector
< ProductHolderIndexAndSkipBit >
const & 
itemsToGetFromEvent () const
 
void labelsForToken (EDGetToken iToken, Labels &oLabels) const
 
void modulesDependentUpon (const std::string &iProcessName, std::vector< const char * > &oModuleLabels) const
 
void modulesWhoseProductsAreConsumed (std::vector< ModuleDescription const * > &modules, ProductRegistry const &preg, std::map< std::string, ModuleDescription const * > const &labelsToDesc, std::string const &processName) const
 
bool registeredToConsume (ProductHolderIndex, bool, BranchType) const
 
bool registeredToConsumeMany (TypeID const &, BranchType) const
 
void updateLookup (BranchType iBranchType, ProductHolderIndexHelper const &)
 
virtual ~EDConsumerBase ()
 

Private Member Functions

virtual void analyze (const edm::Event &, const edm::EventSetup &) override
 
void bookDirHists (DirectoryWrapper &tfd, const Alignable &ali, const TrackerTopology *tTopo)
 
void bookGlobalHists (DirectoryWrapper &tfd)
 
void bookHists (DirectoryWrapper &tfd, const Alignable &ali, const TrackerTopology *tTopo, align::StructureType type, int i)
 
TrackerOfflineValidation::SummaryContainer bookSummaryHists (DirectoryWrapper &tfd, const Alignable &ali, align::StructureType type, int i)
 
TH1 * bookTH1F (bool isTransient, DirectoryWrapper &tfd, const char *histName, const char *histTitle, int nBinsX, double lowX, double highX)
 
TProfile * bookTProfile (bool isTransient, DirectoryWrapper &tfd, const char *histName, const char *histTitle, int nBinsX, double lowX, double highX)
 
TProfile * bookTProfile (bool isTransient, DirectoryWrapper &tfd, const char *histName, const char *histTitle, int nBinsX, double lowX, double highX, double lowY, double highY)
 
virtual void checkBookHists (const edm::EventSetup &setup)
 
void collateSummaryHists (DirectoryWrapper &tfd, const Alignable &ali, int i, std::vector< TrackerOfflineValidation::SummaryContainer > &vLevelProfiles)
 
virtual void endJob () override
 
void fillTree (TTree &tree, const std::map< int, TrackerOfflineValidation::ModuleHistos > &moduleHist_, TkOffTreeVariables &treeMem, const TrackerGeometry &tkgeom, const TrackerTopology *tTopo)
 
std::pair< float, float > fitResiduals (TH1 *hist) const
 
float Fwhm (const TH1 *hist) const
 
void getBinning (uint32_t subDetId, TrackerOfflineValidation::HistogrammType residualtype, int &nBinsX, double &lowerBoundX, double &upperBoundX)
 
ModuleHistosgetHistStructFromMap (const DetId &detid)
 
template<class OBJECT_TYPE >
int GetIndex (const std::vector< OBJECT_TYPE * > &vec, const TString &name)
 
float getMedian (const TH1 *hist) const
 
bool isBarrel (uint32_t subDetId)
 
bool isDetOrDetUnit (align::StructureType type)
 
bool isEndCap (uint32_t subDetId)
 
bool isPixel (uint32_t subDetId)
 
void setSummaryBin (int bin, TH1 *targetHist, TH1 *sourceHist)
 
void summarizeBinInContainer (int bin, SummaryContainer &targetContainer, SummaryContainer &sourceContainer)
 
void summarizeBinInContainer (int bin, uint32_t subDetId, SummaryContainer &targetContainer, ModuleHistos &sourceContainer)
 

Private Attributes

const TrackerGeometrybareTkGeomPtr_
 
const bool dqmMode_
 
const edm::EventSetuplastSetup_
 
const bool lCoorHistOn_
 
const std::string moduleDirectory_
 
const bool moduleLevelHistsTransient_
 
const bool moduleLevelProfiles_
 
std::map< int,
TrackerOfflineValidation::ModuleHistos
mPxbResiduals_
 
std::map< int,
TrackerOfflineValidation::ModuleHistos
mPxeResiduals_
 
std::map< int,
TrackerOfflineValidation::ModuleHistos
mTecResiduals_
 
std::map< int,
TrackerOfflineValidation::ModuleHistos
mTibResiduals_
 
std::map< int,
TrackerOfflineValidation::ModuleHistos
mTidResiduals_
 
std::map< int,
TrackerOfflineValidation::ModuleHistos
mTobResiduals_
 
const edm::ParameterSet parSet_
 
const bool stripYResiduals_
 
edm::ESHandle< TrackerGeometrytkGeom_
 
const bool useFit_
 
const bool useFwhm_
 
const bool useOverflowForRMS_
 
std::vector< TH1 * > vDeleteObjects_
 
std::vector< TH1 * > vTrack2DHistos_
 
std::vector< TH1 * > vTrackHistos_
 
std::vector< TH1 * > vTrackProfiles_
 

Additional Inherited Members

- Static Public Member Functions inherited from edm::EDAnalyzer
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &)
 
- Protected Member Functions inherited from edm::EDConsumerBase
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > consumes (edm::InputTag const &tag)
 
EDGetToken consumes (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken consumes (TypeToGet const &id, edm::InputTag const &tag)
 
ConsumesCollector consumesCollector ()
 Use a ConsumesCollector to gather consumes information from helper functions. More...
 
template<typename ProductType , BranchType B = InEvent>
void consumesMany ()
 
void consumesMany (const TypeToGet &id)
 
template<BranchType B>
void consumesMany (const TypeToGet &id)
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > mayConsume (edm::InputTag const &tag)
 
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 

Detailed Description

Description: <one line="" class="" summary>="">

Implementation: <Notes on="" implementation>="">

Definition at line 76 of file TrackerOfflineValidation.cc.

Member Enumeration Documentation

Constructor & Destructor Documentation

TrackerOfflineValidation::TrackerOfflineValidation ( const edm::ParameterSet iConfig)
explicit

Definition at line 351 of file TrackerOfflineValidation.cc.

352  : parSet_(iConfig), bareTkGeomPtr_(0), lCoorHistOn_(parSet_.getParameter<bool>("localCoorHistosOn")),
353  moduleLevelHistsTransient_(parSet_.getParameter<bool>("moduleLevelHistsTransient")),
354  moduleLevelProfiles_(parSet_.getParameter<bool>("moduleLevelProfiles")),
355  stripYResiduals_(parSet_.getParameter<bool>("stripYResiduals")),
356  useFwhm_(parSet_.getParameter<bool>("useFwhm")),
357  useFit_(parSet_.getParameter<bool>("useFit")),
358  useOverflowForRMS_(parSet_.getParameter<bool>("useOverflowForRMS")),
359  dqmMode_(parSet_.getParameter<bool>("useInDqmMode")),
360  moduleDirectory_(parSet_.getParameter<std::string>("moduleDirectoryInOutput")),
361  lastSetup_(nullptr)
362 {
363 }
const TrackerGeometry * bareTkGeomPtr_
T getParameter(std::string const &) const
const edm::ParameterSet parSet_
const edm::EventSetup * lastSetup_
TrackerOfflineValidation::~TrackerOfflineValidation ( )

Definition at line 366 of file TrackerOfflineValidation.cc.

References vDeleteObjects_.

367 {
368  // do anything here that needs to be done at desctruction time
369  // (e.g. close files, deallocate resources etc.)
370  for( std::vector<TH1*>::const_iterator it = vDeleteObjects_.begin(), itEnd = vDeleteObjects_.end();
371  it != itEnd;
372  ++it) delete *it;
373 }
std::vector< TH1 * > vDeleteObjects_

Member Function Documentation

void TrackerOfflineValidation::analyze ( const edm::Event iEvent,
const edm::EventSetup iSetup 
)
overrideprivatevirtual

Implements edm::EDAnalyzer.

Definition at line 968 of file TrackerOfflineValidation.cc.

References checkBookHists(), cond::rpcobgas::detid, TrackerValidationVariables::fillTrackQuantities(), getHistStructFromMap(), GetIndex(), isPixel(), lCoorHistOn_, TrackerOfflineValidation::ModuleHistos::LocalX, TrackerOfflineValidation::ModuleHistos::LocalY, moduleLevelProfiles_, TrackerOfflineValidation::ModuleHistos::NormResHisto, TrackerOfflineValidation::ModuleHistos::NormResXprimeHisto, TrackerOfflineValidation::ModuleHistos::NormResYprimeHisto, parSet_, PixelSubdetector::PixelBarrel, PixelSubdetector::PixelEndcap, TrackerOfflineValidation::ModuleHistos::ResHisto, TrackerOfflineValidation::ModuleHistos::ResXprimeHisto, TrackerOfflineValidation::ModuleHistos::ResXvsXProfile, TrackerOfflineValidation::ModuleHistos::ResXvsYProfile, TrackerOfflineValidation::ModuleHistos::ResYHisto, TrackerOfflineValidation::ModuleHistos::ResYprimeHisto, TrackerOfflineValidation::ModuleHistos::ResYvsXProfile, TrackerOfflineValidation::ModuleHistos::ResYvsYProfile, stripYResiduals_, DetId::subdetId(), funct::tan(), StripSubdetector::TEC, StripSubdetector::TIB, StripSubdetector::TID, StripSubdetector::TOB, useOverflowForRMS_, vTrack2DHistos_, vTrackHistos_, and vTrackProfiles_.

969 {
970  if (useOverflowForRMS_)TH1::StatOverflows(kTRUE);
971  this->checkBookHists(iSetup); // check whether hists are booked and do so if not yet done
972 
973  TrackerValidationVariables avalidator_(iSetup,parSet_);
974 
975  std::vector<TrackerValidationVariables::AVTrackStruct> vTrackstruct;
976  avalidator_.fillTrackQuantities(iEvent, vTrackstruct);
977 
978  for (std::vector<TrackerValidationVariables::AVTrackStruct>::const_iterator itT = vTrackstruct.begin();
979  itT != vTrackstruct.end();
980  ++itT) {
981 
982  // Fill 1D track histos
983  static const int etaindex = this->GetIndex(vTrackHistos_,"h_tracketa");
984  vTrackHistos_[etaindex]->Fill(itT->eta);
985  static const int phiindex = this->GetIndex(vTrackHistos_,"h_trackphi");
986  vTrackHistos_[phiindex]->Fill(itT->phi);
987  static const int numOfValidHitsindex = this->GetIndex(vTrackHistos_,"h_trackNumberOfValidHits");
988  vTrackHistos_[numOfValidHitsindex]->Fill(itT->numberOfValidHits);
989  static const int numOfLostHitsindex = this->GetIndex(vTrackHistos_,"h_trackNumberOfLostHits");
990  vTrackHistos_[numOfLostHitsindex]->Fill(itT->numberOfLostHits);
991  static const int kappaindex = this->GetIndex(vTrackHistos_,"h_curvature");
992  vTrackHistos_[kappaindex]->Fill(itT->kappa);
993  static const int kappaposindex = this->GetIndex(vTrackHistos_,"h_curvature_pos");
994  if (itT->charge > 0)
995  vTrackHistos_[kappaposindex]->Fill(fabs(itT->kappa));
996  static const int kappanegindex = this->GetIndex(vTrackHistos_,"h_curvature_neg");
997  if (itT->charge < 0)
998  vTrackHistos_[kappanegindex]->Fill(fabs(itT->kappa));
999  static const int normchi2index = this->GetIndex(vTrackHistos_,"h_normchi2");
1000  vTrackHistos_[normchi2index]->Fill(itT->normchi2);
1001  static const int chi2index = this->GetIndex(vTrackHistos_,"h_chi2");
1002  vTrackHistos_[chi2index]->Fill(itT->chi2);
1003  static const int chi2Probindex = this->GetIndex(vTrackHistos_,"h_chi2Prob");
1004  vTrackHistos_[chi2Probindex]->Fill(itT->chi2Prob);
1005  static const int ptindex = this->GetIndex(vTrackHistos_,"h_pt");
1006  vTrackHistos_[ptindex]->Fill(itT->pt);
1007  if (itT->ptError != 0.) {
1008  static const int ptResolutionindex = this->GetIndex(vTrackHistos_,"h_ptResolution");
1009  vTrackHistos_[ptResolutionindex]->Fill(itT->ptError/itT->pt);
1010  }
1011  // Fill track profiles
1012  static const int d0phiindex = this->GetIndex(vTrackProfiles_,"p_d0_vs_phi");
1013  vTrackProfiles_[d0phiindex]->Fill(itT->phi,itT->d0);
1014  static const int dzphiindex = this->GetIndex(vTrackProfiles_,"p_dz_vs_phi");
1015  vTrackProfiles_[dzphiindex]->Fill(itT->phi,itT->dz);
1016  static const int d0etaindex = this->GetIndex(vTrackProfiles_,"p_d0_vs_eta");
1017  vTrackProfiles_[d0etaindex]->Fill(itT->eta,itT->d0);
1018  static const int dzetaindex = this->GetIndex(vTrackProfiles_,"p_dz_vs_eta");
1019  vTrackProfiles_[dzetaindex]->Fill(itT->eta,itT->dz);
1020  static const int chiphiindex = this->GetIndex(vTrackProfiles_,"p_chi2_vs_phi");
1021  vTrackProfiles_[chiphiindex]->Fill(itT->phi,itT->chi2);
1022  static const int chiProbphiindex = this->GetIndex(vTrackProfiles_,"p_chi2Prob_vs_phi");
1023  vTrackProfiles_[chiProbphiindex]->Fill(itT->phi,itT->chi2Prob);
1024  static const int chiProbabsd0index = this->GetIndex(vTrackProfiles_,"p_chi2Prob_vs_d0");
1025  vTrackProfiles_[chiProbabsd0index]->Fill(fabs(itT->d0),itT->chi2Prob);
1026  static const int normchiphiindex = this->GetIndex(vTrackProfiles_,"p_normchi2_vs_phi");
1027  vTrackProfiles_[normchiphiindex]->Fill(itT->phi,itT->normchi2);
1028  static const int chietaindex = this->GetIndex(vTrackProfiles_,"p_chi2_vs_eta");
1029  vTrackProfiles_[chietaindex]->Fill(itT->eta,itT->chi2);
1030  static const int normchiptindex = this->GetIndex(vTrackProfiles_,"p_normchi2_vs_pt");
1031  vTrackProfiles_[normchiptindex]->Fill(itT->pt,itT->normchi2);
1032  static const int normchipindex = this->GetIndex(vTrackProfiles_,"p_normchi2_vs_p");
1033  vTrackProfiles_[normchipindex]->Fill(itT->p,itT->normchi2);
1034  static const int chiProbetaindex = this->GetIndex(vTrackProfiles_,"p_chi2Prob_vs_eta");
1035  vTrackProfiles_[chiProbetaindex]->Fill(itT->eta,itT->chi2Prob);
1036  static const int normchietaindex = this->GetIndex(vTrackProfiles_,"p_normchi2_vs_eta");
1037  vTrackProfiles_[normchietaindex]->Fill(itT->eta,itT->normchi2);
1038  static const int kappaphiindex = this->GetIndex(vTrackProfiles_,"p_kappa_vs_phi");
1039  vTrackProfiles_[kappaphiindex]->Fill(itT->phi,itT->kappa);
1040  static const int kappaetaindex = this->GetIndex(vTrackProfiles_,"p_kappa_vs_eta");
1041  vTrackProfiles_[kappaetaindex]->Fill(itT->eta,itT->kappa);
1042  static const int ptResphiindex = this->GetIndex(vTrackProfiles_,"p_ptResolution_vs_phi");
1043  vTrackProfiles_[ptResphiindex]->Fill(itT->phi,itT->ptError/itT->pt);
1044  static const int ptResetaindex = this->GetIndex(vTrackProfiles_,"p_ptResolution_vs_eta");
1045  vTrackProfiles_[ptResetaindex]->Fill(itT->eta,itT->ptError/itT->pt);
1046 
1047  // Fill 2D track histos
1048  static const int d0phiindex_2d = this->GetIndex(vTrack2DHistos_,"h2_d0_vs_phi");
1049  vTrack2DHistos_[d0phiindex_2d]->Fill(itT->phi,itT->d0);
1050  static const int dzphiindex_2d = this->GetIndex(vTrack2DHistos_,"h2_dz_vs_phi");
1051  vTrack2DHistos_[dzphiindex_2d]->Fill(itT->phi,itT->dz);
1052  static const int d0etaindex_2d = this->GetIndex(vTrack2DHistos_,"h2_d0_vs_eta");
1053  vTrack2DHistos_[d0etaindex_2d]->Fill(itT->eta,itT->d0);
1054  static const int dzetaindex_2d = this->GetIndex(vTrack2DHistos_,"h2_dz_vs_eta");
1055  vTrack2DHistos_[dzetaindex_2d]->Fill(itT->eta,itT->dz);
1056  static const int chiphiindex_2d = this->GetIndex(vTrack2DHistos_,"h2_chi2_vs_phi");
1057  vTrack2DHistos_[chiphiindex_2d]->Fill(itT->phi,itT->chi2);
1058  static const int chiProbphiindex_2d = this->GetIndex(vTrack2DHistos_,"h2_chi2Prob_vs_phi");
1059  vTrack2DHistos_[chiProbphiindex_2d]->Fill(itT->phi,itT->chi2Prob);
1060  static const int chiProbabsd0index_2d = this->GetIndex(vTrack2DHistos_,"h2_chi2Prob_vs_d0");
1061  vTrack2DHistos_[chiProbabsd0index_2d]->Fill(fabs(itT->d0),itT->chi2Prob);
1062  static const int normchiphiindex_2d = this->GetIndex(vTrack2DHistos_,"h2_normchi2_vs_phi");
1063  vTrack2DHistos_[normchiphiindex_2d]->Fill(itT->phi,itT->normchi2);
1064  static const int chietaindex_2d = this->GetIndex(vTrack2DHistos_,"h2_chi2_vs_eta");
1065  vTrack2DHistos_[chietaindex_2d]->Fill(itT->eta,itT->chi2);
1066  static const int chiProbetaindex_2d = this->GetIndex(vTrack2DHistos_,"h2_chi2Prob_vs_eta");
1067  vTrack2DHistos_[chiProbetaindex_2d]->Fill(itT->eta,itT->chi2Prob);
1068  static const int normchietaindex_2d = this->GetIndex(vTrack2DHistos_,"h2_normchi2_vs_eta");
1069  vTrack2DHistos_[normchietaindex_2d]->Fill(itT->eta,itT->normchi2);
1070  static const int kappaphiindex_2d = this->GetIndex(vTrack2DHistos_,"h2_kappa_vs_phi");
1071  vTrack2DHistos_[kappaphiindex_2d]->Fill(itT->phi,itT->kappa);
1072  static const int kappaetaindex_2d = this->GetIndex(vTrack2DHistos_,"h2_kappa_vs_eta");
1073  vTrack2DHistos_[kappaetaindex_2d]->Fill(itT->eta,itT->kappa);
1074  static const int normchi2kappa_2d = this->GetIndex(vTrack2DHistos_,"h2_normchi2_vs_kappa");
1075  vTrack2DHistos_[normchi2kappa_2d]->Fill(itT->normchi2,itT->kappa);
1076 
1077  // hit quantities: residuals, normalized residuals
1078  for (std::vector<TrackerValidationVariables::AVHitStruct>::const_iterator itH = itT->hits.begin();
1079  itH != itT->hits.end();
1080  ++itH) {
1081 
1082  DetId detid(itH->rawDetId);
1083  ModuleHistos &histStruct = this->getHistStructFromMap(detid);
1084 
1085  // fill histos in local coordinates if set in cf
1086  if (lCoorHistOn_) {
1087  histStruct.ResHisto->Fill(itH->resX);
1088  if(itH->resErrX != 0) histStruct.NormResHisto->Fill(itH->resX/itH->resErrX);
1089  if (this->isPixel(detid.subdetId()) || stripYResiduals_ ) {
1090  histStruct.ResYHisto->Fill(itH->resY);
1091  // here add un-primed normalised y-residuals if wanted
1092  }
1093  }
1094  if (itH->resXprime != -999.) {
1095  histStruct.ResXprimeHisto->Fill(itH->resXprime);
1096 
1097  /******************************* Fill 2-D histo ResX vs momenta *****************************/
1098  if (detid.subdetId() == PixelSubdetector::PixelBarrel) {
1099  static const int resXvsPindex_2d = this->GetIndex(vTrack2DHistos_,"p_vs_resXprime_pixB");
1100  vTrack2DHistos_[resXvsPindex_2d]->Fill(itT->p,itH->resXprime);
1101  }
1102  if (detid.subdetId() == PixelSubdetector::PixelEndcap) {
1103  static const int resXvsPindex_2d = this->GetIndex(vTrack2DHistos_,"p_vs_resXprime_pixE");
1104  vTrack2DHistos_[resXvsPindex_2d]->Fill(itT->p,itH->resXprime);
1105  }
1106  if (detid.subdetId() == StripSubdetector::TIB) {
1107  static const int resXvsPindex_2d = this->GetIndex(vTrack2DHistos_,"p_vs_resXprime_TIB");
1108  vTrack2DHistos_[resXvsPindex_2d]->Fill(itT->p,itH->resXprime);
1109  }
1110  if (detid.subdetId() == StripSubdetector::TID) {
1111  static const int resXvsPindex_2d = this->GetIndex(vTrack2DHistos_,"p_vs_resXprime_TID");
1112  vTrack2DHistos_[resXvsPindex_2d]->Fill(itT->p,itH->resXprime);
1113  }
1114  if (detid.subdetId() == StripSubdetector::TOB) {
1115  static const int resXvsPindex_2d = this->GetIndex(vTrack2DHistos_,"p_vs_resXprime_TOB");
1116  vTrack2DHistos_[resXvsPindex_2d]->Fill(itT->p,itH->resXprime);
1117  }
1118  if (detid.subdetId() == StripSubdetector::TEC) {
1119  static const int resXvsPindex_2d = this->GetIndex(vTrack2DHistos_,"p_vs_resXprime_TEC");
1120  vTrack2DHistos_[resXvsPindex_2d]->Fill(itT->p,itH->resXprime);
1121  }
1122  /******************************************/
1123 
1124  if ( moduleLevelProfiles_ && itH->inside ) {
1125  float tgalpha = tan(itH->localAlpha);
1126  if ( fabs(tgalpha)!=0 ){
1127  histStruct.LocalX->Fill(itH->localXnorm, tgalpha*tgalpha);
1128  histStruct.LocalY->Fill(itH->localYnorm, tgalpha*tgalpha);
1129 /* if (this->isEndCap(detid.subdetId()) && !this->isPixel(detid.subdetId())) {
1130  if((itH->resX)*(itH->resXprime)>0){
1131  histStruct.ResXvsXProfile->Fill(itH->localXnorm, itH->resXatTrkY/tgalpha, tgalpha*tgalpha);
1132  histStruct.ResXvsYProfile->Fill(itH->localYnorm, itH->resXatTrkY/tgalpha, tgalpha*tgalpha);
1133  } else {
1134  histStruct.ResXvsXProfile->Fill(itH->localXnorm, (-1)*itH->resXatTrkY/tgalpha, tgalpha*tgalpha);
1135  histStruct.ResXvsYProfile->Fill(itH->localYnorm, (-1)*itH->resXatTrkY/tgalpha, tgalpha*tgalpha);
1136  }
1137 
1138  }else {
1139 */
1140  histStruct.ResXvsXProfile->Fill(itH->localXnorm, itH->resXatTrkY/tgalpha, tgalpha*tgalpha);
1141  histStruct.ResXvsYProfile->Fill(itH->localYnorm, itH->resXatTrkY/tgalpha, tgalpha*tgalpha);
1142 
1143 // }
1144 
1145  }
1146  }
1147 
1148  if(itH->resXprimeErr != 0 && itH->resXprimeErr != -999 ) {
1149  histStruct.NormResXprimeHisto->Fill(itH->resXprime/itH->resXprimeErr);
1150  }
1151  }
1152 
1153  if (itH->resYprime != -999.) {
1154  if (this->isPixel(detid.subdetId()) || stripYResiduals_ ) {
1155  histStruct.ResYprimeHisto->Fill(itH->resYprime);
1156 
1157  /******************************* Fill 2-D histo ResY vs momenta *****************************/
1158  if (detid.subdetId() == PixelSubdetector::PixelBarrel) {
1159  static const int resYvsPindex_2d = this->GetIndex(vTrack2DHistos_,"p_vs_resYprime_pixB");
1160  vTrack2DHistos_[resYvsPindex_2d]->Fill(itT->p,itH->resYprime);
1161  }
1162  if (detid.subdetId() == PixelSubdetector::PixelEndcap) {
1163  static const int resYvsPindex_2d = this->GetIndex(vTrack2DHistos_,"p_vs_resYprime_pixE");
1164  vTrack2DHistos_[resYvsPindex_2d]->Fill(itT->p,itH->resYprime);
1165  }
1166  /******************************************/
1167 
1168  if ( moduleLevelProfiles_ && itH->inside ) {
1169  float tgbeta = tan(itH->localBeta);
1170  if ( fabs(tgbeta)!=0 ){
1171 /* if (this->isEndCap(detid.subdetId()) && !this->isPixel(detid.subdetId())) {
1172 
1173  if((itH->resY)*(itH->resYprime)>0){
1174  histStruct.ResYvsXProfile->Fill(itH->localXnorm, itH->resYprime/tgbeta, tgbeta*tgbeta);
1175  histStruct.ResYvsYProfile->Fill(itH->localYnorm, itH->resYprime/tgbeta, tgbeta*tgbeta);
1176  } else {
1177  histStruct.ResYvsXProfile->Fill(itH->localXnorm, (-1)*itH->resYprime/tgbeta, tgbeta*tgbeta);
1178  histStruct.ResYvsYProfile->Fill(itH->localYnorm, (-1)*itH->resYprime/tgbeta, tgbeta*tgbeta);
1179  }
1180 
1181  }else {
1182 */
1183  histStruct.ResYvsXProfile->Fill(itH->localXnorm, itH->resY/tgbeta, tgbeta*tgbeta);
1184  histStruct.ResYvsYProfile->Fill(itH->localYnorm, itH->resY/tgbeta, tgbeta*tgbeta);
1185 // }
1186  }
1187  }
1188 
1189  if (itH->resYprimeErr != 0 && itH->resYprimeErr != -999. ) {
1190  histStruct.NormResYprimeHisto->Fill(itH->resYprime/itH->resYprimeErr);
1191  }
1192  }
1193  }
1194 
1195  } // finish loop over hit quantities
1196  } // finish loop over track quantities
1197 
1198  if (useOverflowForRMS_) TH1::StatOverflows(kFALSE);
1199 }
bool isPixel(uint32_t subDetId)
std::vector< TH1 * > vTrack2DHistos_
int GetIndex(const std::vector< OBJECT_TYPE * > &vec, const TString &name)
ModuleHistos & getHistStructFromMap(const DetId &detid)
Tan< T >::type tan(const T &t)
Definition: Tan.h:22
virtual void checkBookHists(const edm::EventSetup &setup)
Definition: DetId.h:18
std::vector< TH1 * > vTrackProfiles_
const edm::ParameterSet parSet_
void TrackerOfflineValidation::bookDirHists ( DirectoryWrapper tfd,
const Alignable ali,
const TrackerTopology tTopo 
)
private

Definition at line 594 of file TrackerOfflineValidation.cc.

References Alignable::alignableObjectId(), bookHists(), makeMuonMisalignmentScenario::components, Alignable::components(), dqmMode_, f, i, AlignableObjectId::idToString(), isDetOrDetUnit(), LogDebug, moduleDirectory_, findQualityFiles::size, and AlCaHLTBitMon_QueryRunRegistry::string.

Referenced by checkBookHists().

595 {
596  std::vector<Alignable*> alivec(ali.components());
597  for(int i=0, iEnd = ali.components().size();i < iEnd; ++i) {
598  std::string structurename = AlignableObjectId::idToString((alivec)[i]->alignableObjectId());
599  LogDebug("TrackerOfflineValidation") << "StructureName = " << structurename;
600  std::stringstream dirname;
601  dirname << structurename;
602  // add no suffix counter to Strip and Pixel, just aesthetics
603  if (structurename != "Strip" && structurename != "Pixel") dirname << "_" << i+1;
604 
605  if (structurename.find("Endcap",0) != std::string::npos ) {
606  DirectoryWrapper f(tfd,dirname.str(),moduleDirectory_,dqmMode_);
607  bookHists(f, *(alivec)[i], tTopo, ali.alignableObjectId() , i);
608  bookDirHists( f, *(alivec)[i], tTopo);
609  } else if( !(this->isDetOrDetUnit( (alivec)[i]->alignableObjectId()) )
610  || alivec[i]->components().size() > 1) {
611  DirectoryWrapper f(tfd,dirname.str(),moduleDirectory_,dqmMode_);
612  bookHists(tfd, *(alivec)[i], tTopo, ali.alignableObjectId() , i);
613  bookDirHists( f, *(alivec)[i], tTopo);
614  } else {
615  bookHists(tfd, *(alivec)[i], tTopo, ali.alignableObjectId() , i);
616  }
617  }
618 }
#define LogDebug(id)
int i
Definition: DBlmapReader.cc:9
virtual Alignables components() const =0
Return vector of all direct components.
virtual StructureType alignableObjectId() const =0
Return the alignable type identifier.
double f[11][100]
bool isDetOrDetUnit(align::StructureType type)
void bookDirHists(DirectoryWrapper &tfd, const Alignable &ali, const TrackerTopology *tTopo)
static const char * idToString(align::StructureType type)
tuple size
Write out results.
void bookHists(DirectoryWrapper &tfd, const Alignable &ali, const TrackerTopology *tTopo, align::StructureType type, int i)
void TrackerOfflineValidation::bookGlobalHists ( DirectoryWrapper tfd)
private

Definition at line 422 of file TrackerOfflineValidation.cc.

References TrackerOfflineValidation::DirectoryWrapper::make(), vTrack2DHistos_, vTrackHistos_, and vTrackProfiles_.

Referenced by checkBookHists().

423 {
424 
425  vTrackHistos_.push_back(tfd.make<TH1F>("h_tracketa",
426  "Track #eta;#eta_{Track};Number of Tracks",
427  90,-3.,3.));
428  vTrackHistos_.push_back(tfd.make<TH1F>("h_trackphi",
429  "Track #phi;#phi_{Track};Number of Tracks",
430  90,-3.15,3.15));
431  vTrackHistos_.push_back(tfd.make<TH1F>("h_trackNumberOfValidHits",
432  "Track # of valid hits;# of valid hits _{Track};Number of Tracks",
433  40,0.,40.));
434  vTrackHistos_.push_back(tfd.make<TH1F>("h_trackNumberOfLostHits",
435  "Track # of lost hits;# of lost hits _{Track};Number of Tracks",
436  10,0.,10.));
437  vTrackHistos_.push_back(tfd.make<TH1F>("h_curvature",
438  "Curvature #kappa;#kappa_{Track};Number of Tracks",
439  100,-.05,.05));
440  vTrackHistos_.push_back(tfd.make<TH1F>("h_curvature_pos",
441  "Curvature |#kappa| Positive Tracks;|#kappa_{pos Track}|;Number of Tracks",
442  100,.0,.05));
443  vTrackHistos_.push_back(tfd.make<TH1F>("h_curvature_neg",
444  "Curvature |#kappa| Negative Tracks;|#kappa_{neg Track}|;Number of Tracks",
445  100,.0,.05));
446  vTrackHistos_.push_back(tfd.make<TH1F>("h_diff_curvature",
447  "Curvature |#kappa| Tracks Difference;|#kappa_{Track}|;# Pos Tracks - # Neg Tracks",
448  100,.0,.05));
449  vTrackHistos_.push_back(tfd.make<TH1F>("h_chi2",
450  "#chi^{2};#chi^{2}_{Track};Number of Tracks",
451  500,-0.01,500.));
452  vTrackHistos_.push_back(tfd.make<TH1F>("h_chi2Prob",
453  "#chi^{2} probability;#chi^{2}prob_{Track};Number of Tracks",
454  100,0.0,1.));
455  vTrackHistos_.push_back(tfd.make<TH1F>("h_normchi2",
456  "#chi^{2}/ndof;#chi^{2}/ndof;Number of Tracks",
457  100,-0.01,10.));
458  vTrackHistos_.push_back(tfd.make<TH1F>("h_pt",
459  "p_{T}^{track};p_{T}^{track} [GeV];Number of Tracks",
460  250,0.,250));
461  vTrackHistos_.push_back(tfd.make<TH1F>("h_ptResolution",
462  "#delta_{p_{T}}/p_{T}^{track};#delta_{p_{T}}/p_{T}^{track};Number of Tracks",
463  100,0.,0.5));
464  vTrackProfiles_.push_back(tfd.make<TProfile>("p_d0_vs_phi",
465  "Transverse Impact Parameter vs. #phi;#phi_{Track};#LT d_{0} #GT [cm]",
466  100,-3.15,3.15));
467  vTrackProfiles_.push_back(tfd.make<TProfile>("p_dz_vs_phi",
468  "Longitudinal Impact Parameter vs. #phi;#phi_{Track};#LT d_{z} #GT [cm]",
469  100,-3.15,3.15));
470  vTrackProfiles_.push_back(tfd.make<TProfile>("p_d0_vs_eta",
471  "Transverse Impact Parameter vs. #eta;#eta_{Track};#LT d_{0} #GT [cm]",
472  100,-3.15,3.15));
473  vTrackProfiles_.push_back(tfd.make<TProfile>("p_dz_vs_eta",
474  "Longitudinal Impact Parameter vs. #eta;#eta_{Track};#LT d_{z} #GT [cm]",
475  100,-3.15,3.15));
476  vTrackProfiles_.push_back(tfd.make<TProfile>("p_chi2_vs_phi",
477  "#chi^{2} vs. #phi;#phi_{Track};#LT #chi^{2} #GT",
478  100,-3.15,3.15));
479  vTrackProfiles_.push_back(tfd.make<TProfile>("p_chi2Prob_vs_phi",
480  "#chi^{2} probablility vs. #phi;#phi_{Track};#LT #chi^{2} probability#GT",
481  100,-3.15,3.15));
482  vTrackProfiles_.push_back(tfd.make<TProfile>("p_chi2Prob_vs_d0",
483  "#chi^{2} probablility vs. |d_{0}|;|d_{0}|[cm];#LT #chi^{2} probability#GT",
484  100,0,80));
485  vTrackProfiles_.push_back(tfd.make<TProfile>("p_normchi2_vs_phi",
486  "#chi^{2}/ndof vs. #phi;#phi_{Track};#LT #chi^{2}/ndof #GT",
487  100,-3.15,3.15));
488  vTrackProfiles_.push_back(tfd.make<TProfile>("p_chi2_vs_eta",
489  "#chi^{2} vs. #eta;#eta_{Track};#LT #chi^{2} #GT",
490  100,-3.15,3.15));
491  //variable binning for chi2/ndof vs. pT
492  double xBins[19]={0.,0.15,0.5,1.,1.5,2.,2.5,3.,3.5,4.,4.5,5.,7.,10.,15.,25.,40.,100.,200.};
493  vTrackProfiles_.push_back(tfd.make<TProfile>("p_normchi2_vs_pt",
494  "norm #chi^{2} vs. p_{T}_{Track}; p_{T}_{Track};#LT #chi^{2}/ndof #GT",
495  18,xBins));
496 
497  vTrackProfiles_.push_back(tfd.make<TProfile>("p_normchi2_vs_p",
498  "#chi^{2}/ndof vs. p_{Track};p_{Track};#LT #chi^{2}/ndof #GT",
499  18,xBins));
500  vTrackProfiles_.push_back(tfd.make<TProfile>("p_chi2Prob_vs_eta",
501  "#chi^{2} probability vs. #eta;#eta_{Track};#LT #chi^{2} probability #GT",
502  100,-3.15,3.15));
503  vTrackProfiles_.push_back(tfd.make<TProfile>("p_normchi2_vs_eta",
504  "#chi^{2}/ndof vs. #eta;#eta_{Track};#LT #chi^{2}/ndof #GT",
505  100,-3.15,3.15));
506  vTrackProfiles_.push_back(tfd.make<TProfile>("p_kappa_vs_phi",
507  "#kappa vs. #phi;#phi_{Track};#kappa",
508  100,-3.15,3.15));
509  vTrackProfiles_.push_back(tfd.make<TProfile>("p_kappa_vs_eta",
510  "#kappa vs. #eta;#eta_{Track};#kappa",
511  100,-3.15,3.15));
512  vTrackProfiles_.push_back(tfd.make<TProfile>("p_ptResolution_vs_phi",
513  "#delta_{p_{T}}/p_{T}^{track};#phi^{track};#delta_{p_{T}}/p_{T}^{track}",
514  100, -3.15,3.15));
515  vTrackProfiles_.push_back(tfd.make<TProfile>("p_ptResolution_vs_eta",
516  "#delta_{p_{T}}/p_{T}^{track};#eta^{track};#delta_{p_{T}}/p_{T}^{track}",
517  100, -3.15,3.15));
518 
519  vTrack2DHistos_.push_back(tfd.make<TH2F>("h2_d0_vs_phi",
520  "Transverse Impact Parameter vs. #phi;#phi_{Track};d_{0} [cm]",
521  100, -3.15, 3.15, 100,-1.,1.) );
522  vTrack2DHistos_.push_back(tfd.make<TH2F>("h2_dz_vs_phi",
523  "Longitudinal Impact Parameter vs. #phi;#phi_{Track};d_{z} [cm]",
524  100, -3.15, 3.15, 100,-100.,100.));
525  vTrack2DHistos_.push_back(tfd.make<TH2F>("h2_d0_vs_eta",
526  "Transverse Impact Parameter vs. #eta;#eta_{Track};d_{0} [cm]",
527  100, -3.15, 3.15, 100,-1.,1.));
528  vTrack2DHistos_.push_back(tfd.make<TH2F>("h2_dz_vs_eta",
529  "Longitudinal Impact Parameter vs. #eta;#eta_{Track};d_{z} [cm]",
530  100, -3.15, 3.15, 100,-100.,100.));
531  vTrack2DHistos_.push_back(tfd.make<TH2F>("h2_chi2_vs_phi",
532  "#chi^{2} vs. #phi;#phi_{Track};#chi^{2}",
533  100, -3.15, 3.15, 500, 0., 500.));
534  vTrack2DHistos_.push_back(tfd.make<TH2F>("h2_chi2Prob_vs_phi",
535  "#chi^{2} probability vs. #phi;#phi_{Track};#chi^{2} probability",
536  100, -3.15, 3.15, 100, 0., 1.));
537  vTrack2DHistos_.push_back(tfd.make<TH2F>("h2_chi2Prob_vs_d0",
538  "#chi^{2} probability vs. |d_{0}|;|d_{0}| [cm];#chi^{2} probability",
539  100, 0, 80, 100, 0., 1.));
540  vTrack2DHistos_.push_back(tfd.make<TH2F>("h2_normchi2_vs_phi",
541  "#chi^{2}/ndof vs. #phi;#phi_{Track};#chi^{2}/ndof",
542  100, -3.15, 3.15, 100, 0., 10.));
543  vTrack2DHistos_.push_back(tfd.make<TH2F>("h2_chi2_vs_eta",
544  "#chi^{2} vs. #eta;#eta_{Track};#chi^{2}",
545  100, -3.15, 3.15, 500, 0., 500.));
546  vTrack2DHistos_.push_back(tfd.make<TH2F>("h2_chi2Prob_vs_eta",
547  "#chi^{2} probaility vs. #eta;#eta_{Track};#chi^{2} probability",
548  100, -3.15, 3.15, 100, 0., 1.));
549  vTrack2DHistos_.push_back(tfd.make<TH2F>("h2_normchi2_vs_eta",
550  "#chi^{2}/ndof vs. #eta;#eta_{Track};#chi^{2}/ndof",
551  100,-3.15,3.15, 100, 0., 10.));
552  vTrack2DHistos_.push_back(tfd.make<TH2F>("h2_kappa_vs_phi",
553  "#kappa vs. #phi;#phi_{Track};#kappa",
554  100,-3.15,3.15, 100, .0,.05));
555  vTrack2DHistos_.push_back(tfd.make<TH2F>("h2_kappa_vs_eta",
556  "#kappa vs. #eta;#eta_{Track};#kappa",
557  100,-3.15,3.15, 100, .0,.05));
558  vTrack2DHistos_.push_back(tfd.make<TH2F>("h2_normchi2_vs_kappa",
559  "#kappa vs. #chi^{2}/ndof;#chi^{2}/ndof;#kappa",
560  100,0.,10, 100,-.03,.03));
561 
562  /****************** Definition of 2-D Histos of ResX vs momenta ****************************/
563  vTrack2DHistos_.push_back(tfd.make<TH2F>("p_vs_resXprime_pixB",
564  "res_{x'} vs momentum in BPix;p [GeV]; res_{x'}",
565  15,0.,15., 200, -0.1,0.1));
566  vTrack2DHistos_.push_back(tfd.make<TH2F>("p_vs_resXprime_pixE",
567  "res_{x'} vs momentum in FPix;p [GeV]; res_{x'}",
568  15,0.,15., 200, -0.1,0.1));
569  vTrack2DHistos_.push_back(tfd.make<TH2F>("p_vs_resXprime_TIB",
570  "res_{x'} vs momentum in TIB;p [GeV]; res_{x'}",
571  15,0.,15., 200, -0.1,0.1));
572  vTrack2DHistos_.push_back(tfd.make<TH2F>("p_vs_resXprime_TID",
573  "res_{x'} vs momentum in TID;p [GeV]; res_{x'}",
574  15,0.,15., 200, -0.1,0.1));
575  vTrack2DHistos_.push_back(tfd.make<TH2F>("p_vs_resXprime_TOB",
576  "res_{x'} vs momentum in TOB;p [GeV]; res_{x'}",
577  15,0.,15., 200, -0.1,0.1));
578  vTrack2DHistos_.push_back(tfd.make<TH2F>("p_vs_resXprime_TEC",
579  "res_{x'} vs momentum in TEC;p [GeV]; res_{x'}",
580  15,0.,15., 200, -0.1,0.1));
581 
582  /****************** Definition of 2-D Histos of ResY vs momenta ****************************/
583  vTrack2DHistos_.push_back(tfd.make<TH2F>("p_vs_resYprime_pixB",
584  "res_{y'} vs momentum in BPix;p [GeV]; res_{y'}",
585  15,0.,15., 200, -0.1,0.1));
586  vTrack2DHistos_.push_back(tfd.make<TH2F>("p_vs_resYprime_pixE",
587  "res_{y'} vs momentum in FPix;p [GeV]; res_{y'}",
588  15,0.,15., 200, -0.1,0.1));
589 
590 }
std::vector< TH1 * > vTrack2DHistos_
std::vector< TH1 * > vTrackProfiles_
void TrackerOfflineValidation::bookHists ( DirectoryWrapper tfd,
const Alignable ali,
const TrackerTopology tTopo,
align::StructureType  type,
int  i 
)
private

Definition at line 622 of file TrackerOfflineValidation.cc.

References align::AlignableDetUnit, Alignable::alignableObjectId(), bookTH1F(), bookTProfile(), dqmMode_, getBinning(), getHistStructFromMap(), Alignable::id(), align::invalid, isBarrel(), isDetOrDetUnit(), isEndCap(), isPixel(), lCoorHistOn_, TrackerOfflineValidation::ModuleHistos::LocalX, TrackerOfflineValidation::ModuleHistos::LocalY, moduleLevelHistsTransient_, moduleLevelProfiles_, pileupCalc::nbins, TrackerOfflineValidation::ModuleHistos::NormResHisto, TrackerOfflineValidation::ModuleHistos::NormResXprimeHisto, TrackerOfflineValidation::ModuleHistos::NormResYprimeHisto, NormXprimeResidual, NormXResidual, NormYprimeResidual, TrackerOfflineValidation::ModuleHistos::ResHisto, TrackerOfflineValidation::ModuleHistos::ResXprimeHisto, TrackerOfflineValidation::ModuleHistos::ResXvsXProfile, TrackerOfflineValidation::ModuleHistos::ResXvsYProfile, TrackerOfflineValidation::ModuleHistos::ResYHisto, TrackerOfflineValidation::ModuleHistos::ResYprimeHisto, TrackerOfflineValidation::ModuleHistos::ResYvsXProfile, TrackerOfflineValidation::ModuleHistos::ResYvsYProfile, AlCaHLTBitMon_QueryRunRegistry::string, stripYResiduals_, TrackerAlignableId::typeAndLayerFromDetId(), SiStripMonitorClusterAlca_cfi::xmax, SiStripMonitorClusterAlca_cfi::xmin, XprimeResidual, XResidual, XResidualProfile, SiStripMonitorClusterAlca_cfi::ymax, SiStripMonitorClusterAlca_cfi::ymin, YprimeResidual, YResidual, and YResidualProfile.

Referenced by bookDirHists().

623 {
624  TrackerAlignableId aliid;
625  const DetId id = ali.id();
626 
627  // comparing subdetandlayer to subdetIds gives a warning at compile time
628  // -> subdetandlayer could also be pair<uint,uint> but this has to be adapted
629  // in AlignableObjId
630  std::pair<int,int> subdetandlayer = aliid.typeAndLayerFromDetId(id, tTopo);
631 
633 
634  // are we on or just above det, detunit level respectively?
635  if (type == align::AlignableDetUnit )subtype = type;
636  else if( this->isDetOrDetUnit(ali.alignableObjectId()) ) subtype = ali.alignableObjectId();
637 
638  // construct histogramm title and name
639  std::stringstream histoname, histotitle, normhistoname, normhistotitle,
640  yhistoname, yhistotitle,
641  xprimehistoname, xprimehistotitle, normxprimehistoname, normxprimehistotitle,
642  yprimehistoname, yprimehistotitle, normyprimehistoname, normyprimehistotitle,
643  localxname, localxtitle, localyname, localytitle,
644  resxvsxprofilename, resxvsxprofiletitle, resyvsxprofilename, resyvsxprofiletitle,
645  resxvsyprofilename, resxvsyprofiletitle, resyvsyprofilename, resyvsyprofiletitle;
646 
647  std::string wheel_or_layer;
648 
649  if( this->isEndCap(static_cast<uint32_t>(subdetandlayer.first)) ) wheel_or_layer = "_wheel_";
650  else if ( this->isBarrel(static_cast<uint32_t>(subdetandlayer.first)) ) wheel_or_layer = "_layer_";
651  else edm::LogWarning("TrackerOfflineValidation") << "@SUB=TrackerOfflineValidation::bookHists"
652  << "Unknown subdetid: " << subdetandlayer.first;
653 
654  histoname << "h_residuals_subdet_" << subdetandlayer.first
655  << wheel_or_layer << subdetandlayer.second << "_module_" << id.rawId();
656  yhistoname << "h_y_residuals_subdet_" << subdetandlayer.first
657  << wheel_or_layer << subdetandlayer.second << "_module_" << id.rawId();
658  xprimehistoname << "h_xprime_residuals_subdet_" << subdetandlayer.first
659  << wheel_or_layer << subdetandlayer.second << "_module_" << id.rawId();
660  yprimehistoname << "h_yprime_residuals_subdet_" << subdetandlayer.first
661  << wheel_or_layer << subdetandlayer.second << "_module_" << id.rawId();
662  normhistoname << "h_normresiduals_subdet_" << subdetandlayer.first
663  << wheel_or_layer << subdetandlayer.second << "_module_" << id.rawId();
664  normxprimehistoname << "h_normxprimeresiduals_subdet_" << subdetandlayer.first
665  << wheel_or_layer << subdetandlayer.second << "_module_" << id.rawId();
666  normyprimehistoname << "h_normyprimeresiduals_subdet_" << subdetandlayer.first
667  << wheel_or_layer << subdetandlayer.second << "_module_" << id.rawId();
668  histotitle << "X Residual for module " << id.rawId() << ";x_{tr} - x_{hit} [cm]";
669  yhistotitle << "Y Residual for module " << id.rawId() << ";y_{tr} - y_{hit} [cm]";
670  normhistotitle << "Normalized Residual for module " << id.rawId() << ";x_{tr} - x_{hit}/#sigma";
671  xprimehistotitle << "X' Residual for module " << id.rawId() << ";(x_{tr} - x_{hit})' [cm]";
672  normxprimehistotitle << "Normalized X' Residual for module " << id.rawId() << ";(x_{tr} - x_{hit})'/#sigma";
673  yprimehistotitle << "Y' Residual for module " << id.rawId() << ";(y_{tr} - y_{hit})' [cm]";
674  normyprimehistotitle << "Normalized Y' Residual for module " << id.rawId() << ";(y_{tr} - y_{hit})'/#sigma";
675 
676  if ( moduleLevelProfiles_ ) {
677  localxname << "h_localx_subdet_" << subdetandlayer.first
678  << wheel_or_layer << subdetandlayer.second << "_module_" << id.rawId();
679  localyname << "h_localy_subdet_" << subdetandlayer.first
680  << wheel_or_layer << subdetandlayer.second << "_module_" << id.rawId();
681  localxtitle << "u local for module " << id.rawId() << "; u_{tr,r}";
682  localytitle << "v local for module " << id.rawId() << "; v_{tr,r}";
683 
684  resxvsxprofilename << "p_residuals_x_vs_x_subdet_" << subdetandlayer.first
685  << wheel_or_layer << subdetandlayer.second << "_module_" << id.rawId();
686  resyvsxprofilename << "p_residuals_y_vs_x_subdet_" << subdetandlayer.first
687  << wheel_or_layer << subdetandlayer.second << "_module_" << id.rawId();
688  resxvsyprofilename << "p_residuals_x_vs_y_subdet_" << subdetandlayer.first
689  << wheel_or_layer << subdetandlayer.second << "_module_" << id.rawId();
690  resyvsyprofilename << "p_residuals_y_vs_y_subdet_" << subdetandlayer.first
691  << wheel_or_layer << subdetandlayer.second << "_module_" << id.rawId();
692  resxvsxprofiletitle << "U Residual vs u for module " << id.rawId() << "; u_{tr,r} ;(u_{tr} - u_{hit})/tan#alpha [cm]";
693  resyvsxprofiletitle << "V Residual vs u for module " << id.rawId() << "; u_{tr,r} ;(v_{tr} - v_{hit})/tan#beta [cm]";
694  resxvsyprofiletitle << "U Residual vs v for module " << id.rawId() << "; v_{tr,r} ;(u_{tr} - u_{hit})/tan#alpha [cm]";
695  resyvsyprofiletitle << "V Residual vs v for module " << id.rawId() << "; v_{tr,r} ;(v_{tr} - v_{hit})/tan#beta [cm]";
696  }
697 
698  if( this->isDetOrDetUnit( subtype ) ) {
699  ModuleHistos &histStruct = this->getHistStructFromMap(id);
700  int nbins = 0;
701  double xmin = 0., xmax = 0.;
702  double ymin = -0.1, ymax = 0.1;
703 
704  // do not allow transient hists in DQM mode
705  bool moduleLevelHistsTransient(moduleLevelHistsTransient_);
706  if (dqmMode_) moduleLevelHistsTransient = false;
707 
708  // decide via cfg if hists in local coordinates should be booked
709  if(lCoorHistOn_) {
710  this->getBinning(id.subdetId(), XResidual, nbins, xmin, xmax);
711  histStruct.ResHisto = this->bookTH1F(moduleLevelHistsTransient, tfd,
712  histoname.str().c_str(),histotitle.str().c_str(),
713  nbins, xmin, xmax);
714  this->getBinning(id.subdetId(), NormXResidual, nbins, xmin, xmax);
715  histStruct.NormResHisto = this->bookTH1F(moduleLevelHistsTransient, tfd,
716  normhistoname.str().c_str(),normhistotitle.str().c_str(),
717  nbins, xmin, xmax);
718  }
719  this->getBinning(id.subdetId(), XprimeResidual, nbins, xmin, xmax);
720  histStruct.ResXprimeHisto = this->bookTH1F(moduleLevelHistsTransient, tfd,
721  xprimehistoname.str().c_str(),xprimehistotitle.str().c_str(),
722  nbins, xmin, xmax);
723  this->getBinning(id.subdetId(), NormXprimeResidual, nbins, xmin, xmax);
724  histStruct.NormResXprimeHisto = this->bookTH1F(moduleLevelHistsTransient, tfd,
725  normxprimehistoname.str().c_str(),normxprimehistotitle.str().c_str(),
726  nbins, xmin, xmax);
727 
728  if ( moduleLevelProfiles_ ) {
729  this->getBinning(id.subdetId(), XResidualProfile, nbins, xmin, xmax);
730 
731  histStruct.LocalX = this->bookTH1F(moduleLevelHistsTransient, tfd,
732  localxname.str().c_str(),localxtitle.str().c_str(),
733  nbins, xmin, xmax);
734  histStruct.LocalY = this->bookTH1F(moduleLevelHistsTransient, tfd,
735  localyname.str().c_str(),localytitle.str().c_str(),
736  nbins, xmin, xmax);
737  histStruct.ResXvsXProfile = this->bookTProfile(moduleLevelHistsTransient, tfd,
738  resxvsxprofilename.str().c_str(),resxvsxprofiletitle.str().c_str(),
739  nbins, xmin, xmax, ymin, ymax);
740  histStruct.ResXvsXProfile->Sumw2(); // to be filled with weights, so uncertainties need sum of square of weights
741  histStruct.ResXvsYProfile = this->bookTProfile(moduleLevelHistsTransient, tfd,
742  resxvsyprofilename.str().c_str(),resxvsyprofiletitle.str().c_str(),
743  nbins, xmin, xmax, ymin, ymax);
744  histStruct.ResXvsYProfile->Sumw2(); // to be filled with weights, so uncertainties need sum of square of weights
745  }
746 
747  if( this->isPixel(subdetandlayer.first) || stripYResiduals_ ) {
748  this->getBinning(id.subdetId(), YprimeResidual, nbins, xmin, xmax);
749  histStruct.ResYprimeHisto = this->bookTH1F(moduleLevelHistsTransient, tfd,
750  yprimehistoname.str().c_str(),yprimehistotitle.str().c_str(),
751  nbins, xmin, xmax);
752  if (lCoorHistOn_) { // un-primed y-residual
753  this->getBinning(id.subdetId(), YResidual, nbins, xmin, xmax);
754  histStruct.ResYHisto = this->bookTH1F(moduleLevelHistsTransient, tfd,
755  yhistoname.str().c_str(), yhistotitle.str().c_str(),
756  nbins, xmin, xmax);
757  }
758  this->getBinning(id.subdetId(), NormYprimeResidual, nbins, xmin, xmax);
759  histStruct.NormResYprimeHisto = this->bookTH1F(moduleLevelHistsTransient, tfd,
760  normyprimehistoname.str().c_str(),normyprimehistotitle.str().c_str(),
761  nbins, xmin, xmax);
762  // Here we could add un-primed normalised y-residuals if(lCoorHistOn_)...
763  if ( moduleLevelProfiles_ ) {
764  this->getBinning(id.subdetId(), YResidualProfile, nbins, xmin, xmax);
765 
766  histStruct.ResYvsXProfile = this->bookTProfile(moduleLevelHistsTransient, tfd,
767  resyvsxprofilename.str().c_str(),resyvsxprofiletitle.str().c_str(),
768  nbins, xmin, xmax, ymin, ymax);
769  histStruct.ResYvsXProfile->Sumw2(); // to be filled with weights, so uncertainties need sum of square of weights
770  histStruct.ResYvsYProfile = this->bookTProfile(moduleLevelHistsTransient, tfd,
771  resyvsyprofilename.str().c_str(),resyvsyprofiletitle.str().c_str(),
772  nbins, xmin, xmax, ymin, ymax);
773  histStruct.ResYvsYProfile->Sumw2(); // to be filled with weights, so uncertainties need sum of square of weights
774  }
775  }
776  }
777 }
type
Definition: HCALResponse.h:21
align::ID id() const
Return the ID of Alignable, i.e. DetId of &#39;first&#39; component GeomDet(Unit).
Definition: Alignable.h:180
std::pair< int, int > typeAndLayerFromDetId(const DetId &detId, const TrackerTopology *tTopo) const
bool isPixel(uint32_t subDetId)
TH1 * bookTH1F(bool isTransient, DirectoryWrapper &tfd, const char *histName, const char *histTitle, int nBinsX, double lowX, double highX)
ModuleHistos & getHistStructFromMap(const DetId &detid)
void getBinning(uint32_t subDetId, TrackerOfflineValidation::HistogrammType residualtype, int &nBinsX, double &lowerBoundX, double &upperBoundX)
virtual StructureType alignableObjectId() const =0
Return the alignable type identifier.
TProfile * bookTProfile(bool isTransient, DirectoryWrapper &tfd, const char *histName, const char *histTitle, int nBinsX, double lowX, double highX)
bool isDetOrDetUnit(align::StructureType type)
Definition: DetId.h:18
bool isEndCap(uint32_t subDetId)
bool isBarrel(uint32_t subDetId)
TrackerOfflineValidation::SummaryContainer TrackerOfflineValidation::bookSummaryHists ( DirectoryWrapper tfd,
const Alignable ali,
align::StructureType  type,
int  i 
)
private

Definition at line 1297 of file TrackerOfflineValidation.cc.

References align::AlignableDet, align::AlignableDetUnit, Alignable::alignableObjectId(), Alignable::components(), cond::rpcobgas::detid, getBinning(), getHistStructFromMap(), Alignable::id(), AlignableObjectId::idToString(), isPixel(), j, relval_steps::k, TrackerOfflineValidation::DirectoryWrapper::make(), pileupCalc::nbins, TrackerOfflineValidation::ModuleHistos::NormResXprimeHisto, TrackerOfflineValidation::ModuleHistos::NormResYprimeHisto, NormXprimeResidual, NormYprimeResidual, TrackerOfflineValidation::ModuleHistos::ResXprimeHisto, TrackerOfflineValidation::ModuleHistos::ResYprimeHisto, stripYResiduals_, DetId::subdetId(), summarizeBinInContainer(), indexGen::title, SiStripMonitorClusterAlca_cfi::xmax, SiStripMonitorClusterAlca_cfi::xmin, XprimeResidual, and YprimeResidual.

Referenced by collateSummaryHists().

1299 {
1300  const uint aliSize = ali.components().size();
1301  const align::StructureType alitype = ali.alignableObjectId();
1302  const align::StructureType subtype = ali.components()[0]->alignableObjectId();
1303  const char *aliTypeName = AlignableObjectId::idToString(alitype); // lifetime of char* OK
1304  const char *aliSubtypeName = AlignableObjectId::idToString(subtype);
1305  const char *typeName = AlignableObjectId::idToString(type);
1306 
1307  const DetId aliDetId = ali.id();
1308  // y residuals only if pixel or specially requested for strip:
1309  const bool bookResidY = this->isPixel(aliDetId.subdetId()) || stripYResiduals_;
1310 
1311  SummaryContainer sumContainer;
1312 
1313  // Book summary hists with one bin per component,
1314  // but special case for Det with two DetUnit that we want to summarize one level up
1315  // (e.g. in TOBRods with 12 bins for 6 stereo and 6 rphi DetUnit.)
1316  // component of ali is not Det or Det with just one components
1317  const uint subcompSize = ali.components()[0]->components().size();
1318  if (subtype != align::AlignableDet || subcompSize == 1) { // Det with 1 comp. should not exist anymore...
1319  const TString title(Form("Summary for substructures in %s %d;%s;",aliTypeName,i,aliSubtypeName));
1320 
1321  sumContainer.summaryXResiduals_ = tfd.make<TH1F>(Form("h_summaryX%s_%d",aliTypeName,i),
1322  title + "#LT #Delta x' #GT",
1323  aliSize, 0.5, aliSize+0.5);
1324  sumContainer.summaryNormXResiduals_ = tfd.make<TH1F>(Form("h_summaryNormX%s_%d",aliTypeName,i),
1325  title + "#LT #Delta x'/#sigma #GT",
1326  aliSize,0.5,aliSize+0.5);
1327 
1328  if (bookResidY) {
1329  sumContainer.summaryYResiduals_ = tfd.make<TH1F>(Form("h_summaryY%s_%d",aliTypeName,i),
1330  title + "#LT #Delta y' #GT",
1331  aliSize, 0.5, aliSize+0.5);
1332  sumContainer.summaryNormYResiduals_ = tfd.make<TH1F>(Form("h_summaryNormY%s_%d",aliTypeName,i),
1333  title + "#LT #Delta y'/#sigma #GT",
1334  aliSize,0.5,aliSize+0.5);
1335  }
1336 
1337  } else if (subtype == align::AlignableDet && subcompSize > 1) { // fixed: was aliSize before
1338  if (subcompSize != 2) { // strange... expect only 2 DetUnits in DS layers
1339  // this 2 is hardcoded factor 2 in binning below and also assumed later on
1340  edm::LogError("Alignment") << "@SUB=bookSummaryHists"
1341  << "Det with " << subcompSize << " components";
1342  }
1343  // title contains x-title
1344  const TString title(Form("Summary for substructures in %s %d;%s;", aliTypeName, i,
1345  AlignableObjectId::idToString(ali.components()[0]->components()[0]->alignableObjectId())));
1346 
1347  sumContainer.summaryXResiduals_
1348  = tfd.make<TH1F>(Form("h_summaryX%s_%d", aliTypeName, i),
1349  title + "#LT #Delta x' #GT", (2*aliSize), 0.5, 2*aliSize+0.5);
1350  sumContainer.summaryNormXResiduals_
1351  = tfd.make<TH1F>(Form("h_summaryNormX%s_%d", aliTypeName, i),
1352  title + "#LT #Delta x'/#sigma #GT", (2*aliSize), 0.5, 2*aliSize+0.5);
1353 
1354  if (bookResidY) {
1355  sumContainer.summaryYResiduals_
1356  = tfd.make<TH1F>(Form("h_summaryY%s_%d", aliTypeName, i),
1357  title + "#LT #Delta y' #GT", (2*aliSize), 0.5, 2*aliSize+0.5);
1358  sumContainer.summaryNormYResiduals_
1359  = tfd.make<TH1F>(Form("h_summaryNormY%s_%d", aliTypeName, i),
1360  title + "#LT #Delta y'/#sigma #GT", (2*aliSize), 0.5, 2*aliSize+0.5);
1361  }
1362 
1363  } else {
1364  edm::LogError("TrackerOfflineValidation") << "@SUB=TrackerOfflineValidation::bookSummaryHists"
1365  << "No summary histogramm for hierarchy level "
1366  << aliTypeName << " in subdet " << aliDetId.subdetId();
1367  }
1368 
1369  // Now book hists that just sum up the residual histograms from lower levels.
1370  // Axis title is copied from lowest level module of structure.
1371  // Should be safe that y-hists are only touched if non-null pointers...
1372  int nbins = 0;
1373  double xmin = 0., xmax = 0.;
1374  const TString sumTitle(Form("Residual for %s %d in %s;", aliTypeName, i, typeName));
1375  const ModuleHistos &xTitHists = this->getHistStructFromMap(aliDetId); // for x-axis titles
1376  this->getBinning(aliDetId.subdetId(), XprimeResidual, nbins, xmin, xmax);
1377 
1378  sumContainer.sumXResiduals_ = tfd.make<TH1F>(Form("h_Xprime_%s_%d", aliTypeName, i),
1379  sumTitle + xTitHists.ResXprimeHisto->GetXaxis()->GetTitle(),
1380  nbins, xmin, xmax);
1381 
1382  this->getBinning(aliDetId.subdetId(), NormXprimeResidual, nbins, xmin, xmax);
1383  sumContainer.sumNormXResiduals_ = tfd.make<TH1F>(Form("h_NormXprime_%s_%d",aliTypeName,i),
1384  sumTitle + xTitHists.NormResXprimeHisto->GetXaxis()->GetTitle(),
1385  nbins, xmin, xmax);
1386  if (bookResidY) {
1387  this->getBinning(aliDetId.subdetId(), YprimeResidual, nbins, xmin, xmax);
1388  sumContainer.sumYResiduals_ = tfd.make<TH1F>(Form("h_Yprime_%s_%d",aliTypeName,i),
1389  sumTitle + xTitHists.ResYprimeHisto->GetXaxis()->GetTitle(),
1390  nbins, xmin, xmax);
1391 
1392  this->getBinning(aliDetId.subdetId(), NormYprimeResidual, nbins, xmin, xmax);
1393  sumContainer.sumNormYResiduals_ = tfd.make<TH1F>(Form("h_NormYprime_%s_%d",aliTypeName,i),
1394  sumTitle + xTitHists.NormResYprimeHisto->GetXaxis()->GetTitle(),
1395  nbins, xmin, xmax);
1396  }
1397 
1398  // If we are at the lowest level, we already sum up and fill the summary.
1399 
1400  // special case I: For DetUnits and Dets with only one subcomponent start filling summary histos
1401  if( ( subtype == align::AlignableDet && subcompSize == 1) || subtype == align::AlignableDetUnit ) {
1402  for(uint k = 0; k < aliSize; ++k) {
1403  DetId detid = ali.components()[k]->id();
1404  ModuleHistos &histStruct = this->getHistStructFromMap(detid);
1405  this->summarizeBinInContainer(k+1, detid.subdetId() ,sumContainer, histStruct );
1406  sumContainer.sumXResiduals_->Add(histStruct.ResXprimeHisto);
1407  sumContainer.sumNormXResiduals_->Add(histStruct.NormResXprimeHisto);
1408  if( this->isPixel(detid.subdetId()) || stripYResiduals_ ) {
1409  sumContainer.sumYResiduals_->Add(histStruct.ResYprimeHisto);
1410  sumContainer.sumNormYResiduals_->Add(histStruct.NormResYprimeHisto);
1411  }
1412  }
1413  } else if( subtype == align::AlignableDet && subcompSize > 1) { // fixed: was aliSize before
1414  // special case II: Fill summary histos for dets with two detunits
1415  for(uint k = 0; k < aliSize; ++k) {
1416  for(uint j = 0; j < subcompSize; ++j) { // assumes all have same size (as binning does)
1417  DetId detid = ali.components()[k]->components()[j]->id();
1418  ModuleHistos &histStruct = this->getHistStructFromMap(detid);
1419  this->summarizeBinInContainer(2*k+j+1, detid.subdetId() ,sumContainer, histStruct );
1420  sumContainer.sumXResiduals_->Add( histStruct.ResXprimeHisto);
1421  sumContainer.sumNormXResiduals_->Add( histStruct.NormResXprimeHisto);
1422  if( this->isPixel(detid.subdetId()) || stripYResiduals_ ) {
1423  sumContainer.sumYResiduals_->Add( histStruct.ResYprimeHisto);
1424  sumContainer.sumNormYResiduals_->Add( histStruct.NormResYprimeHisto);
1425  }
1426  }
1427  }
1428  }
1429  return sumContainer;
1430 }
type
Definition: HCALResponse.h:21
align::ID id() const
Return the ID of Alignable, i.e. DetId of &#39;first&#39; component GeomDet(Unit).
Definition: Alignable.h:180
int i
Definition: DBlmapReader.cc:9
bool isPixel(uint32_t subDetId)
ModuleHistos & getHistStructFromMap(const DetId &detid)
virtual Alignables components() const =0
Return vector of all direct components.
void getBinning(uint32_t subDetId, TrackerOfflineValidation::HistogrammType residualtype, int &nBinsX, double &lowerBoundX, double &upperBoundX)
virtual StructureType alignableObjectId() const =0
Return the alignable type identifier.
int j
Definition: DBlmapReader.cc:9
int subdetId() const
get the contents of the subdetector field (not cast into any detector&#39;s numbering enum) ...
Definition: DetId.h:37
Definition: DetId.h:18
void summarizeBinInContainer(int bin, SummaryContainer &targetContainer, SummaryContainer &sourceContainer)
static const char * idToString(align::StructureType type)
TH1 * TrackerOfflineValidation::bookTH1F ( bool  isTransient,
DirectoryWrapper tfd,
const char *  histName,
const char *  histTitle,
int  nBinsX,
double  lowX,
double  highX 
)
private

Definition at line 780 of file TrackerOfflineValidation.cc.

References TrackerOfflineValidation::DirectoryWrapper::make(), and vDeleteObjects_.

Referenced by bookHists().

782 {
783  if (isTransient) {
784  vDeleteObjects_.push_back(new TH1F(histName, histTitle, nBinsX, lowX, highX));
785  return vDeleteObjects_.back(); // return last element of vector
786  }
787  else
788  return tfd.make<TH1F>(histName, histTitle, nBinsX, lowX, highX);
789 }
std::vector< TH1 * > vDeleteObjects_
TProfile * TrackerOfflineValidation::bookTProfile ( bool  isTransient,
DirectoryWrapper tfd,
const char *  histName,
const char *  histTitle,
int  nBinsX,
double  lowX,
double  highX 
)
private

Definition at line 791 of file TrackerOfflineValidation.cc.

References TrackerOfflineValidation::DirectoryWrapper::make(), and vDeleteObjects_.

Referenced by bookHists().

793 {
794  if (isTransient) {
795  TProfile * profile = new TProfile(histName, histTitle, nBinsX, lowX, highX);
796  vDeleteObjects_.push_back(profile);
797  return profile;
798  }
799  else
800  return (TProfile*)tfd.make<TProfile>(histName, histTitle, nBinsX, lowX, highX);
801 }
std::vector< TH1 * > vDeleteObjects_
TProfile * TrackerOfflineValidation::bookTProfile ( bool  isTransient,
DirectoryWrapper tfd,
const char *  histName,
const char *  histTitle,
int  nBinsX,
double  lowX,
double  highX,
double  lowY,
double  highY 
)
private

Definition at line 804 of file TrackerOfflineValidation.cc.

References TrackerOfflineValidation::DirectoryWrapper::make(), and vDeleteObjects_.

806 {
807  if (isTransient) {
808  TProfile * profile = new TProfile(histName, histTitle, nBinsX, lowX, highX, lowY, highY);
809  vDeleteObjects_.push_back(profile);
810  return profile;
811  }
812  else
813  return (TProfile*)tfd.make<TProfile>(histName, histTitle, nBinsX, lowX, highX, lowY, highY);
814 }
std::vector< TH1 * > vDeleteObjects_
void TrackerOfflineValidation::checkBookHists ( const edm::EventSetup setup)
privatevirtual

Definition at line 383 of file TrackerOfflineValidation.cc.

References bareTkGeomPtr_, bookDirHists(), bookGlobalHists(), TrackerGeometry::detIds(), TrackerGeometry::detUnitIds(), dqmMode_, edm::EventSetup::get(), moduleDirectory_, edm::ESHandle< class >::product(), AlCaHLTBitMon_QueryRunRegistry::string, and tkGeom_.

Referenced by analyze().

384 {
385  es.get<TrackerDigiGeometryRecord>().get( tkGeom_ );
386  const TrackerGeometry *newBareTkGeomPtr = &(*tkGeom_);
387  if (newBareTkGeomPtr == bareTkGeomPtr_) return; // already booked hists, nothing changed
388 
389  if (!bareTkGeomPtr_) { // pointer not yet set: called the first time => book hists
390 
391  //Retrieve tracker topology from geometry
392  edm::ESHandle<TrackerTopology> tTopoHandle;
393  es.get<IdealGeometryRecord>().get(tTopoHandle);
394  const TrackerTopology* const tTopo = tTopoHandle.product();
395 
396  // construct alignable tracker to get access to alignable hierarchy
397  AlignableTracker aliTracker(&(*tkGeom_), tTopo);
398 
399  edm::LogInfo("TrackerOfflineValidation") << "There are " << newBareTkGeomPtr->detIds().size()
400  << " dets in the Geometry record.\n"
401  << "Out of these "<<newBareTkGeomPtr->detUnitIds().size()
402  <<" are detUnits";
403 
404  // Book Histogramms for global track quantities
405  std::string globDir("GlobalTrackVariables");
406  DirectoryWrapper trackglobal(globDir,moduleDirectory_,dqmMode_);
407  this->bookGlobalHists(trackglobal);
408 
409  // recursively book histogramms on lowest level
410  DirectoryWrapper tfdw("",moduleDirectory_,dqmMode_);
411  this->bookDirHists(tfdw, aliTracker, tTopo);
412  }
413  else { // histograms booked, but changed TrackerGeometry?
414  edm::LogWarning("GeometryChange") << "@SUB=checkBookHists"
415  << "TrackerGeometry changed, but will not re-book hists!";
416  }
417  bareTkGeomPtr_ = newBareTkGeomPtr;
418 }
const TrackerGeometry * bareTkGeomPtr_
edm::ESHandle< TrackerGeometry > tkGeom_
virtual const DetIdContainer & detIds() const
Returm a vector of all GeomDet DetIds (including those of GeomDetUnits)
T const * product() const
Definition: ESHandle.h:86
void bookGlobalHists(DirectoryWrapper &tfd)
virtual const DetIdContainer & detUnitIds() const
Returm a vector of all GeomDetUnit DetIds.
void bookDirHists(DirectoryWrapper &tfd, const Alignable &ali, const TrackerTopology *tTopo)
void TrackerOfflineValidation::collateSummaryHists ( DirectoryWrapper tfd,
const Alignable ali,
int  i,
std::vector< TrackerOfflineValidation::SummaryContainer > &  vLevelProfiles 
)
private

Definition at line 1251 of file TrackerOfflineValidation.cc.

References Alignable::alignableObjectId(), bookSummaryHists(), makeMuonMisalignmentScenario::components, Alignable::components(), dqmMode_, f, fitResiduals(), AlignableObjectId::idToString(), isDetOrDetUnit(), LogDebug, moduleDirectory_, gen::n, findQualityFiles::size, AlCaHLTBitMon_QueryRunRegistry::string, and summarizeBinInContainer().

Referenced by endJob().

1253 {
1254  std::vector<Alignable*> alivec(ali.components());
1255  if( this->isDetOrDetUnit((alivec)[0]->alignableObjectId()) ) return;
1256 
1257  for(int iComp=0, iCompEnd = ali.components().size();iComp < iCompEnd; ++iComp) {
1258  std::vector< TrackerOfflineValidation::SummaryContainer > vProfiles;
1259  std::string structurename = AlignableObjectId::idToString((alivec)[iComp]->alignableObjectId());
1260 
1261  LogDebug("TrackerOfflineValidation") << "StructureName = " << structurename;
1262  std::stringstream dirname;
1263  dirname << structurename;
1264 
1265  // add no suffix counter to strip and pixel -> just aesthetics
1266  if (structurename != "Strip" && structurename != "Pixel") dirname << "_" << iComp+1;
1267 
1268  if( !(this->isDetOrDetUnit( (alivec)[iComp]->alignableObjectId()) )
1269  || (alivec)[0]->components().size() > 1 ) {
1270  DirectoryWrapper f(tfd,dirname.str(),moduleDirectory_,dqmMode_);
1271  this->collateSummaryHists( f, *(alivec)[iComp], i, vProfiles);
1272  vLevelProfiles.push_back(this->bookSummaryHists(tfd, *(alivec[iComp]), ali.alignableObjectId(), iComp+1));
1273  TH1 *hY = vLevelProfiles[iComp].sumYResiduals_;
1274  TH1 *hNormY = vLevelProfiles[iComp].sumNormYResiduals_;
1275  for(uint n = 0; n < vProfiles.size(); ++n) {
1276  this->summarizeBinInContainer(n+1, vLevelProfiles[iComp], vProfiles[n] );
1277  vLevelProfiles[iComp].sumXResiduals_->Add(vProfiles[n].sumXResiduals_);
1278  vLevelProfiles[iComp].sumNormXResiduals_->Add(vProfiles[n].sumNormXResiduals_);
1279  if (hY) hY->Add(vProfiles[n].sumYResiduals_); // only if existing
1280  if (hNormY) hNormY->Add(vProfiles[n].sumNormYResiduals_); // dito (pxl, stripYResiduals_)
1281  }
1282  if(dqmMode_)continue; // No fits in dqmMode
1283  //add fit values to stat box
1284  this->fitResiduals(vLevelProfiles[iComp].sumXResiduals_);
1285  this->fitResiduals(vLevelProfiles[iComp].sumNormXResiduals_);
1286  if (hY) this->fitResiduals(hY); // only if existing (pixel or stripYResiduals_)
1287  if (hNormY) this->fitResiduals(hNormY); // dito
1288  } else {
1289  // nothing to be done for det or detunits
1290  continue;
1291  }
1292  }
1293 }
#define LogDebug(id)
int i
Definition: DBlmapReader.cc:9
void collateSummaryHists(DirectoryWrapper &tfd, const Alignable &ali, int i, std::vector< TrackerOfflineValidation::SummaryContainer > &vLevelProfiles)
virtual Alignables components() const =0
Return vector of all direct components.
TrackerOfflineValidation::SummaryContainer bookSummaryHists(DirectoryWrapper &tfd, const Alignable &ali, align::StructureType type, int i)
virtual StructureType alignableObjectId() const =0
Return the alignable type identifier.
double f[11][100]
bool isDetOrDetUnit(align::StructureType type)
std::pair< float, float > fitResiduals(TH1 *hist) const
void summarizeBinInContainer(int bin, SummaryContainer &targetContainer, SummaryContainer &sourceContainer)
static const char * idToString(align::StructureType type)
tuple size
Write out results.
void TrackerOfflineValidation::endJob ( void  )
overrideprivatevirtual

Reimplemented from edm::EDAnalyzer.

Definition at line 1204 of file TrackerOfflineValidation.cc.

References collateSummaryHists(), dqmMode_, f, fillTree(), edm::EventSetup::get(), GetIndex(), lastSetup_, TFileService::make(), moduleDirectory_, mPxbResiduals_, mPxeResiduals_, mTecResiduals_, mTibResiduals_, mTidResiduals_, mTobResiduals_, edm::ESHandle< class >::product(), tkGeom_, MainPageGenerator::tree, and vTrackHistos_.

1205 {
1206 
1207  if (!tkGeom_.product()) return;
1208 
1209  //Retrieve tracker topology from geometry
1210  edm::ESHandle<TrackerTopology> tTopoHandle;
1211  lastSetup_->get<IdealGeometryRecord>().get(tTopoHandle);
1212  const TrackerTopology* const tTopo = tTopoHandle.product();
1213 
1214  AlignableTracker aliTracker(&(*tkGeom_), tTopo);
1215 
1216  static const int kappadiffindex = this->GetIndex(vTrackHistos_,"h_diff_curvature");
1217  vTrackHistos_[kappadiffindex]->Add(vTrackHistos_[this->GetIndex(vTrackHistos_,"h_curvature_neg")],
1218  vTrackHistos_[this->GetIndex(vTrackHistos_,"h_curvature_pos")],-1,1);
1219 
1220  // Collate Information for Subdetectors
1221  // create summary histogramms recursively
1222  std::vector<TrackerOfflineValidation::SummaryContainer> vTrackerprofiles;
1223  DirectoryWrapper f("",moduleDirectory_,dqmMode_);
1224  this->collateSummaryHists(f,(aliTracker), 0, vTrackerprofiles);
1225 
1226  if (dqmMode_) return;
1227  // Should be excluded in dqmMode, since TTree is not usable
1228  // In dqmMode tree operations are are sourced out to the additional module TrackerOfflineValidationSummary
1229 
1231  TTree *tree = fs->make<TTree>("TkOffVal","TkOffVal");
1232 
1233  TkOffTreeVariables *treeMemPtr = new TkOffTreeVariables;
1234  // We create branches for all members of 'TkOffTreeVariables' (even if not needed).
1235  // This works because we have a dictionary for 'TkOffTreeVariables'
1236  // (see src/classes_def.xml and src/classes.h):
1237  tree->Branch("TkOffTreeVariables", &treeMemPtr); // address of pointer!
1238 
1239  this->fillTree(*tree, mPxbResiduals_, *treeMemPtr, *tkGeom_, tTopo);
1240  this->fillTree(*tree, mPxeResiduals_, *treeMemPtr, *tkGeom_, tTopo);
1241  this->fillTree(*tree, mTibResiduals_, *treeMemPtr, *tkGeom_, tTopo);
1242  this->fillTree(*tree, mTidResiduals_, *treeMemPtr, *tkGeom_, tTopo);
1243  this->fillTree(*tree, mTobResiduals_, *treeMemPtr, *tkGeom_, tTopo);
1244  this->fillTree(*tree, mTecResiduals_, *treeMemPtr, *tkGeom_, tTopo);
1245 
1246  delete treeMemPtr; treeMemPtr = 0;
1247 }
std::map< int, TrackerOfflineValidation::ModuleHistos > mPxeResiduals_
void collateSummaryHists(DirectoryWrapper &tfd, const Alignable &ali, int i, std::vector< TrackerOfflineValidation::SummaryContainer > &vLevelProfiles)
std::map< int, TrackerOfflineValidation::ModuleHistos > mTecResiduals_
container to hold data to be written into TTree
edm::ESHandle< TrackerGeometry > tkGeom_
int GetIndex(const std::vector< OBJECT_TYPE * > &vec, const TString &name)
T * make(const Args &...args) const
make new ROOT object
Definition: TFileService.h:64
void fillTree(TTree &tree, const std::map< int, TrackerOfflineValidation::ModuleHistos > &moduleHist_, TkOffTreeVariables &treeMem, const TrackerGeometry &tkgeom, const TrackerTopology *tTopo)
std::map< int, TrackerOfflineValidation::ModuleHistos > mTibResiduals_
std::map< int, TrackerOfflineValidation::ModuleHistos > mTidResiduals_
double f[11][100]
std::map< int, TrackerOfflineValidation::ModuleHistos > mTobResiduals_
const T & get() const
Definition: EventSetup.h:55
T const * product() const
Definition: ESHandle.h:86
std::map< int, TrackerOfflineValidation::ModuleHistos > mPxbResiduals_
const edm::EventSetup * lastSetup_
void TrackerOfflineValidation::fillTree ( TTree &  tree,
const std::map< int, TrackerOfflineValidation::ModuleHistos > &  moduleHist_,
TkOffTreeVariables treeMem,
const TrackerGeometry tkgeom,
const TrackerTopology tTopo 
)
private

Definition at line 1464 of file TrackerOfflineValidation.cc.

References TkOffTreeVariables::blade, TkOffTreeVariables::chi2PerDofX, TkOffTreeVariables::chi2PerDofY, TkOffTreeVariables::clear(), SiPixelRawToDigiRegional_cfi::deltaPhi, dPhi(), PFRecoTauDiscriminationAgainstElectronDeadECAL_cfi::dR, TkOffTreeVariables::entries, PV3DBase< T, PVType, FrameType >::eta(), TkOffTreeVariables::fitMeanNormX, TkOffTreeVariables::fitMeanNormY, TkOffTreeVariables::fitMeanX, TkOffTreeVariables::fitMeanY, fitResiduals(), TkOffTreeVariables::fitSigmaNormX, TkOffTreeVariables::fitSigmaNormY, TkOffTreeVariables::fitSigmaX, TkOffTreeVariables::fitSigmaY, Fwhm(), getMedian(), h, TkOffTreeVariables::half, TkOffTreeVariables::histNameLocalX, TkOffTreeVariables::histNameLocalY, TkOffTreeVariables::histNameNormLocalX, TkOffTreeVariables::histNameNormX, TkOffTreeVariables::histNameNormY, TkOffTreeVariables::histNameX, TkOffTreeVariables::histNameY, TrackerGeometry::idToDet(), TkOffTreeVariables::isDoubleSide, TkOffTreeVariables::isStereo, TkOffTreeVariables::layer, lCoorHistOn_, TkOffTreeVariables::meanLocalX, TkOffTreeVariables::meanNormLocalX, TkOffTreeVariables::meanNormX, TkOffTreeVariables::meanNormY, TkOffTreeVariables::meanResXvsX, TkOffTreeVariables::meanResXvsY, TkOffTreeVariables::meanResYvsX, TkOffTreeVariables::meanResYvsY, TkOffTreeVariables::meanX, TkOffTreeVariables::meanY, TkOffTreeVariables::medianX, TkOffTreeVariables::medianY, TkOffTreeVariables::module, TkOffTreeVariables::moduleId, moduleLevelProfiles_, TkOffTreeVariables::numberOfOutliers, TkOffTreeVariables::numberOfOverflows, TkOffTreeVariables::numberOfUnderflows, TkOffTreeVariables::outerInner, TkOffTreeVariables::panel, PV3DBase< T, PVType, FrameType >::perp(), TkOffTreeVariables::petal, PV3DBase< T, PVType, FrameType >::phi(), TkOffTreeVariables::phiDirection, PixelSubdetector::PixelBarrel, PixelSubdetector::PixelEndcap, TkOffTreeVariables::posEta, GeomDet::position(), TkOffTreeVariables::posPhi, TkOffTreeVariables::posR, TkOffTreeVariables::posX, TkOffTreeVariables::posY, TkOffTreeVariables::posZ, TkOffTreeVariables::profileNameResXvsX, TkOffTreeVariables::profileNameResXvsY, TkOffTreeVariables::profileNameResYvsX, TkOffTreeVariables::profileNameResYvsY, TrackerTopology::pxbLadder(), TrackerTopology::pxbLayer(), TrackerTopology::pxbModule(), TrackerTopology::pxfBlade(), TrackerTopology::pxfDisk(), TrackerTopology::pxfModule(), TrackerTopology::pxfPanel(), TrackerTopology::pxfSide(), DetId::rawId(), TkOffTreeVariables::rDirection, TkOffTreeVariables::ring, TkOffTreeVariables::rmsLocalX, TkOffTreeVariables::rmsNormLocalX, TkOffTreeVariables::rmsNormX, TkOffTreeVariables::rmsNormY, TkOffTreeVariables::rmsResXvsX, TkOffTreeVariables::rmsResXvsY, TkOffTreeVariables::rmsResYvsX, TkOffTreeVariables::rmsResYvsY, TkOffTreeVariables::rmsX, TkOffTreeVariables::rmsY, TkOffTreeVariables::rod, TkOffTreeVariables::rOrZDirection, TkOffTreeVariables::side, TkOffTreeVariables::sigmaNormX, DetId::subdetId(), TkOffTreeVariables::subDetId, GeomDet::surface(), StripSubdetector::TEC, TrackerTopology::tecIsDoubleSide(), TrackerTopology::tecModule(), TrackerTopology::tecPetalInfo(), TrackerTopology::tecRing(), TrackerTopology::tecSide(), TrackerTopology::tecStereo(), TrackerTopology::tecWheel(), StripSubdetector::TIB, TrackerTopology::tibIsDoubleSide(), TrackerTopology::tibLayer(), TrackerTopology::tibModule(), TrackerTopology::tibStereo(), TrackerTopology::tibStringInfo(), StripSubdetector::TID, TrackerTopology::tidIsDoubleSide(), TrackerTopology::tidModuleInfo(), TrackerTopology::tidRing(), TrackerTopology::tidSide(), TrackerTopology::tidStereo(), TrackerTopology::tidWheel(), StripSubdetector::TOB, TrackerTopology::tobIsDoubleSide(), TrackerTopology::tobLayer(), TrackerTopology::tobModule(), TrackerTopology::tobRodInfo(), TrackerTopology::tobStereo(), Surface::toGlobal(), useFit_, PV3DBase< T, PVType, FrameType >::x(), PV3DBase< T, PVType, FrameType >::y(), PV3DBase< T, PVType, FrameType >::z(), and TkOffTreeVariables::zDirection.

Referenced by endJob(), and core.AutoFillTreeProducer.AutoFillTreeProducer::process().

1467 {
1468 
1469  for(std::map<int, TrackerOfflineValidation::ModuleHistos>::const_iterator it = moduleHist_.begin(),
1470  itEnd= moduleHist_.end(); it != itEnd;++it ) {
1471  treeMem.clear(); // make empty/default
1472 
1473  //variables concerning the tracker components/hierarchy levels
1474  DetId detId_ = it->first;
1475  treeMem.moduleId = detId_;
1476  treeMem.subDetId = detId_.subdetId();
1477  treeMem.isDoubleSide =0;
1478 
1479  if(treeMem.subDetId == PixelSubdetector::PixelBarrel){
1480  unsigned int whichHalfBarrel(1), rawId(detId_.rawId()); //DetId does not know about halfBarrels is PXB ...
1481  if( (rawId>=302056964 && rawId<302059300) || (rawId>=302123268 && rawId<302127140) ||
1482  (rawId>=302189572 && rawId<302194980) ) whichHalfBarrel=2;
1483  treeMem.layer = tTopo->pxbLayer(detId_);
1484  treeMem.half = whichHalfBarrel;
1485  treeMem.rod = tTopo->pxbLadder(detId_); // ... so, ladder is not per halfBarrel-Layer, but per barrel-layer!
1486  treeMem.module = tTopo->pxbModule(detId_);
1487  } else if(treeMem.subDetId == PixelSubdetector::PixelEndcap){
1488  unsigned int whichHalfCylinder(1), rawId(detId_.rawId()); //DetId does not kmow about halfCylinders in PXF
1489  if( (rawId>=352394500 && rawId<352406032) || (rawId>=352460036 && rawId<352471568) ||
1490  (rawId>=344005892 && rawId<344017424) || (rawId>=344071428 && rawId<344082960) ) whichHalfCylinder=2;
1491  treeMem.layer = tTopo->pxfDisk(detId_);
1492  treeMem.side = tTopo->pxfSide(detId_);
1493  treeMem.half = whichHalfCylinder;
1494  treeMem.blade = tTopo->pxfBlade(detId_);
1495  treeMem.panel = tTopo->pxfPanel(detId_);
1496  treeMem.module = tTopo->pxfModule(detId_);
1497  } else if(treeMem.subDetId == StripSubdetector::TIB){
1498  unsigned int whichHalfShell(1), rawId(detId_.rawId()); //DetId does not kmow about halfShells in TIB
1499  if ( (rawId>=369120484 && rawId<369120688) || (rawId>=369121540 && rawId<369121776) ||
1500  (rawId>=369136932 && rawId<369137200) || (rawId>=369137988 && rawId<369138288) ||
1501  (rawId>=369153396 && rawId<369153744) || (rawId>=369154436 && rawId<369154800) ||
1502  (rawId>=369169844 && rawId<369170256) || (rawId>=369170900 && rawId<369171344) ||
1503  (rawId>=369124580 && rawId<369124784) || (rawId>=369125636 && rawId<369125872) ||
1504  (rawId>=369141028 && rawId<369141296) || (rawId>=369142084 && rawId<369142384) ||
1505  (rawId>=369157492 && rawId<369157840) || (rawId>=369158532 && rawId<369158896) ||
1506  (rawId>=369173940 && rawId<369174352) || (rawId>=369174996 && rawId<369175440) ) whichHalfShell=2;
1507  treeMem.layer = tTopo->tibLayer(detId_);
1508  treeMem.side = tTopo->tibStringInfo(detId_)[0];
1509  treeMem.half = whichHalfShell;
1510  treeMem.rod = tTopo->tibStringInfo(detId_)[2];
1511  treeMem.outerInner = tTopo->tibStringInfo(detId_)[1];
1512  treeMem.module = tTopo->tibModule(detId_);
1513  treeMem.isStereo = tTopo->tibStereo(detId_);
1514  treeMem.isDoubleSide = tTopo->tibIsDoubleSide(detId_);
1515  } else if(treeMem.subDetId == StripSubdetector::TID){
1516  treeMem.layer = tTopo->tidWheel(detId_);
1517  treeMem.side = tTopo->tidSide(detId_);
1518  treeMem.ring = tTopo->tidRing(detId_);
1519  treeMem.outerInner = tTopo->tidModuleInfo(detId_)[0];
1520  treeMem.module = tTopo->tidModuleInfo(detId_)[1];
1521  treeMem.isStereo = tTopo->tidStereo(detId_);
1522  treeMem.isDoubleSide = tTopo->tidIsDoubleSide(detId_);
1523  } else if(treeMem.subDetId == StripSubdetector::TOB){
1524  treeMem.layer = tTopo->tobLayer(detId_);
1525  treeMem.side = tTopo->tobRodInfo(detId_)[0];
1526  treeMem.rod = tTopo->tobRodInfo(detId_)[1];
1527  treeMem.module = tTopo->tobModule(detId_);
1528  treeMem.isStereo = tTopo->tobStereo(detId_);
1529  treeMem.isDoubleSide = tTopo->tobIsDoubleSide(detId_);
1530  } else if(treeMem.subDetId == StripSubdetector::TEC) {
1531  treeMem.layer = tTopo->tecWheel(detId_);
1532  treeMem.side = tTopo->tecSide(detId_);
1533  treeMem.ring = tTopo->tecRing(detId_);
1534  treeMem.petal = tTopo->tecPetalInfo(detId_)[1];
1535  treeMem.outerInner = tTopo->tecPetalInfo(detId_)[0];
1536  treeMem.module = tTopo->tecModule(detId_);
1537  treeMem.isStereo = tTopo->tecStereo(detId_);
1538  treeMem.isDoubleSide = tTopo->tecIsDoubleSide(detId_);
1539  }
1540 
1541  //variables concerning the tracker geometry
1542  const Surface::PositionType &gPModule = tkgeom.idToDet(detId_)->position();
1543  treeMem.posPhi = gPModule.phi();
1544  treeMem.posEta = gPModule.eta();
1545  treeMem.posR = gPModule.perp();
1546  treeMem.posX = gPModule.x();
1547  treeMem.posY = gPModule.y();
1548  treeMem.posZ = gPModule.z();
1549 
1550  const Surface& surface = tkgeom.idToDet(detId_)->surface();
1551 
1552  //global Orientation of local coordinate system of dets/detUnits
1553  LocalPoint lUDirection(1.,0.,0.), lVDirection(0.,1.,0.), lWDirection(0.,0.,1.);
1554  GlobalPoint gUDirection = surface.toGlobal(lUDirection),
1555  gVDirection = surface.toGlobal(lVDirection),
1556  gWDirection = surface.toGlobal(lWDirection);
1557  double dR(999.), dPhi(999.), dZ(999.);
1559  dR = gWDirection.perp() - gPModule.perp();
1560  dPhi = deltaPhi(gUDirection.phi(),gPModule.phi());
1561  dZ = gVDirection.z() - gPModule.z();
1562  if(dZ>=0.)treeMem.rOrZDirection = 1; else treeMem.rOrZDirection = -1;
1563  }else if(treeMem.subDetId==PixelSubdetector::PixelEndcap){
1564  dR = gUDirection.perp() - gPModule.perp();
1565  dPhi = deltaPhi(gVDirection.phi(),gPModule.phi());
1566  dZ = gWDirection.z() - gPModule.z();
1567  if(dR>=0.)treeMem.rOrZDirection = 1; else treeMem.rOrZDirection = -1;
1568  }else if(treeMem.subDetId==StripSubdetector::TID || treeMem.subDetId==StripSubdetector::TEC){
1569  dR = gVDirection.perp() - gPModule.perp();
1570  dPhi = deltaPhi(gUDirection.phi(),gPModule.phi());
1571  dZ = gWDirection.z() - gPModule.z();
1572  if(dR>=0.)treeMem.rOrZDirection = 1; else treeMem.rOrZDirection = -1;
1573  }
1574  if(dR>=0.)treeMem.rDirection = 1; else treeMem.rDirection = -1;
1575  if(dPhi>=0.)treeMem.phiDirection = 1; else treeMem.phiDirection = -1;
1576  if(dZ>=0.)treeMem.zDirection = 1; else treeMem.zDirection = -1;
1577 
1578  //mean and RMS values (extracted from histograms(Xprime on module level)
1579  treeMem.entries = static_cast<UInt_t>(it->second.ResXprimeHisto->GetEntries());
1580  treeMem.meanX = it->second.ResXprimeHisto->GetMean();
1581  treeMem.rmsX = it->second.ResXprimeHisto->GetRMS();
1582  //treeMem.sigmaX = Fwhm(it->second.ResXprimeHisto)/2.355;
1583 
1584  if (useFit_) {
1585  //call fit function which returns mean and sigma from the fit
1586  //for absolute residuals
1587  std::pair<float,float> fitResult1 = this->fitResiduals(it->second.ResXprimeHisto);
1588  treeMem.fitMeanX = fitResult1.first;
1589  treeMem.fitSigmaX = fitResult1.second;
1590  //for normalized residuals
1591  std::pair<float,float> fitResult2 = this->fitResiduals(it->second.NormResXprimeHisto);
1592  treeMem.fitMeanNormX = fitResult2.first;
1593  treeMem.fitSigmaNormX = fitResult2.second;
1594  }
1595 
1596  //get median for absolute residuals
1597  treeMem.medianX = this->getMedian(it->second.ResXprimeHisto);
1598 
1599  int numberOfBins=it->second.ResXprimeHisto->GetNbinsX();
1600  treeMem.numberOfUnderflows = it->second.ResXprimeHisto->GetBinContent(0);
1601  treeMem.numberOfOverflows = it->second.ResXprimeHisto->GetBinContent(numberOfBins+1);
1602  treeMem.numberOfOutliers = it->second.ResXprimeHisto->GetBinContent(0)+it->second.ResXprimeHisto->GetBinContent(numberOfBins+1);
1603 
1604  //mean and RMS values (extracted from histograms(normalized Xprime on module level)
1605  treeMem.meanNormX = it->second.NormResXprimeHisto->GetMean();
1606  treeMem.rmsNormX = it->second.NormResXprimeHisto->GetRMS();
1607 
1608  double stats[20];
1609  it->second.NormResXprimeHisto->GetStats(stats);
1610  // GF treeMem.chi2PerDofX = stats[3]/(stats[0]-1);
1611  if (stats[0]) treeMem.chi2PerDofX = stats[3]/stats[0];
1612 
1613  treeMem.sigmaNormX = Fwhm(it->second.NormResXprimeHisto)/2.355;
1614  treeMem.histNameX = it->second.ResXprimeHisto->GetName();
1615  treeMem.histNameNormX = it->second.NormResXprimeHisto->GetName();
1616 
1617  // fill tree variables in local coordinates if set in cfg
1618  if(lCoorHistOn_) {
1619  treeMem.meanLocalX = it->second.ResHisto->GetMean();
1620  treeMem.rmsLocalX = it->second.ResHisto->GetRMS();
1621  treeMem.meanNormLocalX = it->second.NormResHisto->GetMean();
1622  treeMem.rmsNormLocalX = it->second.NormResHisto->GetRMS();
1623 
1624  treeMem.histNameLocalX = it->second.ResHisto->GetName();
1625  treeMem.histNameNormLocalX = it->second.NormResHisto->GetName();
1626  if (it->second.ResYHisto) treeMem.histNameLocalY = it->second.ResYHisto->GetName();
1627  }
1628 
1629  // mean and RMS values in local y (extracted from histograms(normalized Yprime on module level)
1630  // might exist in pixel only
1631  if (it->second.ResYprimeHisto) {//(stripYResiduals_)
1632  TH1 *h = it->second.ResYprimeHisto;
1633  treeMem.meanY = h->GetMean();
1634  treeMem.rmsY = h->GetRMS();
1635 
1636  if (useFit_) { // fit function which returns mean and sigma from the fit
1637  std::pair<float,float> fitMeanSigma = this->fitResiduals(h);
1638  treeMem.fitMeanY = fitMeanSigma.first;
1639  treeMem.fitSigmaY = fitMeanSigma.second;
1640  }
1641 
1642  //get median for absolute residuals
1643  treeMem.medianY = this->getMedian(h);
1644 
1645  treeMem.histNameY = h->GetName();
1646  }
1647  if (it->second.NormResYprimeHisto) {
1648  TH1 *h = it->second.NormResYprimeHisto;
1649  treeMem.meanNormY = h->GetMean();
1650  treeMem.rmsNormY = h->GetRMS();
1651  h->GetStats(stats); // stats buffer defined above
1652  if (stats[0]) treeMem.chi2PerDofY = stats[3]/stats[0];
1653 
1654  if (useFit_) { // fit function which returns mean and sigma from the fit
1655  std::pair<float,float> fitMeanSigma = this->fitResiduals(h);
1656  treeMem.fitMeanNormY = fitMeanSigma.first;
1657  treeMem.fitSigmaNormY = fitMeanSigma.second;
1658  }
1659  treeMem.histNameNormY = h->GetName();
1660  }
1661 
1662  if (moduleLevelProfiles_) {
1663  if (it->second.ResXvsXProfile) {
1664  TH1 *h = it->second.ResXvsXProfile;
1665  treeMem.meanResXvsX = h->GetMean();
1666  treeMem.rmsResXvsX = h->GetRMS();
1667  treeMem.profileNameResXvsX = h->GetName();
1668  }
1669  if (it->second.ResXvsYProfile) {
1670  TH1 *h = it->second.ResXvsYProfile;
1671  treeMem.meanResXvsY = h->GetMean();
1672  treeMem.rmsResXvsY = h->GetRMS();
1673  treeMem.profileNameResXvsY = h->GetName();
1674  }
1675  if (it->second.ResYvsXProfile) {
1676  TH1 *h = it->second.ResYvsXProfile;
1677  treeMem.meanResYvsX = h->GetMean();
1678  treeMem.rmsResYvsX = h->GetRMS();
1679  treeMem.profileNameResYvsX = h->GetName();
1680  }
1681  if (it->second.ResYvsYProfile) {
1682  TH1 *h = it->second.ResYvsYProfile;
1683  treeMem.meanResYvsY = h->GetMean();
1684  treeMem.rmsResYvsY = h->GetRMS();
1685  treeMem.profileNameResYvsY = h->GetName();
1686  }
1687  }
1688 
1689  tree.Fill();
1690  }
1691 }
GlobalPoint toGlobal(const Point2DBase< Scalar, LocalTag > lp) const
Definition: Surface.h:114
bool tecIsDoubleSide(const DetId &id) const
bool tobIsDoubleSide(const DetId &id) const
bool tibIsDoubleSide(const DetId &id) const
T perp() const
Definition: PV3DBase.h:72
unsigned int tibLayer(const DetId &id) const
unsigned int tidRing(const DetId &id) const
std::vector< unsigned int > tidModuleInfo(const DetId &id) const
unsigned int pxfDisk(const DetId &id) const
std::string profileNameResXvsX
unsigned int tecRing(const DetId &id) const
ring id
uint32_t tobStereo(const DetId &id) const
Geom::Phi< T > phi() const
Definition: PV3DBase.h:69
unsigned int pxbLadder(const DetId &id) const
T y() const
Definition: PV3DBase.h:63
unsigned int tidWheel(const DetId &id) const
unsigned int pxbModule(const DetId &id) const
float getMedian(const TH1 *hist) const
std::vector< unsigned int > tibStringInfo(const DetId &id) const
const Plane & surface() const
The nominal surface of the GeomDet.
Definition: GeomDet.h:40
std::string profileNameResYvsX
uint32_t rawId() const
get the raw id
Definition: DetId.h:43
std::vector< unsigned int > tecPetalInfo(const DetId &id) const
const Surface::PositionType & position() const
The position (origin of the R.F.)
Definition: GeomDet.h:46
unsigned int tidSide(const DetId &id) const
double dPhi(double phi1, double phi2)
Definition: JetUtil.h:30
uint32_t tidStereo(const DetId &id) const
std::vector< unsigned int > tobRodInfo(const DetId &id) const
T z() const
Definition: PV3DBase.h:64
The Signals That Services Can Subscribe To This is based on ActivityRegistry h
Helper function to determine trigger accepts.
Definition: Activities.doc:4
int subdetId() const
get the contents of the subdetector field (not cast into any detector&#39;s numbering enum) ...
Definition: DetId.h:37
std::string histNameLocalY
std::string histNameNormLocalX
unsigned int tibModule(const DetId &id) const
unsigned int pxfModule(const DetId &id) const
unsigned int pxbLayer(const DetId &id) const
unsigned int tecModule(const DetId &id) const
Definition: DetId.h:18
std::pair< float, float > fitResiduals(TH1 *hist) const
std::string histNameLocalX
bool tidIsDoubleSide(const DetId &id) const
unsigned int tobModule(const DetId &id) const
std::string profileNameResXvsY
T eta() const
Definition: PV3DBase.h:76
void clear()
set to empty values
uint32_t tecStereo(const DetId &id) const
unsigned int pxfSide(const DetId &id) const
uint32_t tibStereo(const DetId &id) const
T x() const
Definition: PV3DBase.h:62
float Fwhm(const TH1 *hist) const
unsigned int tecWheel(const DetId &id) const
unsigned int pxfPanel(const DetId &id) const
unsigned int pxfBlade(const DetId &id) const
std::string profileNameResYvsY
unsigned int tobLayer(const DetId &id) const
unsigned int tecSide(const DetId &id) const
virtual const TrackerGeomDet * idToDet(DetId) const
std::pair< float, float > TrackerOfflineValidation::fitResiduals ( TH1 *  hist) const
private

Definition at line 1695 of file TrackerOfflineValidation.cc.

References alignCSCRings::e, timingPdfMaker::mean, and cms::Exception::what().

Referenced by collateSummaryHists(), and fillTree().

1696 {
1697  std::pair<float,float> fitResult(9999., 9999.);
1698  if (!hist || hist->GetEntries() < 20) return fitResult;
1699 
1700  float mean = hist->GetMean();
1701  float sigma = hist->GetRMS();
1702 
1703  try { // for < CMSSW_2_2_0 since ROOT warnings from fit are converted to exceptions
1704  // Remove the try/catch for more recent CMSSW!
1705  // first fit: two RMS around mean
1706  TF1 func("tmp", "gaus", mean - 2.*sigma, mean + 2.*sigma);
1707  if (0 == hist->Fit(&func,"QNR")) { // N: do not blow up file by storing fit!
1708  mean = func.GetParameter(1);
1709  sigma = func.GetParameter(2);
1710  // second fit: three sigma of first fit around mean of first fit
1711  func.SetRange(mean - 3.*sigma, mean + 3.*sigma);
1712  // I: integral gives more correct results if binning is too wide
1713  // L: Likelihood can treat empty bins correctly (if hist not weighted...)
1714  if (0 == hist->Fit(&func, "Q0LR")) {
1715  if (hist->GetFunction(func.GetName())) { // Take care that it is later on drawn:
1716  hist->GetFunction(func.GetName())->ResetBit(TF1::kNotDraw);
1717  }
1718  fitResult.first = func.GetParameter(1);
1719  fitResult.second = func.GetParameter(2);
1720  }
1721  }
1722  } catch (cms::Exception const & e) {
1723  edm::LogWarning("Alignment") << "@SUB=TrackerOfflineValidation::fitResiduals"
1724  << "Caught this exception during ROOT fit: "
1725  << e.what();
1726  }
1727  return fitResult;
1728 }
virtual char const * what() const
Definition: Exception.cc:141
float TrackerOfflineValidation::Fwhm ( const TH1 *  hist) const
private

Definition at line 1434 of file TrackerOfflineValidation.cc.

References i, and bookConverter::max.

Referenced by fillTree(), and setSummaryBin().

1435 {
1436  float max = hist->GetMaximum();
1437  int left = -1, right = -1;
1438  for(unsigned int i = 1, iEnd = hist->GetNbinsX(); i <= iEnd; ++i) {
1439  if(hist->GetBinContent(i) < max/2. && hist->GetBinContent(i+1) > max/2. && left == -1) {
1440  if(max/2. - hist->GetBinContent(i) < hist->GetBinContent(i+1) - max/2.) {
1441  left = i;
1442  ++i;
1443  } else {
1444  left = i+1;
1445  ++i;
1446  }
1447  }
1448  if(left != -1 && right == -1) {
1449  if(hist->GetBinContent(i) > max/2. && hist->GetBinContent(i+1) < max/2.) {
1450  if( hist->GetBinContent(i) - max/2. < max/2. - hist->GetBinContent(i+1)) {
1451  right = i;
1452  } else {
1453  right = i+1;
1454  }
1455 
1456  }
1457  }
1458  }
1459  return hist->GetXaxis()->GetBinCenter(right) - hist->GetXaxis()->GetBinCenter(left);
1460 }
int i
Definition: DBlmapReader.cc:9
void TrackerOfflineValidation::getBinning ( uint32_t  subDetId,
TrackerOfflineValidation::HistogrammType  residualtype,
int &  nBinsX,
double &  lowerBoundX,
double &  upperBoundX 
)
private

Definition at line 847 of file TrackerOfflineValidation.cc.

References edm::ParameterSet::getParameter(), isPixel(), NormXprimeResidual, NormXResidual, NormYprimeResidual, parSet_, XprimeResidual, XResidual, XResidualProfile, YprimeResidual, YResidual, and YResidualProfile.

Referenced by bookHists(), and bookSummaryHists().

850 {
851  // determine if
852  const bool isPixel = this->isPixel(subDetId);
853 
854  edm::ParameterSet binningPSet;
855 
856  switch(residualType)
857  {
858  case XResidual :
859  if(isPixel) binningPSet = parSet_.getParameter<edm::ParameterSet>("TH1XResPixelModules");
860  else binningPSet = parSet_.getParameter<edm::ParameterSet>("TH1XResStripModules");
861  break;
862  case NormXResidual :
863  if(isPixel) binningPSet = parSet_.getParameter<edm::ParameterSet>("TH1NormXResPixelModules");
864  else binningPSet = parSet_.getParameter<edm::ParameterSet>("TH1NormXResStripModules");
865  break;
866  case XprimeResidual :
867  if(isPixel) binningPSet = parSet_.getParameter<edm::ParameterSet>("TH1XprimeResPixelModules");
868  else binningPSet = parSet_.getParameter<edm::ParameterSet>("TH1XprimeResStripModules");
869  break;
870  case NormXprimeResidual :
871  if(isPixel) binningPSet = parSet_.getParameter<edm::ParameterSet>("TH1NormXprimeResPixelModules");
872  else binningPSet = parSet_.getParameter<edm::ParameterSet>("TH1NormXprimeResStripModules");
873  break;
874  case YResidual : // borrow y-residual binning from yprime
875  case YprimeResidual :
876  if(isPixel) binningPSet = parSet_.getParameter<edm::ParameterSet>("TH1YResPixelModules");
877  else binningPSet = parSet_.getParameter<edm::ParameterSet>("TH1YResStripModules");
878  break;
879  /* case NormYResidual :*/
880  case NormYprimeResidual :
881  if(isPixel) binningPSet = parSet_.getParameter<edm::ParameterSet>("TH1NormYResPixelModules");
882  else binningPSet = parSet_.getParameter<edm::ParameterSet>("TH1NormYResStripModules");
883  break;
884  case XResidualProfile :
885  if(isPixel) binningPSet = parSet_.getParameter<edm::ParameterSet>("TProfileXResPixelModules");
886  else binningPSet = parSet_.getParameter<edm::ParameterSet>("TProfileXResStripModules");
887  break;
888  case YResidualProfile :
889  if(isPixel) binningPSet = parSet_.getParameter<edm::ParameterSet>("TProfileYResPixelModules");
890  else binningPSet = parSet_.getParameter<edm::ParameterSet>("TProfileYResStripModules");
891  break;
892  }
893  nBinsX = binningPSet.getParameter<int32_t>("Nbinx");
894  lowerBoundX = binningPSet.getParameter<double>("xmin");
895  upperBoundX = binningPSet.getParameter<double>("xmax");
896 }
T getParameter(std::string const &) const
bool isPixel(uint32_t subDetId)
unsigned int subDetId[18]
const edm::ParameterSet parSet_
TrackerOfflineValidation::ModuleHistos & TrackerOfflineValidation::getHistStructFromMap ( const DetId detid)
private

Definition at line 939 of file TrackerOfflineValidation.cc.

References DetId::det(), edm::hlt::Exception, mPxbResiduals_, mPxeResiduals_, mTecResiduals_, mTibResiduals_, mTidResiduals_, mTobResiduals_, PixelSubdetector::PixelBarrel, PixelSubdetector::PixelEndcap, DetId::rawId(), DetId::subdetId(), StripSubdetector::TEC, StripSubdetector::TIB, StripSubdetector::TID, and StripSubdetector::TOB.

Referenced by analyze(), bookHists(), and bookSummaryHists().

940 {
941  // get a struct with histograms from the respective map
942  // if no object exist, the reference is automatically created by the map
943  // throw exception if non-tracker id is passed
944  uint subdetid = detid.subdetId();
945  if(subdetid == PixelSubdetector::PixelBarrel ) {
946  return mPxbResiduals_[detid.rawId()];
947  } else if (subdetid == PixelSubdetector::PixelEndcap) {
948  return mPxeResiduals_[detid.rawId()];
949  } else if(subdetid == StripSubdetector::TIB) {
950  return mTibResiduals_[detid.rawId()];
951  } else if(subdetid == StripSubdetector::TID) {
952  return mTidResiduals_[detid.rawId()];
953  } else if(subdetid == StripSubdetector::TOB) {
954  return mTobResiduals_[detid.rawId()];
955  } else if(subdetid == StripSubdetector::TEC) {
956  return mTecResiduals_[detid.rawId()];
957  } else {
958  throw cms::Exception("Geometry Error")
959  << "[TrackerOfflineValidation] Error, tried to get reference for non-tracker subdet " << subdetid
960  << " from detector " << detid.det();
961  return mPxbResiduals_[0];
962  }
963 }
std::map< int, TrackerOfflineValidation::ModuleHistos > mPxeResiduals_
std::map< int, TrackerOfflineValidation::ModuleHistos > mTecResiduals_
std::map< int, TrackerOfflineValidation::ModuleHistos > mTibResiduals_
std::map< int, TrackerOfflineValidation::ModuleHistos > mTidResiduals_
uint32_t rawId() const
get the raw id
Definition: DetId.h:43
int subdetId() const
get the contents of the subdetector field (not cast into any detector&#39;s numbering enum) ...
Definition: DetId.h:37
std::map< int, TrackerOfflineValidation::ModuleHistos > mTobResiduals_
std::map< int, TrackerOfflineValidation::ModuleHistos > mPxbResiduals_
Detector det() const
get the detector field from this detid
Definition: DetId.h:35
template<class OBJECT_TYPE >
int TrackerOfflineValidation::GetIndex ( const std::vector< OBJECT_TYPE * > &  vec,
const TString &  name 
)
private

Definition at line 292 of file TrackerOfflineValidation.cc.

References getDQMSummary::iter, mergeVDriftHistosByStation::name, and query::result.

Referenced by analyze(), and endJob().

293 {
294  int result = 0;
295  for (typename std::vector<OBJECT_TYPE*>::const_iterator iter = vec.begin(), iterEnd = vec.end();
296  iter != iterEnd; ++iter, ++result) {
297  if (*iter && (*iter)->GetName() == name) return result;
298  }
299  edm::LogError("Alignment") << "@SUB=TrackerOfflineValidation::GetIndex" << " could not find " << name;
300  return -1;
301 }
tuple result
Definition: query.py:137
float TrackerOfflineValidation::getMedian ( const TH1 *  hist) const
private

Definition at line 1732 of file TrackerOfflineValidation.cc.

References j, pileupCalc::nbins, x, and detailsBasic3DVector::y.

Referenced by fillTree().

1733 {
1734  float median = 999;
1735  int nbins = histo->GetNbinsX();
1736 
1737  //extract median from histogram
1738  double *x = new double[nbins];
1739  double *y = new double[nbins];
1740  for (int j = 0; j < nbins; j++) {
1741  x[j] = histo->GetBinCenter(j+1);
1742  y[j] = histo->GetBinContent(j+1);
1743  }
1744  median = TMath::Median(nbins, x, y);
1745 
1746  delete[] x; x = 0;
1747  delete [] y; y = 0;
1748 
1749  return median;
1750 
1751 }
int j
Definition: DBlmapReader.cc:9
Definition: DDAxes.h:10
bool TrackerOfflineValidation::isBarrel ( uint32_t  subDetId)
private
bool TrackerOfflineValidation::isDetOrDetUnit ( align::StructureType  type)
private
bool TrackerOfflineValidation::isEndCap ( uint32_t  subDetId)
private
bool TrackerOfflineValidation::isPixel ( uint32_t  subDetId)
private
void TrackerOfflineValidation::setSummaryBin ( int  bin,
TH1 *  targetHist,
TH1 *  sourceHist 
)
private

Definition at line 900 of file TrackerOfflineValidation.cc.

References Fwhm(), and useFwhm_.

Referenced by summarizeBinInContainer().

901 {
902  if(targetHist && sourceHist) {
903  targetHist->SetBinContent(bin, sourceHist->GetMean(1));
904  if(useFwhm_) targetHist->SetBinError(bin, Fwhm(sourceHist)/2.);
905  else targetHist->SetBinError(bin, sourceHist->GetRMS(1) );
906  }
907  else return;
908 }
float Fwhm(const TH1 *hist) const
void TrackerOfflineValidation::summarizeBinInContainer ( int  bin,
SummaryContainer targetContainer,
SummaryContainer sourceContainer 
)
private

Definition at line 912 of file TrackerOfflineValidation.cc.

References setSummaryBin(), TrackerOfflineValidation::SummaryContainer::summaryNormXResiduals_, TrackerOfflineValidation::SummaryContainer::summaryNormYResiduals_, TrackerOfflineValidation::SummaryContainer::summaryXResiduals_, TrackerOfflineValidation::SummaryContainer::summaryYResiduals_, TrackerOfflineValidation::SummaryContainer::sumNormXResiduals_, TrackerOfflineValidation::SummaryContainer::sumNormYResiduals_, TrackerOfflineValidation::SummaryContainer::sumXResiduals_, and TrackerOfflineValidation::SummaryContainer::sumYResiduals_.

Referenced by bookSummaryHists(), and collateSummaryHists().

914 {
915  this->setSummaryBin(bin, targetContainer.summaryXResiduals_, sourceContainer.sumXResiduals_);
916  this->setSummaryBin(bin, targetContainer.summaryNormXResiduals_, sourceContainer.sumNormXResiduals_);
917  // If no y-residual hists, just returns:
918  this->setSummaryBin(bin, targetContainer.summaryYResiduals_, sourceContainer.sumYResiduals_);
919  this->setSummaryBin(bin, targetContainer.summaryNormYResiduals_, sourceContainer.sumNormYResiduals_);
920 }
void setSummaryBin(int bin, TH1 *targetHist, TH1 *sourceHist)
void TrackerOfflineValidation::summarizeBinInContainer ( int  bin,
uint32_t  subDetId,
SummaryContainer targetContainer,
ModuleHistos sourceContainer 
)
private

Definition at line 924 of file TrackerOfflineValidation.cc.

References isPixel(), TrackerOfflineValidation::ModuleHistos::NormResXprimeHisto, TrackerOfflineValidation::ModuleHistos::NormResYprimeHisto, TrackerOfflineValidation::ModuleHistos::ResXprimeHisto, TrackerOfflineValidation::ModuleHistos::ResYprimeHisto, setSummaryBin(), stripYResiduals_, TrackerOfflineValidation::SummaryContainer::summaryNormXResiduals_, TrackerOfflineValidation::SummaryContainer::summaryNormYResiduals_, TrackerOfflineValidation::SummaryContainer::summaryXResiduals_, and TrackerOfflineValidation::SummaryContainer::summaryYResiduals_.

927 {
928  // takes two summary Containers and sets summaryBins for all histograms
929  this->setSummaryBin(bin, targetContainer.summaryXResiduals_, sourceContainer.ResXprimeHisto);
930  this->setSummaryBin(bin, targetContainer.summaryNormXResiduals_, sourceContainer.NormResXprimeHisto);
931  if( this->isPixel(subDetId) || stripYResiduals_ ) {
932  this->setSummaryBin(bin, targetContainer.summaryYResiduals_, sourceContainer.ResYprimeHisto);
933  this->setSummaryBin(bin, targetContainer.summaryNormYResiduals_, sourceContainer.NormResYprimeHisto);
934  }
935 }
bool isPixel(uint32_t subDetId)
void setSummaryBin(int bin, TH1 *targetHist, TH1 *sourceHist)
unsigned int subDetId[18]

Member Data Documentation

const TrackerGeometry* TrackerOfflineValidation::bareTkGeomPtr_
private

Definition at line 252 of file TrackerOfflineValidation.cc.

Referenced by checkBookHists().

const bool TrackerOfflineValidation::dqmMode_
private
const edm::EventSetup* TrackerOfflineValidation::lastSetup_
private

Definition at line 279 of file TrackerOfflineValidation.cc.

Referenced by endJob().

const bool TrackerOfflineValidation::lCoorHistOn_
private

Definition at line 255 of file TrackerOfflineValidation.cc.

Referenced by analyze(), bookHists(), and fillTree().

const std::string TrackerOfflineValidation::moduleDirectory_
private
const bool TrackerOfflineValidation::moduleLevelHistsTransient_
private

Definition at line 256 of file TrackerOfflineValidation.cc.

Referenced by bookHists().

const bool TrackerOfflineValidation::moduleLevelProfiles_
private

Definition at line 257 of file TrackerOfflineValidation.cc.

Referenced by analyze(), bookHists(), and fillTree().

std::map<int,TrackerOfflineValidation::ModuleHistos> TrackerOfflineValidation::mPxbResiduals_
private

Definition at line 272 of file TrackerOfflineValidation.cc.

Referenced by endJob(), and getHistStructFromMap().

std::map<int,TrackerOfflineValidation::ModuleHistos> TrackerOfflineValidation::mPxeResiduals_
private

Definition at line 273 of file TrackerOfflineValidation.cc.

Referenced by endJob(), and getHistStructFromMap().

std::map<int,TrackerOfflineValidation::ModuleHistos> TrackerOfflineValidation::mTecResiduals_
private

Definition at line 277 of file TrackerOfflineValidation.cc.

Referenced by endJob(), and getHistStructFromMap().

std::map<int,TrackerOfflineValidation::ModuleHistos> TrackerOfflineValidation::mTibResiduals_
private

Definition at line 274 of file TrackerOfflineValidation.cc.

Referenced by endJob(), and getHistStructFromMap().

std::map<int,TrackerOfflineValidation::ModuleHistos> TrackerOfflineValidation::mTidResiduals_
private

Definition at line 275 of file TrackerOfflineValidation.cc.

Referenced by endJob(), and getHistStructFromMap().

std::map<int,TrackerOfflineValidation::ModuleHistos> TrackerOfflineValidation::mTobResiduals_
private

Definition at line 276 of file TrackerOfflineValidation.cc.

Referenced by endJob(), and getHistStructFromMap().

const edm::ParameterSet TrackerOfflineValidation::parSet_
private

Definition at line 250 of file TrackerOfflineValidation.cc.

Referenced by analyze(), and getBinning().

const bool TrackerOfflineValidation::stripYResiduals_
private
edm::ESHandle<TrackerGeometry> TrackerOfflineValidation::tkGeom_
private

Definition at line 251 of file TrackerOfflineValidation.cc.

Referenced by checkBookHists(), and endJob().

const bool TrackerOfflineValidation::useFit_
private

Definition at line 260 of file TrackerOfflineValidation.cc.

Referenced by fillTree().

const bool TrackerOfflineValidation::useFwhm_
private

Definition at line 259 of file TrackerOfflineValidation.cc.

Referenced by setSummaryBin().

const bool TrackerOfflineValidation::useOverflowForRMS_
private

Definition at line 261 of file TrackerOfflineValidation.cc.

Referenced by analyze().

std::vector<TH1*> TrackerOfflineValidation::vDeleteObjects_
private

Definition at line 266 of file TrackerOfflineValidation.cc.

Referenced by bookTH1F(), bookTProfile(), and ~TrackerOfflineValidation().

std::vector<TH1*> TrackerOfflineValidation::vTrack2DHistos_
private

Definition at line 270 of file TrackerOfflineValidation.cc.

Referenced by analyze(), and bookGlobalHists().

std::vector<TH1*> TrackerOfflineValidation::vTrackHistos_
private

Definition at line 268 of file TrackerOfflineValidation.cc.

Referenced by analyze(), bookGlobalHists(), and endJob().

std::vector<TH1*> TrackerOfflineValidation::vTrackProfiles_
private

Definition at line 269 of file TrackerOfflineValidation.cc.

Referenced by analyze(), and bookGlobalHists().