diff --git a/L1Trigger/CSCTriggerPrimitives/interface/CSCAnodeLCTProcessor.h b/L1Trigger/CSCTriggerPrimitives/interface/CSCAnodeLCTProcessor.h index e98b9dda21e09..994a05f3136d8 100644 --- a/L1Trigger/CSCTriggerPrimitives/interface/CSCAnodeLCTProcessor.h +++ b/L1Trigger/CSCTriggerPrimitives/interface/CSCAnodeLCTProcessor.h @@ -222,14 +222,25 @@ class CSCAnodeLCTProcessor : public CSCBaseboard { // set the wire hit container void setWireContainer(CSCALCTDigi&, CSCALCTDigi::WireContainer& wireHits) const; - /* This function looks for LCTs on the previous and next wires. If one + /* This function looks for ALCTs on the previous and next wires. If one exists and it has a better quality and a bx_time up to 4 clocks earlier - than the present, then the present LCT is cancelled. The present LCT + than the present, then the present ALCT is cancelled. The present ALCT also gets cancelled if it has the same quality as the one on the previous wire (this has not been done in 2003 test beam). The cancellation is done separately for collision and accelerator patterns. */ virtual void ghostCancellationLogic(); + /* In older versions of the ALCT emulation, the ghost cancellation was performed after + the ALCTs were found. In December 2018 it became clear that during the study of data + and emulation comparison on 2018 data, a small disagreement between data and emulation + was found. The changes we implemented then allow re-triggering on one wiregroup after + some dead time once an earlier ALCT was constructed built on this wiregroup. Before this + commit the ALCT processor would prohibit the wiregroup from triggering in one event after + an ALCT was found on that wiregroup. In the firwmare, the wiregroup with ALCT is only dead + for a few BX before it can be triggered by next muon. The implementation of ghost cancellation + logic wqas changed to accommodate the re-triggering change while the idea of the ghost + cancellation logic is kept the same. + */ virtual void ghostCancellationLogicOneWire(const int key_wire, int* ghost_cleared); virtual int getTempALCTQuality(int temp_quality) const; diff --git a/L1Trigger/CSCTriggerPrimitives/interface/CSCUpgradeAnodeLCTProcessor.h b/L1Trigger/CSCTriggerPrimitives/interface/CSCUpgradeAnodeLCTProcessor.h index 3156066e2cae8..6e980b05c3a01 100644 --- a/L1Trigger/CSCTriggerPrimitives/interface/CSCUpgradeAnodeLCTProcessor.h +++ b/L1Trigger/CSCTriggerPrimitives/interface/CSCUpgradeAnodeLCTProcessor.h @@ -23,8 +23,8 @@ class CSCUpgradeAnodeLCTProcessor : public CSCAnodeLCTProcessor { unsigned chamber, const edm::ParameterSet& conf); - /** Default constructor. Used for testing. */ - CSCUpgradeAnodeLCTProcessor(); + /** Default destructor. */ + ~CSCUpgradeAnodeLCTProcessor() override{}; private: /* This function looks for LCTs on the previous and next wires. If one diff --git a/L1Trigger/CSCTriggerPrimitives/python/params/alctParams.py b/L1Trigger/CSCTriggerPrimitives/python/params/alctParams.py index f6902035d2e66..0cce4044fc6cf 100644 --- a/L1Trigger/CSCTriggerPrimitives/python/params/alctParams.py +++ b/L1Trigger/CSCTriggerPrimitives/python/params/alctParams.py @@ -51,7 +51,7 @@ ) alctPhase2GEM = alctPhase2.clone( - alctNplanesHitPattern = 3 + alctNplanesHitPattern = 4 ) alctPSets = cms.PSet( diff --git a/L1Trigger/CSCTriggerPrimitives/src/CSCAnodeLCTProcessor.cc b/L1Trigger/CSCTriggerPrimitives/src/CSCAnodeLCTProcessor.cc index 0412b5fee0ecb..96c074ab8f3a0 100644 --- a/L1Trigger/CSCTriggerPrimitives/src/CSCAnodeLCTProcessor.cc +++ b/L1Trigger/CSCTriggerPrimitives/src/CSCAnodeLCTProcessor.cc @@ -297,6 +297,18 @@ void CSCAnodeLCTProcessor::run(const std::vector wire[CSCConstants::NUM_LAY if (patternDetection(i_wire, hits_in_patterns)) { trigger = true; int ghost_cleared[2] = {0, 0}; + /* + In older versions of the ALCT emulation, the ghost cancellation was performed after + the ALCTs were found. In December 2018 it became clear that during the study of data + and emulation comparison on 2018 data, a small disagreement between data and emulation + was found. The changes we implemented then allow re-triggering on one wiregroup after + some dead time once an earlier ALCT was constructed built on this wiregroup. Before this + commit the ALCT processor would prohibit the wiregroup from triggering in one event after + an ALCT was found on that wiregroup. In the firwmare, the wiregroup with ALCT is only dead + for a few BX before it can be triggered by next muon. The implementation of ghost cancellation + logic was changed to accommodate the re-triggering change while the idea of ghost cancellation + logic is kept the same. + */ ghostCancellationLogicOneWire(i_wire, ghost_cleared); int bx = (use_corrected_bx) ? first_bx_corrected[i_wire] : first_bx[i_wire]; @@ -349,6 +361,12 @@ void CSCAnodeLCTProcessor::run(const std::vector wire[CSCConstants::NUM_LAY // Do the rest only if there is at least one trigger candidate. if (trigger) { + /* In Run-1 and Run-2, the ghost cancellation was done after the trigger. + In the firmware however, the ghost cancellation is done during the trigger + on each wiregroup in parallel. For Run-3 and beyond, the ghost cancellation is + implemented per wiregroup earlier in the code. See function + "ghostCancellationLogicOneWire". Therefore, the line below is commented out. + */ //ghostCancellationLogic(); lctSearch(); } diff --git a/L1Trigger/CSCTriggerPrimitives/src/CSCUpgradeAnodeLCTProcessor.cc b/L1Trigger/CSCTriggerPrimitives/src/CSCUpgradeAnodeLCTProcessor.cc index 049ec45cbb3db..42ab9a7bb41bd 100644 --- a/L1Trigger/CSCTriggerPrimitives/src/CSCUpgradeAnodeLCTProcessor.cc +++ b/L1Trigger/CSCTriggerPrimitives/src/CSCUpgradeAnodeLCTProcessor.cc @@ -184,9 +184,9 @@ int CSCUpgradeAnodeLCTProcessor::getTempALCTQuality(int temp_quality) const { // Quality definition changed on 22 June 2007: it no longer depends // on pattern_thresh. int Q; - // hack to run the Phase-II ME2/1, ME3/1 and ME4/1 ILT + // hack to run the Phase-II GE2/1-ME2/1 with 3-layer ALCTs if (temp_quality == 3 and runPhase2_ and runME21ILT_ and isME21_) - Q = 4; + Q = 1; else if (temp_quality > 3) Q = temp_quality - 3; else