Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[14_1_X] Additional tracks filter for vertices (minimum no. strip hits) #45970

Merged
merged 1 commit into from
Sep 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ class TrackFilterForPVFinding : public TrackFilterForPVFindingBase {
private:
float maxD0Sig_, minPt_, maxEta_;
float maxD0Error_, maxDzError_;
int minSiLayers_, minPxLayers_;
int minSiLayers_, minPxLayers_, minStripHits_;
float maxNormChi2_;
reco::TrackBase::TrackQuality quality_;
};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ TrackFilterForPVFinding::TrackFilterForPVFinding(const edm::ParameterSet& conf)
maxNormChi2_ = conf.getParameter<double>("maxNormalizedChi2");
minSiLayers_ = conf.getParameter<int>("minSiliconLayersWithHits");
minPxLayers_ = conf.getParameter<int>("minPixelLayersWithHits");
minStripHits_ = conf.getParameter<int>("minValidStripHits");

// the next few lines are taken from RecoBTag/SecondaryVertex/interface/TrackSelector.h"
std::string qualityClass = conf.getParameter<std::string>("trackQuality");
Expand All @@ -33,8 +34,9 @@ bool TrackFilterForPVFinding::operator()(const reco::TransientTrack& tk) const {
bool nPxLayCut = tk.hitPattern().pixelLayersWithMeasurement() >= minPxLayers_;
bool nSiLayCut = tk.hitPattern().trackerLayersWithMeasurement() >= minSiLayers_;
bool trackQualityCut = (quality_ == reco::TrackBase::undefQuality) || tk.track().quality(quality_);
bool nStripHitsCut = tk.hitPattern().numberOfValidStripHits() >= minStripHits_;

return IPSigCut && pTCut && etaCut && normChi2Cut && nPxLayCut && nSiLayCut && trackQualityCut;
return IPSigCut && pTCut && etaCut && normChi2Cut && nPxLayCut && nSiLayCut && trackQualityCut && nStripHitsCut;
}

// select the vector of tracks that pass the filter cuts
Expand Down Expand Up @@ -72,4 +74,5 @@ void TrackFilterForPVFinding::fillPSetDescription(edm::ParameterSetDescription&
desc.add<std::string>("trackQuality", "any");
desc.add<int>("minPixelLayersWithHits", 2);
desc.add<int>("minSiliconLayersWithHits", 5);
desc.add<int>("minValidStripHits", 0);
}