72 edm::LogError(
"ME0RecHitsValidation") <<
"Cannot get ME0Hits/ME0RecHits by Token simInputTagToken";
76 for (
auto hits = ME0Hits->begin();
hits != ME0Hits->end();
hits++) {
78 Int_t sh_region =
id.region();
79 Int_t sh_layer =
id.layer();
81 Int_t sh_chamber =
id.chamber();
82 Int_t sh_roll =
id.roll();
85 if (ME0Geometry_->
idToDet(
hits->detUnitId()) ==
nullptr) {
86 std::cout <<
"simHit did not matched with GEMGeometry." << std::endl;
93 Float_t
x =
recHit->localPosition().x();
94 Float_t xErr =
recHit->localPositionError().xx();
95 Float_t
y =
recHit->localPosition().y();
96 Float_t yErr =
recHit->localPositionError().yy();
99 Float_t clusterSize = 0;
100 Float_t firstClusterStrip = 0;
104 Short_t region = (Short_t)
id.region();
106 Short_t layer = (Short_t)
id.layer();
108 Short_t roll = (Short_t)
id.roll();
113 Float_t globalR = rhGP.
perp();
114 Float_t globalX = rhGP.
x();
115 Float_t globalY = rhGP.
y();
116 Float_t globalZ = rhGP.
z();
118 Float_t x_sim = hitLP.x();
119 Float_t y_sim = hitLP.y();
120 Float_t pullX = (x_sim -
x) /
sqrt(xErr);
121 Float_t pullY = (y_sim -
y) /
sqrt(yErr);
126 std::vector<int> stripsFired;
127 for (
int i = firstClusterStrip;
i < (firstClusterStrip + clusterSize);
i++) {
128 stripsFired.push_back(
i);
131 const bool cond1(sh_region == region and sh_layer == layer and sh_station == station);
132 const bool cond2(sh_chamber == chamber and sh_roll == roll);
134 (
std::find(stripsFired.begin(), stripsFired.end(), (firstClusterStrip + 1)) != stripsFired.end())
or 140 else if (region == 1)
142 int layer_num = layer - 1;
144 if (cond1 and cond2 and cond3) {
edm::EDGetToken InputTagToken_RecHit
MonitorElement * me0_rh_DeltaX[2][6]
MonitorElement * me0_rh_PullY[2][6]
bool getByToken(EDGetToken token, Handle< PROD > &result) const
GlobalPoint toGlobal(const Local2DPoint &lp) const
Conversion to the global R.F. from the R.F. of the GeomDet.
MonitorElement * me0_rh_xy[2][6]
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
MonitorElement * me0_rh_zr[2]
C::const_iterator const_iterator
constant access iterator type
The Signals That Services Can Subscribe To This is based on ActivityRegistry and is current per Services can connect to the signals distributed by the ActivityRegistry in order to monitor the activity of the application Each possible callback has some defined which we here list in angle e< void, edm::EventID const &, edm::Timestamp const & > We also list in braces which AR_WATCH_USING_METHOD_ is used for those or
MonitorElement * me0_rh_PullX[2][6]
const GeomDet * idToDet(DetId) const override
edm::EDGetToken InputTagToken_
MonitorElement * me0_rh_DeltaY[2][6]