27 #include "CLHEP/Random/RandFlat.h"
43 : muonSource_(iConfig.getParameter<
edm::
InputTag>(
"muonSource")),
44 isoEmSource_(iConfig.getParameter<
edm::
InputTag>(
"isolatedEmSource")),
45 nonIsoEmSource_(iConfig.getParameter<
edm::
InputTag>(
"nonIsolatedEmSource")),
46 cenJetSource_(iConfig.getParameter<
edm::
InputTag>(
"centralJetSource")),
47 forJetSource_(iConfig.getParameter<
edm::
InputTag>(
"forwardJetSource")),
48 tauJetSource_(iConfig.getParameter<
edm::
InputTag>(
"tauJetSource")),
49 etMissSource_(iConfig.getParameter<
edm::
InputTag>(
"etMissSource")),
50 htMissSource_(iConfig.getParameter<
edm::
InputTag>(
"htMissSource")) {
54 produces<L1ParticleMapCollection>();
55 produces<L1GlobalTriggerReadoutRecord>();
58 for (
int i = 0;
i < L1ParticleMap::kNumOfL1TriggerTypes; ++
i) {
260 iConfig.
getParameter<
double>(
"L1_IsoEG10_TauJet20_thresh1");
262 iConfig.
getParameter<
double>(
"L1_IsoEG10_TauJet20_thresh2");
265 iConfig.
getParameter<
double>(
"L1_IsoEG10_TauJet30_thresh1");
267 iConfig.
getParameter<
double>(
"L1_IsoEG10_TauJet30_thresh2");
302 iConfig.
getParameter<
double>(
"L1_TauJet40_HTT200_thresh2");
348 iConfig.
getParameter<
double>(
"L1_DoubleMu3_IsoEG5_thresh1");
350 iConfig.
getParameter<
double>(
"L1_DoubleMu3_IsoEG5_thresh2");
356 iConfig.
getParameter<
double>(
"L1_DoubleIsoEG5_Mu3_thresh1");
358 iConfig.
getParameter<
double>(
"L1_DoubleIsoEG5_Mu3_thresh2");
365 iConfig.
getParameter<
double>(
"L1_DoubleMu3_HTT200_thresh1");
367 iConfig.
getParameter<
double>(
"L1_DoubleMu3_HTT200_thresh2");
370 iConfig.
getParameter<
double>(
"L1_DoubleIsoEG5_HTT200_thresh1");
372 iConfig.
getParameter<
double>(
"L1_DoubleIsoEG5_HTT200_thresh2");
373 prescales_[L1ParticleMap::kDoubleIsoEG5_HTT200] = iConfig.
getParameter<
int>(
"L1_DoubleIsoEG5_HTT200_prescale");
375 iConfig.
getParameter<
double>(
"L1_DoubleEG10_HTT200_thresh1");
377 iConfig.
getParameter<
double>(
"L1_DoubleEG10_HTT200_thresh2");
378 prescales_[L1ParticleMap::kDoubleEG10_HTT200] = iConfig.
getParameter<
int>(
"L1_DoubleEG10_HTT200_prescale");
380 iConfig.
getParameter<
double>(
"L1_DoubleJet50_HTT200_thresh1");
382 iConfig.
getParameter<
double>(
"L1_DoubleJet50_HTT200_thresh2");
383 prescales_[L1ParticleMap::kDoubleJet50_HTT200] = iConfig.
getParameter<
int>(
"L1_DoubleJet50_HTT200_prescale");
385 iConfig.
getParameter<
double>(
"L1_DoubleTauJet40_HTT200_thresh1");
387 iConfig.
getParameter<
double>(
"L1_DoubleTauJet40_HTT200_thresh2");
388 prescales_[L1ParticleMap::kDoubleTauJet40_HTT200] = iConfig.
getParameter<
int>(
"L1_DoubleTauJet40_HTT200_prescale");
392 iConfig.
getParameter<
double>(
"L1_DoubleMu3_ETM20_thresh2");
395 iConfig.
getParameter<
double>(
"L1_DoubleIsoEG5_ETM20_thresh1");
397 iConfig.
getParameter<
double>(
"L1_DoubleIsoEG5_ETM20_thresh2");
398 prescales_[L1ParticleMap::kDoubleIsoEG5_ETM20] = iConfig.
getParameter<
int>(
"L1_DoubleIsoEG5_ETM20_prescale");
400 iConfig.
getParameter<
double>(
"L1_DoubleEG10_ETM20_thresh1");
402 iConfig.
getParameter<
double>(
"L1_DoubleEG10_ETM20_thresh2");
405 iConfig.
getParameter<
double>(
"L1_DoubleJet50_ETM20_thresh1");
407 iConfig.
getParameter<
double>(
"L1_DoubleJet50_ETM20_thresh2");
408 prescales_[L1ParticleMap::kDoubleJet50_ETM20] = iConfig.
getParameter<
int>(
"L1_DoubleJet50_ETM20_prescale");
410 iConfig.
getParameter<
double>(
"L1_DoubleTauJet40_ETM20_thresh1");
412 iConfig.
getParameter<
double>(
"L1_DoubleTauJet40_ETM20_thresh2");
413 prescales_[L1ParticleMap::kDoubleTauJet40_ETM20] = iConfig.
getParameter<
int>(
"L1_DoubleTauJet40_ETM20_prescale");
420 iConfig.
getParameter<
double>(
"L1_ExclusiveDoubleIsoEG4_thresh1");
422 iConfig.
getParameter<
double>(
"L1_ExclusiveDoubleIsoEG4_thresh2");
423 prescales_[L1ParticleMap::kExclusiveDoubleIsoEG4] = iConfig.
getParameter<
int>(
"L1_ExclusiveDoubleIsoEG4_prescale");
425 iConfig.
getParameter<
double>(
"L1_ExclusiveDoubleJet60_thresh");
426 prescales_[L1ParticleMap::kExclusiveDoubleJet60] = iConfig.
getParameter<
int>(
"L1_ExclusiveDoubleJet60_prescale");
428 iConfig.
getParameter<
double>(
"L1_ExclusiveJet25_Gap_Jet25_thresh");
429 prescales_[L1ParticleMap::kExclusiveJet25_Gap_Jet25] =
430 iConfig.
getParameter<
int>(
"L1_ExclusiveJet25_Gap_Jet25_prescale");
432 iConfig.
getParameter<
double>(
"L1_IsoEG10_Jet20_ForJet10_thresh1");
434 iConfig.
getParameter<
double>(
"L1_IsoEG10_Jet20_ForJet10_thresh2");
436 iConfig.
getParameter<
double>(
"L1_IsoEG10_Jet20_ForJet10_thresh3");
437 prescales_[L1ParticleMap::kIsoEG10_Jet20_ForJet10] = iConfig.
getParameter<
int>(
"L1_IsoEG10_Jet20_ForJet10_prescale");
499 using namespace reco;
531 double ht = mhtHandle->
etTotal();
532 double ett = metHandle->
etTotal();
563 L1MuonParticleCollection::const_iterator muItr = muHandle->begin();
564 L1MuonParticleCollection::const_iterator muEnd = muHandle->end();
566 for (
size_t i = 0; muItr != muEnd; ++muItr, ++
i) {
567 if (!muItr->gmtMuonCand().empty()) {
568 unsigned int qual = muItr->gmtMuonCand().quality();
570 if (qual == 4 || qual == 5 || qual == 6 || qual == 7) {
574 if (qual == 3 || qual == 5 || qual == 6 || qual == 7) {
581 bool globalDecision =
false;
582 std::vector<bool> decisionWord;
584 for (
int itrig = 0; itrig < L1ParticleMap::kNumOfL1TriggerTypes; ++itrig) {
585 bool decision =
false;
586 std::vector<L1ParticleMap::L1ObjectType>
objectTypes;
593 if (itrig == L1ParticleMap::kSingleMu3 || itrig == L1ParticleMap::kSingleMu5 ||
594 itrig == L1ParticleMap::kSingleMu7 || itrig == L1ParticleMap::kSingleMu10 ||
595 itrig == L1ParticleMap::kSingleMu14 || itrig == L1ParticleMap::kSingleMu20 ||
596 itrig == L1ParticleMap::kSingleMu25) {
600 }
else if (itrig == L1ParticleMap::kSingleIsoEG5 || itrig == L1ParticleMap::kSingleIsoEG8 ||
601 itrig == L1ParticleMap::kSingleIsoEG10 || itrig == L1ParticleMap::kSingleIsoEG12 ||
602 itrig == L1ParticleMap::kSingleIsoEG15 || itrig == L1ParticleMap::kSingleIsoEG20 ||
603 itrig == L1ParticleMap::kSingleIsoEG25) {
607 }
else if (itrig == L1ParticleMap::kSingleEG5 || itrig == L1ParticleMap::kSingleEG8 ||
608 itrig == L1ParticleMap::kSingleEG10 || itrig == L1ParticleMap::kSingleEG12 ||
609 itrig == L1ParticleMap::kSingleEG15 || itrig == L1ParticleMap::kSingleEG20 ||
610 itrig == L1ParticleMap::kSingleEG25) {
614 }
else if (itrig == L1ParticleMap::kSingleJet15 || itrig == L1ParticleMap::kSingleJet20 ||
615 itrig == L1ParticleMap::kSingleJet30 || itrig == L1ParticleMap::kSingleJet50 ||
616 itrig == L1ParticleMap::kSingleJet70 || itrig == L1ParticleMap::kSingleJet100 ||
617 itrig == L1ParticleMap::kSingleJet150 || itrig == L1ParticleMap::kSingleJet200) {
621 }
else if (itrig == L1ParticleMap::kSingleTauJet10 || itrig == L1ParticleMap::kSingleTauJet20 ||
622 itrig == L1ParticleMap::kSingleTauJet30 || itrig == L1ParticleMap::kSingleTauJet35 ||
623 itrig == L1ParticleMap::kSingleTauJet40 || itrig == L1ParticleMap::kSingleTauJet60 ||
624 itrig == L1ParticleMap::kSingleTauJet80 || itrig == L1ParticleMap::kSingleTauJet100) {
628 }
else if (itrig == L1ParticleMap::kHTT100 || itrig == L1ParticleMap::kHTT200 || itrig == L1ParticleMap::kHTT250 ||
629 itrig == L1ParticleMap::kHTT300 || itrig == L1ParticleMap::kHTT400 || itrig == L1ParticleMap::kHTT500) {
636 }
else if (itrig == L1ParticleMap::kETM10 || itrig == L1ParticleMap::kETM15 || itrig == L1ParticleMap::kETM20 ||
637 itrig == L1ParticleMap::kETM30 || itrig == L1ParticleMap::kETM40 || itrig == L1ParticleMap::kETM50 ||
638 itrig == L1ParticleMap::kETM60) {
645 }
else if (itrig == L1ParticleMap::kETT60) {
652 }
else if (itrig == L1ParticleMap::kDoubleMu3) {
657 inputMuonRefsDouble,
singleThresholds_[itrig], decision, outputMuonRefsTmp, combosTmp);
658 }
else if (itrig == L1ParticleMap::kDoubleIsoEG8 || itrig == L1ParticleMap::kDoubleIsoEG10) {
663 }
else if (itrig == L1ParticleMap::kDoubleEG5 || itrig == L1ParticleMap::kDoubleEG10 ||
664 itrig == L1ParticleMap::kDoubleEG15) {
669 inputRelaxedEmRefs,
singleThresholds_[itrig], decision, outputEmRefsTmp, combosTmp);
670 }
else if (itrig == L1ParticleMap::kDoubleJet70 || itrig == L1ParticleMap::kDoubleJet100) {
675 }
else if (itrig == L1ParticleMap::kDoubleTauJet20 || itrig == L1ParticleMap::kDoubleTauJet30 ||
676 itrig == L1ParticleMap::kDoubleTauJet35 || itrig == L1ParticleMap::kDoubleTauJet40) {
681 }
else if (itrig == L1ParticleMap::kMu3_IsoEG5 || itrig == L1ParticleMap::kMu5_IsoEG10) {
693 }
else if (itrig == L1ParticleMap::kMu3_EG12) {
705 }
else if (itrig == L1ParticleMap::kMu3_Jet15 || itrig == L1ParticleMap::kMu5_Jet15 ||
706 itrig == L1ParticleMap::kMu3_Jet70 || itrig == L1ParticleMap::kMu5_Jet20) {
718 }
else if (itrig == L1ParticleMap::kMu5_TauJet20 || itrig == L1ParticleMap::kMu5_TauJet30) {
730 }
else if (itrig == L1ParticleMap::kIsoEG10_EG10) {
741 }
else if (itrig == L1ParticleMap::kIsoEG10_Jet15 || itrig == L1ParticleMap::kIsoEG10_Jet30 ||
742 itrig == L1ParticleMap::kIsoEG10_Jet20 || itrig == L1ParticleMap::kIsoEG10_Jet70) {
754 }
else if (itrig == L1ParticleMap::kIsoEG10_TauJet20 || itrig == L1ParticleMap::kIsoEG10_TauJet30) {
766 }
else if (itrig == L1ParticleMap::kEG10_Jet15 || itrig == L1ParticleMap::kEG12_Jet20 ||
767 itrig == L1ParticleMap::kEG12_Jet70) {
779 }
else if (itrig == L1ParticleMap::kEG12_TauJet40) {
791 }
else if (itrig == L1ParticleMap::kJet70_TauJet40) {
802 }
else if (itrig == L1ParticleMap::kMu3_HTT200) {
813 }
else if (itrig == L1ParticleMap::kIsoEG10_HTT200) {
824 }
else if (itrig == L1ParticleMap::kEG12_HTT200) {
835 }
else if (itrig == L1ParticleMap::kJet70_HTT200) {
846 }
else if (itrig == L1ParticleMap::kTauJet40_HTT200) {
857 }
else if (itrig == L1ParticleMap::kMu3_ETM30) {
868 }
else if (itrig == L1ParticleMap::kIsoEG10_ETM30) {
879 }
else if (itrig == L1ParticleMap::kEG12_ETM30) {
890 }
else if (itrig == L1ParticleMap::kJet70_ETM40) {
901 }
else if (itrig == L1ParticleMap::kTauJet20_ETM20 || itrig == L1ParticleMap::kTauJet30_ETM30 ||
902 itrig == L1ParticleMap::kTauJet30_ETM40) {
913 }
else if (itrig == L1ParticleMap::kHTT100_ETM30) {
921 }
else if (itrig == L1ParticleMap::kTripleMu3) {
927 inputMuonRefsDouble,
singleThresholds_[itrig], decision, outputMuonRefsTmp, combosTmp);
928 }
else if (itrig == L1ParticleMap::kTripleIsoEG5) {
934 }
else if (itrig == L1ParticleMap::kTripleEG10) {
940 inputRelaxedEmRefs,
singleThresholds_[itrig], decision, outputEmRefsTmp, combosTmp);
941 }
else if (itrig == L1ParticleMap::kTripleJet50) {
947 }
else if (itrig == L1ParticleMap::kTripleTauJet40) {
953 }
else if (itrig == L1ParticleMap::kDoubleMu3_IsoEG5) {
966 }
else if (itrig == L1ParticleMap::kDoubleMu3_EG10) {
979 }
else if (itrig == L1ParticleMap::kDoubleIsoEG5_Mu3) {
992 }
else if (itrig == L1ParticleMap::kDoubleEG10_Mu3) {
1005 }
else if (itrig == L1ParticleMap::kDoubleMu3_HTT200) {
1018 }
else if (itrig == L1ParticleMap::kDoubleIsoEG5_HTT200) {
1031 }
else if (itrig == L1ParticleMap::kDoubleEG10_HTT200) {
1044 }
else if (itrig == L1ParticleMap::kDoubleJet50_HTT200) {
1057 }
else if (itrig == L1ParticleMap::kDoubleTauJet40_HTT200) {
1070 }
else if (itrig == L1ParticleMap::kDoubleMu3_ETM20) {
1083 }
else if (itrig == L1ParticleMap::kDoubleIsoEG5_ETM20) {
1096 }
else if (itrig == L1ParticleMap::kDoubleEG10_ETM20) {
1109 }
else if (itrig == L1ParticleMap::kDoubleJet50_ETM20) {
1122 }
else if (itrig == L1ParticleMap::kDoubleTauJet40_ETM20) {
1135 }
else if (itrig == L1ParticleMap::kQuadJet30) {
1142 }
else if (itrig == L1ParticleMap::kExclusiveDoubleIsoEG4) {
1154 }
else if (itrig == L1ParticleMap::kExclusiveDoubleJet60) {
1158 if (inputJetRefs.size() == 2) {
1161 }
else if (itrig == L1ParticleMap::kExclusiveJet25_Gap_Jet25) {
1165 if (inputJetRefs.size() == 2) {
1168 }
else if (itrig == L1ParticleMap::kIsoEG10_Jet20_ForJet10) {
1177 inputCenJetTauJetRefs,
1185 }
else if (itrig == L1ParticleMap::kMinBias_HTT10) {
1192 }
else if (itrig == L1ParticleMap::kZeroBias) {
1205 double rand = CLHEP::RandFlat::shoot() * (double)
prescales_[itrig];
1209 outputEmRefs = outputEmRefsTmp;
1210 outputJetRefs = outputJetRefsTmp;
1211 outputMuonRefs = outputMuonRefsTmp;
1229 globalDecision = globalDecision || decision;
1230 decisionWord.push_back(decision);
1238 gtRecord->setDecision(globalDecision);
1239 gtRecord->setDecisionWord(decisionWord);
1245 template <
class TCollection>
1249 for (
size_t i = 0;
i <
handle->size(); ++
i) {
1254 template <
class TCollection>
1256 const double &etThreshold,
1260 for (
size_t i = 0;
i < inputRefs.size(); ++
i) {
1261 if (inputRefs[
i].
get()->et() >= etThreshold) {
1263 outputRefs.push_back(inputRefs[
i]);
1268 template <
class TCollection>
1271 const double &etThreshold,
1275 bool combinedWithGlobalObject)
1279 for (
size_t i = 0;
i + 1 < inputRefs.size(); ++
i) {
1281 if (refi.
get()->et() >= etThreshold) {
1282 for (
size_t j =
i + 1;
j < inputRefs.size(); ++
j) {
1284 if (refj.
get()->et() >= etThreshold) {
1291 for (
size_t iout = 0; iout < outputRefs.size(); ++iout) {
1292 if (refi == outputRefs[iout]) {
1296 if (refj == outputRefs[iout]) {
1304 iInList = outputRefs.size();
1305 outputRefs.push_back(refi);
1309 jInList = outputRefs.size();
1310 outputRefs.push_back(refj);
1315 combo.push_back(iInList);
1316 combo.push_back(jInList);
1317 if (combinedWithGlobalObject)
1319 combos.push_back(combo);
1326 template <
class TCollection>
1329 const double &etThreshold,
1336 for (
size_t i = 0;
i + 2 < inputRefs.size(); ++
i) {
1338 if (refi.
get()->et() >= etThreshold) {
1339 for (
size_t j =
i + 1;
j + 1 < inputRefs.size(); ++
j) {
1341 if (refj.
get()->et() >= etThreshold) {
1342 for (
size_t k =
j + 1;
k < inputRefs.size(); ++
k) {
1344 if (refk.
get()->et() >= etThreshold) {
1352 for (
size_t iout = 0; iout < outputRefs.size(); ++iout) {
1353 if (refi == outputRefs[iout]) {
1357 if (refj == outputRefs[iout]) {
1361 if (refk == outputRefs[iout]) {
1369 iInList = outputRefs.size();
1370 outputRefs.push_back(refi);
1374 jInList = outputRefs.size();
1375 outputRefs.push_back(refj);
1379 kInList = outputRefs.size();
1380 outputRefs.push_back(refk);
1385 combo.push_back(iInList);
1386 combo.push_back(jInList);
1387 combo.push_back(kInList);
1388 combos.push_back(combo);
1397 template <
class TCollection1,
class TCollection2>
1401 const double &etThreshold1,
1402 const double &etThreshold2,
1410 for (
size_t i = 0;
i + 1 < inputRefs1.size(); ++
i) {
1412 if (refi.
get()->et() >= etThreshold1) {
1413 for (
size_t j =
i + 1;
j < inputRefs1.size(); ++
j) {
1415 if (refj.
get()->et() >= etThreshold1) {
1416 for (
size_t k = 0;
k < inputRefs2.size(); ++
k) {
1418 if (refk.
get()->et() >= etThreshold2) {
1426 for (
size_t iout = 0; iout < outputRefs1.size(); ++iout) {
1427 if (refi == outputRefs1[iout]) {
1431 if (refj == outputRefs1[iout]) {
1437 for (
size_t kout = 0; kout < outputRefs2.size(); ++kout) {
1438 if (refk == outputRefs2[kout]) {
1446 iInList = outputRefs1.size();
1447 outputRefs1.push_back(refi);
1451 jInList = outputRefs1.size();
1452 outputRefs1.push_back(refj);
1456 kInList = outputRefs2.size();
1457 outputRefs2.push_back(refk);
1462 combo.push_back(iInList);
1463 combo.push_back(jInList);
1464 combo.push_back(kInList);
1465 combos.push_back(combo);
1474 template <
class TCollection>
1477 const double &etThreshold,
1484 for (
size_t i = 0;
i + 3 < inputRefs.size(); ++
i) {
1486 if (refi.
get()->et() >= etThreshold) {
1487 for (
size_t j =
i + 1;
j + 2 < inputRefs.size(); ++
j) {
1489 if (refj.
get()->et() >= etThreshold) {
1490 for (
size_t k =
j + 1;
k + 1 < inputRefs.size(); ++
k) {
1492 if (refk.
get()->et() >= etThreshold) {
1493 for (
size_t p =
k + 1;
p < inputRefs.size(); ++
p) {
1495 if (refp.
get()->et() >= etThreshold) {
1504 for (
size_t iout = 0; iout < outputRefs.size(); ++iout) {
1505 if (refi == outputRefs[iout]) {
1509 if (refj == outputRefs[iout]) {
1513 if (refk == outputRefs[iout]) {
1517 if (refp == outputRefs[iout]) {
1525 iInList = outputRefs.size();
1526 outputRefs.push_back(refi);
1530 jInList = outputRefs.size();
1531 outputRefs.push_back(refj);
1535 kInList = outputRefs.size();
1536 outputRefs.push_back(refk);
1540 pInList = outputRefs.size();
1541 outputRefs.push_back(refp);
1546 combo.push_back(iInList);
1547 combo.push_back(jInList);
1548 combo.push_back(kInList);
1549 combo.push_back(pInList);
1550 combos.push_back(combo);
1561 template <
class TCollection1,
class TCollection2>
1565 const double &etThreshold1,
1566 const double &etThreshold2,
1572 for (
size_t i = 0;
i < inputRefs1.size(); ++
i) {
1574 if (refi.
get()->et() >= etThreshold1) {
1575 for (
size_t j = 0;
j < inputRefs2.size(); ++
j) {
1578 if (refj.
get()->et() >= etThreshold2) {
1584 for (
size_t iout = 0; iout < outputRefs1.size(); ++iout) {
1585 if (refi == outputRefs1[iout]) {
1591 for (
size_t jout = 0; jout < outputRefs2.size(); ++jout) {
1592 if (refj == outputRefs2[jout]) {
1600 iInList = outputRefs1.size();
1601 outputRefs1.push_back(refi);
1605 jInList = outputRefs2.size();
1606 outputRefs2.push_back(refj);
1611 combo.push_back(iInList);
1612 combo.push_back(jInList);
1613 combos.push_back(combo);
1620 template <
class TCollection>
1624 const double &etThreshold1,
1625 const double &etThreshold2,
1630 for (
size_t i = 0;
i < inputRefs1.size(); ++
i) {
1632 if (refi.
get()->et() >= etThreshold1) {
1633 for (
size_t j = 0;
j < inputRefs2.size(); ++
j) {
1636 if (refj.
get()->et() >= etThreshold2 && refi != refj) {
1642 for (
size_t iout = 0; iout < outputRefs.size(); ++iout) {
1643 if (refi == outputRefs[iout]) {
1649 for (
size_t jout = 0; jout < outputRefs.size(); ++jout) {
1650 if (refj == outputRefs[jout]) {
1658 iInList = outputRefs.size();
1659 outputRefs.push_back(refi);
1663 jInList = outputRefs.size();
1664 outputRefs.push_back(refj);
1669 combo.push_back(iInList);
1670 combo.push_back(jInList);
1671 combos.push_back(combo);
1681 const double &etThreshold1,
1682 const double &etThreshold2,
1688 for (
size_t i = 0;
i < inputRefs1.size(); ++
i) {
1690 if (refi.
get()->et() >= etThreshold1) {
1691 for (
size_t j = 0;
j < inputRefs2.size(); ++
j) {
1695 if (refj.
get()->et() >= etThreshold2 &&
1696 (refi.
get()->gctEmCand() ==
nullptr || refj.
get()->gctJetCand() ==
nullptr ||
1697 refi.
get()->gctEmCand()->regionId() != refj.
get()->gctJetCand()->regionId())) {
1703 for (
size_t iout = 0; iout < outputRefs1.size(); ++iout) {
1704 if (refi == outputRefs1[iout]) {
1710 for (
size_t jout = 0; jout < outputRefs2.size(); ++jout) {
1711 if (refj == outputRefs2[jout]) {
1719 iInList = outputRefs1.size();
1720 outputRefs1.push_back(refi);
1724 jInList = outputRefs2.size();
1725 outputRefs2.push_back(refj);
1730 combo.push_back(iInList);
1731 combo.push_back(jInList);
1732 combos.push_back(combo);
1741 const double &etThreshold,
1748 for (
size_t i = 0;
i + 1 < inputRefs.size(); ++
i) {
1750 if (refi.
get()->et() >= etThreshold) {
1751 for (
size_t j =
i + 1;
j < inputRefs.size(); ++
j) {
1753 if ((refj.
get()->et() >= etThreshold) && (((refi.
get()->eta() < 0.) && (refj.
get()->eta() > 0.)) ||
1754 ((refi.
get()->eta() > 0.) && (refj.
get()->eta() < 0.)))) {
1761 for (
size_t iout = 0; iout < outputRefs.size(); ++iout) {
1762 if (refi == outputRefs[iout]) {
1766 if (refj == outputRefs[iout]) {
1774 iInList = outputRefs.size();
1775 outputRefs.push_back(refi);
1779 jInList = outputRefs.size();
1780 outputRefs.push_back(refj);
1785 combo.push_back(iInList);
1786 combo.push_back(jInList);
1787 combos.push_back(combo);
1796 const double &etThreshold,
1802 for (
size_t k = 0;
k + 1 < inputRefs.size(); ++
k) {
1804 double etak = refk.
get()->eta();
1806 for (
size_t l =
k + 1;
l < inputRefs.size(); ++
l) {
1808 double etal =
refl.get()->eta();
1810 ((etak > 0 && etal < 0) || (etak < 0 && etal > 0))) {
1821 const double &etThreshold1,
1822 const double &etThreshold2,
1827 if (inputRefs1.size() == 2) {
1829 if (!inputRefs2.empty()) {
1830 for (
size_t j = 0;
j < inputRefs2.size(); ++
j) {
1831 if (inputRefs2[
j].
get()->gctJetCand()->regionId() == inputRefs1[0].get()->gctEmCand()->regionId())
1833 if (inputRefs2[
j].
get()->gctJetCand()->regionId() == inputRefs1[1].get()->gctEmCand()->regionId())
1835 if (inputRefs2[
j].
get()->et() > etThreshold2) {