Opened 9 years ago
Closed 9 years ago
#878 closed How to (fixed)
Can I merge two different types of arrays?
Reported by: | drakemarquis | Owned by: | |
---|---|---|---|
Priority: | major | Milestone: | |
Component: | Delphes code | Version: | Delphes 3 |
Keywords: | Cc: |
Description
I would like to apply certain isolation conditions for photons. Those photons should satisfy the following condition: at ECAL, the scalar sum of transverse energy is calculated in a cone of DeltaRMax=0.4 around the candidate photon direction, and this sum should be less than 4.2 GeV.
So I modified cards/delphes_card_CMS.tcl so that some modules were taken away. I added several modules. The modules kept and added are
ChargedHadronTrackingEfficiency
ElectronTrackingEfficiency
MuonTrackingEfficiency
ChargedHadronMomentumSmearing
ElectronMomentumSmearing
MuonMomentumSmearing
TrackMerger
Calorimeter
NeutralPionFilter
ElectronFilter
ECALPhotonElectronPi
PhotonIsolationECAL
in which NeutralPionFilter, ElectronFilter, ECALPhotonElectronPi and PhotonIsolationECAL are the newly added. The detailed definitions are in the attached file delphes_card_CMS_modify.tcl. But this card causes Delphes to issue an error saying "can't access input list 'ECALPhotonElectronPi/ecalPhotonElectronPi' in module 'PhotonIsolationECAL'".
I do not know how to fix it. But I modified a little bit more. I replaced NeutralPionFilter, ElectronFilter and ECALPhotonElectronPi with ECALParticles and PhotonIsolationECAL is modified accordingly. See delphes_card_CMS_modify_v2.tcl. This card does not fulfill my isolation requirement, but it works.
Now, I am confused. In the first version, I basically first take pi0 and electrons from Calorimeter/eflowTracks and Calorimeter/eflowNeutralHadrons in modules NeutralPionFilter and ElectronFilter, so they are of the same type of data. Then I merge them with Calorimeter/eflowPhotons. All of them are the same type. There should not be any problem. In the second version, I only use ECALParticles which is a merger, and the card works. Is it because I used two filters before one merger? I need your help! Thank you!
Attachments (2)
Change History (3)
by , 9 years ago
Attachment: | delphes_card_CMS_modify.tcl added |
---|
by , 9 years ago
Attachment: | delphes_card_CMS_modify_v2.tcl added |
---|
comment:1 by , 9 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |