Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:07:07

0001 from __future__ import print_function
0002 import FWCore.ParameterSet.Config as cms                                                
0003 
0004 def customise_for_slice_test(process, enableDigis, enableTPs):
0005 
0006     print("[customise_for_slice_test]: cloning unpacker and DTDigiTask + customising AB7 sequence and TP monitoring")
0007 
0008     # Firstly, increase the cut on # of digis/chamber
0009     # to consider it noisy for the legacy DTDigiTask
0010 
0011     process.dtDigiMonitor.maxTDCHitsPerChamber = 5000
0012 
0013     # This is commented out as the AB7 unpacker is not in CMSSW
0014     # at present, the following lines need to be uncommented in the P5 setup
0015 
0016     # from EventFilter.DTRawToDigi.dtab7unpacker_cfi import dtAB7unpacker
0017     # process.dtAB7Unpacker = dtAB7unpacker.clone()
0018 
0019     # Here using the uROS unpacker as proxy, the following lines
0020     # need to be commented out in the setup running @ P5
0021 
0022     from EventFilter.DTRawToDigi.dturosunpacker_cfi import dturosunpacker
0023     process.dtAB7Unpacker = dturosunpacker.clone()
0024 
0025     if hasattr(process,"dtDQMTask"):
0026         print("[customise_for_slice_test]: extending dtDQMTask sequence to include AB7 unpacker")
0027         process.dtDQMTask.replace(process.dtDigiMonitor, process.dtDigiMonitor
0028                                                          + process.dtAB7Unpacker)
0029 
0030     if enableDigis:
0031     
0032         from DQM.DTMonitorModule.dtDigiTask_cfi import dtDigiMonitor
0033         process.dtAB7DigiMonitor = dtDigiMonitor.clone(
0034            dtDigiLabel = "dtAB7Unpacker",
0035            sliceTestMode = True,
0036            maxTDCHitsPerChamber = 5000
0037         )
0038 
0039         process.dtAB7DigiMonitor.performPerWireT0Calibration = False
0040 
0041         if hasattr(process,"dtAB7Unpacker"):
0042             print("[customise_for_slice_test]: extending dtDQMTask sequence to include AB7 digi monitoring")
0043             process.dtDQMTask.replace(process.dtAB7Unpacker, process.dtAB7Unpacker
0044                                                              + process.dtAB7DigiMonitor)
0045 
0046     if enableTPs:
0047 
0048         print("[customise_for_slice_test]: customise dtTriggerBaseMonitor to include AB7 TP monitoring")
0049         process.dtTriggerBaseMonitor.processAB7 = True
0050 
0051     return process