69 minZ_(
config.getParameter<double>(
"minZ")),
70 maxZ_(
config.getParameter<double>(
"maxZ")),
71 zStep_(
config.getParameter<double>(
"zStep")) {
73 trackerToken_ = esConsumes<TrackerGeometry, TrackerDigiGeometryRecord>();
75 produces<reco::ClusterCompatibility>();
81 auto creco = std::make_unique<reco::ClusterCompatibility>();
88 if (hRecHits.isValid()) {
95 std::vector<VertexHit> vhits;
107 std::vector<SiPixelCluster::Pixel> pixels(
hit->cluster()->pixels());
108 bool pixelOnEdge =
false;
109 for (std::vector<SiPixelCluster::Pixel>::const_iterator
pixel = pixels.begin();
pixel != pixels.end(); ++
pixel) {
110 int pixelX =
pixel->x;
111 int pixelY =
pixel->y;
125 vh.
w =
hit->cluster()->sizeY();
129 creco->setNValidPixelHits(nPxlHits);
134 creco->append(
c.z0,
c.nHit,
c.chi);
141 const std::vector<VertexHit> &
hits,
double z0)
const {
146 for (std::vector<VertexHit>::const_iterator
hit =
hits.begin();
hit !=
hits.end();
hit++) {
151 double p = 2 * fabs(
hit->
z -
z0) /
hit->r + 0.5;
152 if (fabs(
p -
hit->w) <= 1.) {
153 chi += fabs(
p -
hit->w);
Point3DBase< Scalar, LocalTag > LocalPoint
virtual bool isItEdgePixelInX(int ixbin) const =0
T const * product() const
ClusterCompatibilityProducer(const edm::ParameterSet &)
#define DEFINE_FWK_MODULE(type)
ContainedHits getContainedHits(const std::vector< VertexHit > &hits, double z0) const
ESHandle< T > getHandle(const ESGetToken< T, R > &iToken) const
const TrackerGeomDet * idToDet(DetId) const override
GlobalPoint toGlobal(const Local2DPoint &lp) const
Conversion to the global R.F. from the R.F. of the GeomDet.
boost::transform_iterator< IterHelp, const_IdIter > const_iterator
edm::ESGetToken< TrackerGeometry, TrackerDigiGeometryRecord > trackerToken_
edm::EDGetTokenT< SiPixelRecHitCollection > inputToken_
virtual bool isItEdgePixelInY(int iybin) const =0
virtual const PixelTopology & specificTopology() const
Returns a reference to the pixel proxy topology.
~ClusterCompatibilityProducer() override
void produce(edm::Event &, const edm::EventSetup &) override