19 unsigned int nHitsBeforeVtxMax) {
36 double lxy = (mom.x() * dbsx + mom.y() * dbsy) / mom.rho();
43 for (std::vector<uint8_t>::const_iterator
it =
conv.nHitsBeforeVtx().begin();
it !=
conv.nHitsBeforeVtx().end();
45 if ((*
it) > nHitsBeforeVtxMax)
56 bool allowAmbiguousGsfMatch) {
61 const std::vector<edm::RefToBase<reco::Track> > &convTracks =
conv.tracks();
64 if (ele.reco::GsfElectron::gsfTrack().isNonnull() && ele.reco::GsfElectron::gsfTrack().id() ==
it->id() &&
65 ele.reco::GsfElectron::gsfTrack().key() ==
it->key())
67 else if (allowCkfMatch && ele.reco::GsfElectron::closestCtfTrackRef().isNonnull() &&
68 ele.reco::GsfElectron::closestCtfTrackRef().id() ==
it->id() &&
69 ele.reco::GsfElectron::closestCtfTrackRef().key() ==
it->key())
71 if (allowAmbiguousGsfMatch) {
73 if (tk.isNonnull() && tk.id() ==
it->id() && tk.key() ==
it->key())
90 for (
const auto &trkRef :
conv.tracks()) {
116 float dEta = mom.eta() - cscvector.eta();
136 const std::vector<edm::RefToBase<reco::Track> > &convTracks =
conv.tracks();
139 if (trk.
id() ==
it->id() && trk.
key() ==
it->key())
153 const std::vector<edm::RefToBase<reco::Track> > &convTracks =
conv.tracks();
156 if (trk.
id() ==
it->id() && trk.
key() ==
it->key())
170 const std::vector<edm::RefToBase<reco::Track> > &convTracks =
conv.tracks();
173 if (trk.
id() ==
it->id() && trk.
key() ==
it->key())
187 unsigned int nHitsBeforeVtxMax) {
192 for (
auto const &
it : convCol) {
193 if (!matchesConversion(ele,
it, allowCkfMatch))
210 unsigned int nHitsBeforeVtxMax) {
217 for (
auto const &
it : convCol) {
218 if (!matchesConversion(trk,
it))
238 unsigned int nHitsBeforeVtxMax) {
242 for (
auto const &
it : convCol) {
243 if (!matchesConversion(sc,
it))
261 unsigned int nHitsBeforeVtxMax) {
270 double minRho = 999.;
271 for (
auto const &
it : convCol) {
272 float rho =
it.conversionVertex().position().rho();
275 if (!matchesConversion(ele,
it, allowCkfMatch))
294 unsigned int nHitsBeforeVtxMax) {
303 double minRho = 999.;
304 for (
auto const &
it : convCol) {
305 float rho =
it.conversionVertex().position().rho();
308 if (!matchesConversion(eleCore,
it, allowCkfMatch))
326 unsigned int nHitsBeforeVtxMax) {
337 double minRho = 999.;
338 for (
auto const &
it : convCol) {
339 float rho =
it.conversionVertex().position().rho();
342 if (!matchesConversion(trk,
it))
363 unsigned int nHitsBeforeVtxMax) {
371 double minRho = 999.;
372 for (
auto const &
it : convCol) {
373 float rho =
it.conversionVertex().position().rho();
396 unsigned int nHitsBeforeVtxMax) {
397 return !(matchedPromptElectron(sc, eleCol, convCol,
beamspot, allowCkfMatch, lxyMin,
probMin, nHitsBeforeVtxMax) ==
409 unsigned int nHitsBeforeVtxMax) {
418 for (
auto const &
it : eleCol) {
420 if (
it.superCluster() != sc)
428 if (hasMatchedConversion(
it, convCol,
beamspot, allowCkfMatch, lxyMin,
probMin, nHitsBeforeVtxMax))
439 if (
conv !=
nullptr) {
442 return TMath::Prob(
vtx.chi2(),
vtx.ndof());
constexpr double deltaPhi(double phi1, double phi2)
const math::XYZPoint & position() const
cluster centroid position
ProductID id() const
Accessor for product ID.
TrackRef ctfTrack() const
bool isNonnull() const
Checks for non-null.
std::vector< GsfElectron > GsfElectronCollection
collection of GsfElectron objects
key_type key() const
Accessor for product key.
std::vector< Conversion > ConversionCollection
collectin of Conversion objects
auto const & ambiguousGsfTracks() const
bool isNull() const
Checks for null.
bool isNull() const
Checks for null.
constexpr auto deltaR(const T1 &t1, const T2 &t2) -> decltype(t1.eta())
XYZVectorD XYZVector
spatial vector with cartesian internal representation
XYZPointD XYZPoint
point in space with cartesian internal representation
const GsfTrackRef & gsfTrack() const
std::string match(BranchDescription const &a, BranchDescription const &b, std::string const &fileName)