131 histtitle =
"muonPt";
136 histname =
"muonPtNoDxyCut";
137 histtitle =
"muonPtNoDxyCut";
147 histname =
"muonPt_variable";
148 histtitle =
"muonPt";
152 histname =
"muonPtVsLS";
153 histtitle =
"muonPt vs LS";
165 histname =
"muonEta";
166 histtitle =
"muonEta";
171 histname =
"muonPhi";
172 histtitle =
"muonPhi";
177 histname =
"muonDxy";
178 histtitle =
"muonDxy";
184 histname =
"subMuonPt";
185 histtitle =
"subMuonPt";
190 histname =
"subMuonPt_variable";
191 histtitle =
"subMuonPt";
195 histname =
"subMuonEta";
196 histtitle =
"subMuonEta";
206 histname =
"subMuonPhi";
207 histtitle =
"subMuonPhi";
217 histname =
"subMuonDxy";
218 histtitle =
"subMuonDxy";
241 const int ls =
iEvent.id().luminosityBlock();
245 if ((
unsigned int)(DSAHandle->size()) <
nmuons_)
247 std::vector<edm::Ptr<reco::Track>> dsaMuonPtrs_{};
248 for (
size_t i(0);
i != DSAHandle->size(); ++
i) {
249 dsaMuonPtrs_.emplace_back(DSAHandle,
i);
251 std::vector<edm::Ptr<reco::Track>>
muons{}, muonsCutOnPt{}, muonsCutOnDxy{}, muonsCutOnPtAndDxy{};
255 std::copy_if(dsaMuonPtrs_.begin(), dsaMuonPtrs_.end(), back_inserter(
muons), selectGeneral_);
261 return lhs->
pt() > rhs->pt();
267 std::copy_if(
muons.begin(),
muons.end(), back_inserter(muonsCutOnPt), selectOnPt_);
270 std::copy_if(
muons.begin(),
muons.end(), back_inserter(muonsCutOnDxy), selectOnDxy_);
272 auto selectOnPtAndDxy_(
274 std::copy_if(
muons.begin(),
muons.end(), back_inserter(muonsCutOnPtAndDxy), selectOnPtAndDxy_);
276 std::sort(muonsCutOnPt.begin(), muonsCutOnPt.end(), ptSorter_);
277 std::sort(muonsCutOnDxy.begin(), muonsCutOnDxy.end(), ptSorter_);
278 std::sort(muonsCutOnPtAndDxy.begin(), muonsCutOnPtAndDxy.end(), ptSorter_);
283 if (muonsCutOnDxy.size() >=
nmuons_) {
294 if (muonsCutOnPtAndDxy.size() >=
nmuons_) {
303 if (muonsCutOnPt.size() >=
nmuons_) {
317 if (muonsCutOnDxy.size() >=
nmuons_) {
328 if (muonsCutOnPtAndDxy.size() >=
nmuons_) {
337 if (muonsCutOnPt.size() >=
nmuons_) {
349 desc.add<
bool>(
"requireValidHLTPaths",
true);
352 desc.add<
unsigned int>(
"nmuons", 2);
381 std::vector<double>
bins = {0., 20., 40., 60., 80., 90., 100., 110., 120., 130., 140., 150., 160.,
382 170., 180., 190., 200., 220., 240., 260., 280., 300., 350., 400., 450., 1000.};
387 descriptions.
add(
"DiDispStaMuonMonitoring",
desc);
muonSelection
MU SELECTION #########################.
~DiDispStaMuonMonitor() override
void bookHistograms(DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override
std::vector< double > muonPt_variable_binning_
virtual void setCurrentFolder(std::string const &fullpath)
const bool requireValidHLTPaths_
std::vector< Track > TrackCollection
collection of Tracks
Provides a code based selection for trigger and DCS information in order to have no failing filters i...
static void fillHistoPSetDescription(edm::ParameterSetDescription &pset)
const std::string folderName_
denGenericTriggerEventPSet
std::unique_ptr< T, impl::DeviceDeleter > unique_ptr
void setMETitle(ObjME &me, const std::string &titleX, const std::string &titleY)
MEbinning muonPt_binning_
dqm::reco::MonitorElement MonitorElement
double pt() const
track transverse momentum
static MEbinning getHistoPSet(const edm::ParameterSet &pset)
std::unique_ptr< GenericTriggerEventFlag > num_genTriggerEventFlag_
void analyze(edm::Event const &iEvent, edm::EventSetup const &iSetup) override
StringCutObjectSelector< reco::Track, true > muonSelectionDxy_
StringCutObjectSelector< reco::Track, true > muonSelectionGeneral_
MEbinning muonEta_binning_
MonitorElement * denominator
DiDispStaMuonMonitor(const edm::ParameterSet &)
MonitorElement * numerator
MEbinning muonDxy_binning_
#define DEFINE_FWK_MODULE(type)
ObjME muonPtME_variableBinning_
std::unique_ptr< GenericTriggerEventFlag > den_genTriggerEventFlag_
dqm::reco::DQMStore DQMStore
ObjME subMuonPtME_variableBinning_
void add(std::string const &label, ParameterSetDescription const &psetDescription)
StringCutObjectSelector< reco::Track, true > muonSelectionPt_
void bookME(DQMStore::IBooker &, ObjME &me, const std::string &histname, const std::string &histtitle, const uint nbins, const double xmin, const double xmax, const bool bookDen=true)
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
MEbinning muonPhi_binning_
edm::EDGetTokenT< reco::TrackCollection > muonToken_
static void fillPSetDescription(edm::ParameterSetDescription &desc)
numGenericTriggerEventPSet