44 temp_all_hits.clear();
49 for (
const auto& it_rh : ds_rh2.data) {
50 CLHEP::Hep3Vector localV(it_rh.point().x(), it_rh.point().y(), it_rh.point().z());
53 localError[0][0] = it_rh.error().xx();
54 localError[0][1] = it_rh.error().xy();
55 localError[0][2] = 0.;
56 localError[1][0] = it_rh.error().xy();
57 localError[1][1] = it_rh.error().yy();
58 localError[1][2] = 0.;
59 localError[2][0] = 0.;
60 localError[2][1] = 0.;
61 localError[2][2] = 0.;
63 edm::LogInfo(
"RPixRoadFinder") <<
"Hits = " << ds_rh2.data.size();
67 theRotationMatrix.GetComponents(theRotationTMatrix(0, 0),
68 theRotationTMatrix(0, 1),
69 theRotationTMatrix(0, 2),
70 theRotationTMatrix(1, 0),
71 theRotationTMatrix(1, 1),
72 theRotationTMatrix(1, 2),
73 theRotationTMatrix(2, 0),
74 theRotationTMatrix(2, 1),
75 theRotationTMatrix(2, 2));
78 PointInPlane thePointAndRecHit = {globalV, globalError, it_rh, myid};
79 temp_all_hits.push_back(thePointAndRecHit);
83 Road::iterator it_gh1 = temp_all_hits.begin();
84 Road::iterator it_gh2;
90 while (it_gh1 != temp_all_hits.end() && temp_all_hits.size() >=
minRoadSize_) {
95 CLHEP::Hep3Vector currPoint = it_gh1->globalPoint;
98 while (it_gh2 != temp_all_hits.end()) {
99 bool same_pot =
false;
101 if (currDet.
rpId() == tmpGh2Id.
rpId())
103 CLHEP::Hep3Vector subtraction = currPoint - it_gh2->globalPoint;
105 if (subtraction.perp() <
roadRadius_ && same_pot) {
106 temp_road.push_back(*it_gh2);
107 temp_all_hits.erase(it_gh2);
ROOT::Math::SMatrix< double, 3, 3, ROOT::Math::MatRepStd< double, 3, 3 > > AlgebraicMatrix33
unsigned int maxRoadSize_
std::vector< PointInPlane > Road
const CTPPSGeometry * geometry_
const edm::DetSetVector< CTPPSPixelRecHit > * hitVector_
CLHEP::Hep3Vector localToGlobal(const DetGeomDesc *, const CLHEP::Hep3Vector &) const
std::vector< Road > patternVector_
RotationMatrix rotation() const
geometry information
const DetGeomDesc * sensor(unsigned int id) const
returns geometry of a detector performs necessary checks, returns NULL if fails
unsigned int minRoadSize_
ROOT::Math::Rotation3D RotationMatrix