CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Stage2MainProcessorImp1.cc
Go to the documentation of this file.
1 
21 
23 
24 using namespace std;
25 
27  m_params(params)
28 {
29 
32  Stage2Layer2ClusterAlgorithmFirmwareImp1::ClusterInput::E);
35  Stage2Layer2ClusterAlgorithmFirmwareImp1::ClusterInput::EH);
40 
45 
46 }
47 
49 {
50 
51 };
52 
53 
54 //need to switch to BXVector
55 void l1t::Stage2MainProcessorFirmwareImp1::processEvent(const std::vector<l1t::CaloTower> & inTowers,
56  std::vector<l1t::CaloTower> & outTowers,
57  std::vector<l1t::CaloCluster> & clusters,
58  std::vector<l1t::EGamma> & mpEGammas,
59  std::vector<l1t::Tau> & mpTaus,
60  std::vector<l1t::Jet> & mpJets,
61  std::vector<l1t::EtSum> & mpSums,
62  std::vector<l1t::EGamma> & egammas,
63  std::vector<l1t::Tau> & taus,
64  std::vector<l1t::Jet> & jets,
65  std::vector<l1t::EtSum> & etSums) {
66 
67  // processing below is performed by the MP
68  std::vector<l1t::CaloCluster> egClusters;
69  std::vector<l1t::CaloCluster> tauClusters;
70  std::vector<l1t::Jet> mpAllJets;
71  std::vector<l1t::EtSum> towerSums;
72  std::vector<l1t::EtSum> jetSums;
73 
74  m_towerAlgo->processEvent( inTowers, outTowers );
75  m_egClusterAlgo->processEvent( outTowers, egClusters );
76  m_egAlgo->processEvent( egClusters, outTowers, mpEGammas );
77  m_tauClusterAlgo->processEvent( outTowers, tauClusters );
78  m_tauAlgo->processEvent( tauClusters,outTowers, mpTaus );
79  m_jetAlgo->processEvent( outTowers, mpJets, mpAllJets );
80  m_sumAlgo->processEvent( outTowers, towerSums );
81  m_jetSumAlgo->processEvent( mpAllJets, jetSums );
82 
83  clusters.insert( clusters.end(), egClusters.begin(), egClusters.end() );
84 
85  mpSums.insert( mpSums.end(), towerSums.begin(), towerSums.end() );
86  mpSums.insert( mpSums.end(), jetSums.begin(), jetSums.end() );
87 
88 
89  // processing below is actually performed by the Demux card
90  // in principle this could be done in a separate EDProduce
91  // but it is done here for flexibility
92 
93  m_demuxEGAlgo->processEvent( mpEGammas, egammas );
94  m_demuxTauAlgo->processEvent( mpTaus, taus );
95  m_demuxJetAlgo->processEvent( mpJets, jets );
96  m_demuxSumsAlgo->processEvent( mpSums, etSums );
97 
98 }
99 
100 
102 
103  out << "Calo Stage 2 Main Processor" << std::endl;
104  out << " Tower algo : " << (m_towerAlgo?1:0) << std::endl;
105  out << " EG cluster algo : " << (m_egClusterAlgo?1:0) << std::endl;
106  out << " EG ID algo : " << (m_egAlgo?1:0) << std::endl;
107  out << " Tau cluster algo : " << (m_tauClusterAlgo?1:0) << std::endl;
108  out << " Tau ID algo : " << (m_tauAlgo?1:0) << std::endl;
109  out << " Jet algo : " << (m_jetAlgo?1:0) << std::endl;
110  out << " Jet sum algo : " << (m_jetSumAlgo?1:0) << std::endl;
111  out << " Sums algo : " << (m_sumAlgo?1:0) << std::endl;
112 
113 }
Stage2Layer2ClusterAlgorithm * m_tauClusterAlgo
Stage2MainProcessorFirmwareImp1(unsigned fwv, CaloParamsHelper *params)
vector< PseudoJet > jets
tuple out
Definition: dbtoconf.py:99
Stage2TowerDecompressAlgorithm * m_towerAlgo
Stage2Layer2ClusterAlgorithm * m_egClusterAlgo
virtual void processEvent(const std::vector< l1t::CaloTower > &inTowers, std::vector< l1t::CaloTower > &outTowers, std::vector< l1t::CaloCluster > &clusters, std::vector< l1t::EGamma > &mpEGammas, std::vector< l1t::Tau > &mpTaus, std::vector< l1t::Jet > &mpJets, std::vector< l1t::EtSum > &mpSums, std::vector< l1t::EGamma > &egammas, std::vector< l1t::Tau > &taus, std::vector< l1t::Jet > &jets, std::vector< l1t::EtSum > &etSums)