Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Phase 2 GTT Add Extended Jets to buffers for GlobalTrigger #1248

Open
wants to merge 1 commit into
base: phase2-l1t-integration-14_0_0_pre3
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion L1Trigger/DemonstratorTools/plugins/GTTFileWriter.cc
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ class GTTFileWriter : public edm::one::EDAnalyzer<edm::one::SharedResources> {
const edm::EDGetTokenT<TrackRefCollection_t> vertexAssociatedTracksToken_;
const edm::EDGetTokenT<edm::View<l1t::VertexWord>> verticesToken_;
const edm::EDGetTokenT<edm::View<l1t::TkJetWord>> jetsToken_;
const edm::EDGetTokenT<edm::View<l1t::TkJetWord>> jetsDispToken_;
const edm::EDGetTokenT<edm::View<l1t::EtSum>> htMissToken_;
const edm::EDGetTokenT<edm::View<l1t::EtSum>> htMissDispToken_;
const edm::EDGetTokenT<edm::View<l1t::EtSum>> etMissToken_;
Expand Down Expand Up @@ -107,6 +108,7 @@ GTTFileWriter::GTTFileWriter(const edm::ParameterSet& iConfig)
consumes<TrackRefCollection_t>(iConfig.getUntrackedParameter<edm::InputTag>("vertexAssociatedTracks"))),
verticesToken_(consumes<edm::View<l1t::VertexWord>>(iConfig.getUntrackedParameter<edm::InputTag>("vertices"))),
jetsToken_(consumes<edm::View<l1t::TkJetWord>>(iConfig.getUntrackedParameter<edm::InputTag>("jets"))),
jetsDispToken_(consumes<edm::View<l1t::TkJetWord>>(iConfig.getUntrackedParameter<edm::InputTag>("jetsdisp"))),
htMissToken_(consumes<edm::View<l1t::EtSum>>(iConfig.getUntrackedParameter<edm::InputTag>("htmiss"))),
htMissDispToken_(consumes<edm::View<l1t::EtSum>>(iConfig.getUntrackedParameter<edm::InputTag>("htmissdisp"))),
etMissToken_(consumes<edm::View<l1t::EtSum>>(iConfig.getUntrackedParameter<edm::InputTag>("etmiss"))),
Expand Down Expand Up @@ -169,6 +171,7 @@ void GTTFileWriter::analyze(const edm::Event& iEvent, const edm::EventSetup& iSe
const auto& convertedTracksCollection = iEvent.get(convertedTracksToken_);
const auto& verticesCollection = iEvent.get(verticesToken_);
const auto& jetsCollection = iEvent.get(jetsToken_);
const auto& jetsDispCollection = iEvent.get(jetsDispToken_);
const auto& htMissCollection = iEvent.get(htMissToken_);
const auto& htMissDispCollection = iEvent.get(htMissDispToken_);
const auto& etMissCollection = iEvent.get(etMissToken_);
Expand All @@ -187,6 +190,7 @@ void GTTFileWriter::analyze(const edm::Event& iEvent, const edm::EventSetup& iSe
const auto vertexAssociatedTrackData(encodeTracks(convertedTracksHandle, vertexAssociatedTracksHandle));
const auto vertexData(encodeVertices(verticesCollection));
const auto jetsData(encodeTkJets(jetsCollection));
const auto jetsDispData(encodeTkJets(jetsDispCollection));
const auto htMissData(encodeHtSums(htMissCollection));
const auto htMissDispData(encodeHtSums(htMissDispCollection));
const auto etMissData(encodeEtSums(etMissCollection));
Expand All @@ -209,7 +213,7 @@ void GTTFileWriter::analyze(const edm::Event& iEvent, const edm::EventSetup& iSe
// 2b) For the global trigger 'event data' combine different objects into one 'logical' link
std::vector<ap_uint<64>> sumsData;
sumsData.insert(sumsData.end(), jetsData.at(0).begin(), jetsData.at(0).end());
sumsData.insert(sumsData.end(), 24, 0);
sumsData.insert(sumsData.end(), jetsDispData.at(0).begin(), jetsDispData.at(0).end());
sumsData.insert(sumsData.end(), htMissData.at(0).begin(), htMissData.at(0).end());
sumsData.insert(sumsData.end(), htMissDispData.at(0).begin(), htMissDispData.at(0).end());
sumsData.insert(sumsData.end(), etMissData.at(0).begin(), etMissData.at(0).end());
Expand Down Expand Up @@ -258,6 +262,7 @@ void GTTFileWriter::fillDescriptions(edm::ConfigurationDescriptions& description
edm::InputTag("l1tTrackSelectionProducer", "Level1TTTracksSelectedAssociatedEmulation"));
desc.addUntracked<edm::InputTag>("vertices", edm::InputTag("l1tVertexProducer", "L1VerticesEmulation"));
desc.addUntracked<edm::InputTag>("jets", edm::InputTag("l1tTrackJetsEmulation", "L1TrackJets"));
desc.addUntracked<edm::InputTag>("jetsdisp", edm::InputTag("l1tTrackJetsExtendedEmulation", "L1TrackJetsExtended"));
desc.addUntracked<edm::InputTag>("htmiss", edm::InputTag("l1tTrackerEmuHTMiss", "L1TrackerEmuHTMiss"));
desc.addUntracked<edm::InputTag>("htmissdisp",
edm::InputTag("l1tTrackerEmuHTMissExtended", "L1TrackerEmuHTMissExtended"));
Expand Down
1 change: 1 addition & 0 deletions L1Trigger/DemonstratorTools/python/l1tGTTFileWriter_cfi.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
selectedTracks = cms.untracked.InputTag("l1tTrackSelectionProducer", "Level1TTTracksSelectedEmulation"),
vertexAssociatedTracks = cms.untracked.InputTag("l1tTrackSelectionProducer", "Level1TTTracksSelectedAssociatedEmulation"),
jets = cms.untracked.InputTag("l1tTrackJetsEmulation","L1TrackJets"),
jetsdisp = cms.untracked.InputTag("l1tTrackJetsExtendedEmulation","L1TrackJetsExtended"),
htmiss = cms.untracked.InputTag("l1tTrackerEmuHTMiss", "L1TrackerEmuHTMiss"),
htmissdisp = cms.untracked.InputTag("l1tTrackerEmuHTMissExtended", "L1TrackerEmuHTMissExtended"),
etmiss = cms.untracked.InputTag("l1tTrackerEmuEtMiss", "L1TrackerEmuEtMiss"),
Expand Down