27 edm::LogInfo(
"GEMRecHitTrackMatch")<<
"GEM RecHitTrackMatch :: bookHistograms"<<std::endl;
31 edm::LogInfo(
"GEMRecHitTrackMatch")<<
"GEM RecHitTrackMatch :: about to set the geometry"<<std::endl;
33 edm::LogInfo(
"GEMRecHitTrackMatch")<<
"GEM RecHitTrackMatch :: successfully set the geometry"<<std::endl;
34 edm::LogInfo(
"GEMRecHitTrackMatch")<<
"GEM RecHitTrackMatch :: geom = "<<&geom<<std::endl;
37 edm::LogInfo(
"GEMRecHitTrackMatch")<<
"ibooker set current folder\n";
44 for(
unsigned int j=0 ; j<
nstation ; j++) {
46 string track_eta_title =
string(
"track_eta")+
";SimTrack |#eta|;# of tracks";
49 for (
unsigned int k = 0 ;
k <
c_suffix.size() ;
k++) {
52 string track_phi_title =
string(
"track_phi")+suffix+
";SimTrack #phi;# of tracks";
60 string rh_eta_title = rh_eta_name+
"; tracks |#eta|; # of tracks";
64 string rh_sh_eta_title = rh_sh_eta_name+
"; tracks |#eta|; # of tracks";
67 for (
unsigned int k = 0 ;
k <
c_suffix.size() ;
k++) {
70 string rh_phi_title = rh_phi_name+
"; tracks #phi; # of tracks";
71 rh_phi[
i][j][
k] = ibooker.
book1D( (rh_phi_name).c_str(), rh_phi_title.c_str(), 200, -
PI,
PI) ;
74 string rh_sh_phi_title = rh_sh_phi_name+
"; tracks #phi; # of tracks";
86 edm::LogInfo(
"GEMRecHitTrackMatch")<<
"GEM RecHitTrackMatch :: analyze"<<std::endl;
104 for (
auto&
t: sim_trks)
114 track_.
pt =
t.momentum().pt();
116 track_.
phi =
t.momentum().phi();
117 track_.
eta =
t.momentum().eta();
121 for (
int i= 0 ;
i< 3 ;
i++) {
122 for (
int j= 0 ; j<2 ; j++) {
130 for(
auto d: gem_sh_ids_ch)
134 else if (
id.
chamber() %2 ==1 ) track_.
hitOdd[
id.station()-1] =
true;
135 else {
edm::LogInfo(
"GEMRecHitTrackMatch")<<
"Error to get chamber id"<<std::endl; }
137 track_.
gem_sh[
id.station()-1][ (
id.layer()-1)] =
true;
141 const auto gem_rh_ids_ch = match_rh.
chamberIds();
143 for(
auto d: gem_rh_ids_ch)
146 track_.
gem_rh[
id.station()-1][ (
id.layer()-1)] =
true;
T getParameter(std::string const &) const
T getUntrackedParameter(std::string const &, T const &) const
std::set< unsigned int > chamberIds() const
static const std::array< std::string, 4 > l_suffix
MonitorElement * rh_phi[4][3][3]
bool getByToken(EDGetToken token, Handle< PROD > &result) const
MonitorElement * track_phi[3][3]
std::set< unsigned int > chamberIdsGEM() const
GEM chamber detIds with SimHits.
edm::EDGetToken simHitsToken_
edm::EDGetToken simVerticesToken_
MonitorElement * rh_sh_phi[4][3][3]
void setGeometry(const GEMGeometry &geom)
GEMRecHitTrackMatch(const edm::ParameterSet &ps)
void bookHistograms(DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override
MonitorElement * rh_sh_eta[4][3]
static const std::array< std::string, 2 > s_suffix
edm::EDGetToken simTracksToken_
const std::vector< const GEMRegion * > & regions() const
Return a vector of all GEM regions.
MonitorElement * book1D(Args &&...args)
~GEMRecHitTrackMatch() override
edm::EDGetToken gem_recHitToken_
void setCurrentFolder(const std::string &fullpath)
T const * product() const
MonitorElement * track_eta[3]
void FillWithTrigger(MonitorElement *me[3], Float_t eta)
void analyze(const edm::Event &e, const edm::EventSetup &) override
MonitorElement * rh_eta[4][3]
bool isSimTrackGood(const SimTrack &)
std::vector< SimTrack > SimTrackContainer
static const std::array< std::string, 3 > c_suffix