36 int getContainedHits(
const vector<VertexHit>&
hits,
float z0,
float& chi) {
40 for (vector<VertexHit>::const_iterator
hit =
hits.begin();
hit !=
hits.end();
hit++) {
42 float p = 2 * fabs(
hit->
z - z0) /
hit->r + 0.5;
44 if (fabs(
p -
hit->w) <= 1.) {
45 chi += fabs(
p -
hit->w);
58 produces<reco::VertexCollection>();
75 auto vertices = std::make_unique<reco::VertexCollection>();
77 if (!thePixelHits->
empty()) {
78 vector<VertexHit>
hits;
81 recHitEnd = thePixelHits->
data().end();
89 vector<SiPixelCluster::Pixel> pixels =
recHit->cluster()->pixels();
91 bool pixelOnEdge =
false;
92 for (vector<SiPixelCluster::Pixel>::const_iterator
pixel = pixels.begin();
pixel != pixels.end();
pixel++) {
94 int pos_y = (
int)
pixel->y;
122 float chi_max = 1
e+9;
126 for (
float z0 = -15.9;
z0 <= 15.95;
z0 += 0.1) {
130 if (
nhits > nhits_max) {
135 if (
nhits >= nhits_max)
143 LogTrace(
"MinBiasTracking") <<
" [vertex position] estimated = " << zest
144 <<
" | pixel barrel hits = " << thePixelHits->
size();
147 err(2, 2) = 0.6 * 0.6;
Point3DBase< Scalar, LocalTag > LocalPoint
T const & getData(const ESGetToken< T, R > &iToken) const noexcept(false)
const TrackerGeomDet * idToDetUnit(DetId) const override
Return the pointer to the GeomDetUnit corresponding to a given DetId.
const edm::ESGetToken< TrackerGeometry, TrackerDigiGeometryRecord > geomToken_
edm::EDGetTokenT< SiPixelRecHitCollection > pixelToken_
T const * product() const
data_type const * data(size_t cell) const
math::Error< dimension >::type Error
covariance error matrix (3x3)
void produce(edm::StreamID, edm::Event &ev, const edm::EventSetup &es) const override
virtual bool isItEdgePixelInX(int ixbin) const =0
~PixelVertexProducerClusters() override
math::XYZPoint Point
point in the space
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
virtual bool isItEdgePixelInY(int iybin) const =0
virtual const PixelTopology & specificTopology() const
Returns a reference to the pixel proxy topology.
PixelVertexProducerClusters(const edm::ParameterSet &ps)