Description: Creates 3x3 PF clusters from GCTintTowers to be sent to correlator. Follows firmware logic, creates 8 clusters per (2+17+2)x(2+4+2).
Implementation: To be run together with Phase2L1CaloEGammaEmulator.
Definition at line 48 of file Phase2L1CaloPFClusterEmulator.cc.
Definition at line 75 of file Phase2L1CaloPFClusterEmulator.cc.
References caloTowerToken_, gctpf::GCTpfcluster_t::et, gctpf::GCTpfcluster_t::eta, gctpf::PFcluster_t::GCTpfclusters, mps_fire::i, hcalRecHitTable_cff::ieta, iEvent, hcalRecHitTable_cff::iphi, edm::HandleBase::isValid(), dqmdumpme::k, eostools::move(), nPFClusterSLR, nSLR, nTowerEta, nTowerEtaSLR, nTowerPhi, nTowerPhiSLR, gctpf::pfcluster(), gctpf::GCTpfcluster_t::phi, l1tp2::CaloPFCluster::setClusterEt(), l1tp2::CaloPFCluster::setClusterEta(), l1tp2::CaloPFCluster::setClusterIEta(), l1tp2::CaloPFCluster::setClusterIPhi(), and l1tp2::CaloPFCluster::setClusterPhi().
77 std::unique_ptr<l1tp2::CaloPFClusterCollection> pfclusterCands(make_unique<l1tp2::CaloPFClusterCollection>());
81 if (!caloTowerCollection.
isValid())
82 cms::Exception(
"Phase2L1CaloPFClusterEmulator") <<
"Failed to get towers from caloTowerCollection!";
88 int ieta =
i.towerIEta();
89 int iphi =
i.towerIPhi();
90 GCTintTowers[
ieta][
iphi] =
i.ecalTowerEt();
99 for (
int k = 0;
k <
nSLR;
k++) {
112 for (
int k = 1;
k < 17;
k++) {
121 for (
int k = 1;
k < 17;
k++) {
135 for (
int k = 0;
k <
nSLR;
k++) {
145 if (
k > 1 &&
k % 2 == 0)
146 phioffset = phioffset + 4;
154 float towereta = realEta[gcteta][gctphi];
155 float towerphi = realPhi[gcteta][gctphi];
162 pfclusterCands->push_back(l1CaloPFCluster);
void setClusterEta(float clusterEtaIn)
const edm::EDGetTokenT< l1tp2::CaloTowerCollection > caloTowerToken_
static constexpr int nPFClusterSLR
void setClusterIPhi(int clusterIPhiIn)
static constexpr int nSLR
GCTpfcluster_t GCTpfclusters[nPFClusterSLR]
static constexpr int nTowerEtaSLR
static constexpr int nTowerEta
PFcluster_t pfcluster(float temporary[nTowerEtaSLR][nTowerPhiSLR], int etaoffset, int phioffset)
static constexpr int nTowerPhiSLR
static constexpr int nTowerPhi
void setClusterPhi(float clusterPhiIn)
void setClusterIEta(int clusterIEtaIn)
void setClusterEt(float clusterEtIn)