CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Types | Public Member Functions | Static Public Attributes | Protected Member Functions | Private Attributes | Friends
L1GctJetLeafCard Class Reference

#include <L1GctJetLeafCard.h>

Inheritance diagram for L1GctJetLeafCard:
L1GctProcessor

Public Types

typedef L1GctTwosComplement
< L1GctInternEtSum::kMissExOrEyNBits
etComponentType
 
typedef L1GctUnsignedInt
< L1GctInternEtSum::kTotEtOrHtNBits
etHadType
 
typedef L1GctUnsignedInt
< L1GctInternEtSum::kTotEtOrHtNBits
etTotalType
 
typedef
L1GctJetFinderBase::hfTowerSumsType 
hfTowerSumsType
 
typedef L1GctTwosComplement
< L1GctInternHtMiss::kMissHxOrHyNBits
htComponentType
 
enum  jetFinderType { tdrJetFinder, hardwareJetFinder, nullJetFinder }
 
enum  maxValues { etTotalMaxValue = L1GctInternEtSum::kTotEtOrHtMaxValue, htTotalMaxValue = L1GctInternEtSum::kTotEtOrHtMaxValue }
 

Public Member Functions

virtual void fetchInput ()
 set the input buffers More...
 
std::vector< etTotalTypegetAllOutputEt () const
 get the Et output history More...
 
std::vector< etComponentTypegetAllOutputEx () const
 
std::vector< etComponentTypegetAllOutputEy () const
 get the Ey output history More...
 
std::vector< hfTowerSumsTypegetAllOutputHfSums () const
 
std::vector< etHadTypegetAllOutputHt () const
 
std::vector< htComponentTypegetAllOutputHx () const
 get the output Ht components history More...
 
std::vector< htComponentTypegetAllOutputHy () const
 
std::vector< L1GctInternEtSumgetInternalEtSums () const
 get the Et sums in internal component format More...
 
std::vector< L1GctInternHtMissgetInternalHtMiss () const
 
L1GctJetFinderBasegetJetFinderA () const
 get pointers to associated jetfinders More...
 
L1GctJetFinderBasegetJetFinderB () const
 
L1GctJetFinderBasegetJetFinderC () const
 
etTotalType getOutputEt () const
 get the Et output More...
 
etComponentType getOutputEx () const
 get the Ex output More...
 
etComponentType getOutputEy () const
 get the Ey output More...
 
hfTowerSumsType getOutputHfSums () const
 
etHadType getOutputHt () const
 
etComponentType getOutputHx () const
 get the output Ht components More...
 
etComponentType getOutputHy () const
 
std::vector< L1GctJetCandgetOutputJetsA () const
 Output jetfinder A jets (lowest jetFinder in phi) More...
 
std::vector< L1GctJetCandgetOutputJetsB () const
 Output jetfinder B jets (middle jetFinder in phi) More...
 
std::vector< L1GctJetCandgetOutputJetsC () const
 Ouptut jetfinder C jets (highest jetFinder in phi) More...
 
 L1GctJetLeafCard (int id, int iphi, jetFinderType jfType=tdrJetFinder)
 
virtual void process ()
 process the data and set outputs More...
 
void reset ()
 clear internal buffers More...
 
void setBxRange (const int firstBx, const int numberOfBx)
 define the bunch crossing range to process More...
 
void setNeighbourLeafCards (std::vector< L1GctJetLeafCard * > neighbours)
 set pointers to neighbours - needed to complete the setup More...
 
void setNextBx (const int bx)
 partially clear buffers More...
 
bool setupOk () const
 Check setup is Ok. More...
 
 ~L1GctJetLeafCard ()
 
- Public Member Functions inherited from L1GctProcessor
 L1GctProcessor ()
 
void reset ()
 complete reset of processor More...
 
void setBxRange (const int firstBx, const int numberOfBx)
 define the bunch crossing range to process More...
 
void setNextBx (const int bxnum)
 clear input data buffers and process a new bunch crossing More...
 
void setTerse ()
 
bool setupOk () const
 Method to check the setup for this processor. Returns true by default. More...
 
void setVerbose ()
 control output messages More...
 
virtual ~L1GctProcessor ()
 

Static Public Attributes

static const int MAX_JET_FINDERS = 3
 Number of jetfinders per jet leaf card. More...
 

Protected Member Functions

virtual void resetPipelines ()
 
virtual void resetProcessor ()
 Separate reset methods for the processor itself and any data stored in pipelines. More...
 
virtual void setupObjects ()
 Initialise inputs with null objects for the correct bunch crossing if required. More...
 
- Protected Member Functions inherited from L1GctProcessor
int bxAbs () const
 
int bxMax () const
 
int bxMin () const
 Support for multiple beam crossing operation. More...
 
int bxRel () const
 
int numOfBx () const
 

Private Attributes

bool m_ctorInputOk
 
etTotalType m_etSum
 
Pipeline< etTotalTypem_etSumPipe
 
etComponentType m_exSum
 
Pipeline< etComponentTypem_exSumPipe
 
etComponentType m_eySum
 
Pipeline< etComponentTypem_eySumPipe
 
hfTowerSumsType m_hfSums
 
Pipeline< hfTowerSumsTypem_hfSumsPipe
 
etHadType m_htSum
 
Pipeline< etHadTypem_htSumPipe
 
htComponentType m_hxSum
 
Pipeline< htComponentTypem_hxSumPipe
 
htComponentType m_hySum
 
Pipeline< htComponentTypem_hySumPipe
 
int m_id
 
L1GctJetFinderBasem_jetFinderA
 lowest jetFinder in phi More...
 
L1GctJetFinderBasem_jetFinderB
 middle jetFinder in phi More...
 
L1GctJetFinderBasem_jetFinderC
 highest jetFinder in phi More...
 
jetFinderType m_whichJetFinder
 
int phiPosition
 

Friends

std::ostream & operator<< (std::ostream &os, const L1GctJetLeafCard &card)
 Overload << operator. More...
 

Additional Inherited Members

- Protected Attributes inherited from L1GctProcessor
bool m_verbose
 Flag to control output messages. More...
 

Detailed Description

Definition at line 28 of file L1GctJetLeafCard.h.

Member Typedef Documentation

Definition at line 41 of file L1GctJetLeafCard.h.

Definition at line 39 of file L1GctJetLeafCard.h.

Definition at line 38 of file L1GctJetLeafCard.h.

Definition at line 44 of file L1GctJetLeafCard.h.

Definition at line 42 of file L1GctJetLeafCard.h.

Member Enumeration Documentation

Constructor & Destructor Documentation

L1GctJetLeafCard::L1GctJetLeafCard ( int  id,
int  iphi,
jetFinderType  jfType = tdrJetFinder 
)

Definition at line 15 of file L1GctJetLeafCard.cc.

References hardwareJetFinder, m_ctorInputOk, m_id, m_jetFinderA, m_jetFinderB, m_jetFinderC, L1GctProcessor::m_verbose, m_whichJetFinder, nullJetFinder, phiPosition, and tdrJetFinder.

15  :
17  m_id(id),
18  m_whichJetFinder(jfType),
19  phiPosition(iphi),
20  m_exSum(0), m_eySum(0),
21  m_hxSum(0), m_hySum(0),
22  m_etSum(0), m_htSum(0),
23  m_hfSums(),
27  m_hfSumsPipe(),
28  m_ctorInputOk(true)
29 {
30  //Check jetLeafCard setup
31  if(m_id < 0 || m_id > 5)
32  {
33  m_ctorInputOk = false;
34  if (m_verbose) {
35  edm::LogWarning("L1GctSetupError")
36  << "L1GctJetLeafCard::L1GctJetLeafCard() : Jet Leaf Card ID " << m_id << " has been incorrectly constructed!\n"
37  << "ID number should be between the range of 0 to 5\n";
38  }
39  }
40 
41  //iphi is redundant
42  if(phiPosition != m_id%3)
43  {
44  m_ctorInputOk = false;
45  if (m_verbose) {
46  edm::LogWarning("L1GctSetupError")
47  << "L1GctJetLeafCard::L1GctJetLeafCard() : Jet Leaf Card ID " << m_id << " has been incorrectly constructed!\n"
48  << "Argument iphi is " << phiPosition << ", should be " << (m_id%3) << " for this ID value \n";
49  }
50  }
51 
52  switch (m_whichJetFinder) {
53  case tdrJetFinder :
54  m_jetFinderA = new L1GctTdrJetFinder( 3*id );
55  m_jetFinderB = new L1GctTdrJetFinder(3*id+1);
56  m_jetFinderC = new L1GctTdrJetFinder(3*id+2);
57  break;
58 
59  case hardwareJetFinder :
63  break;
64 
65  case nullJetFinder :
66  m_jetFinderA = new L1GctNullJetFinder( 3*id );
67  m_jetFinderB = new L1GctNullJetFinder(3*id+1);
68  m_jetFinderC = new L1GctNullJetFinder(3*id+2);
69  break;
70 
71  default :
72 
73  m_ctorInputOk = false;
74  if (m_verbose) {
75  edm::LogWarning("L1GctSetupError")
76  << "L1GctJetLeafCard::L1GctJetLeafCard() : Jet Leaf Card ID " << m_id << " has been incorrectly constructed!\n"
77  << "Unrecognised jetFinder type " << m_whichJetFinder << ", cannot setup jetFinders\n";
78  }
79 
80  }
81 
82  if (!m_ctorInputOk && m_verbose) {
83  edm::LogError("L1GctSetupError") << "Jet Leaf Card ID " << m_id << " has been incorrectly constructed";
84  }
85 }
htComponentType m_hySum
Pipeline< htComponentType > m_hxSumPipe
3*3 sliding window algorithm jet finder.
L1GctJetFinderBase * m_jetFinderB
middle jetFinder in phi
L1GctJetFinderBase * m_jetFinderC
highest jetFinder in phi
bool m_verbose
Flag to control output messages.
Pipeline< etHadType > m_htSumPipe
Pipeline< etTotalType > m_etSumPipe
no-op jet finder for test purposes.
Pipeline< etComponentType > m_eySumPipe
Pipeline< htComponentType > m_hySumPipe
jetFinderType m_whichJetFinder
hfTowerSumsType m_hfSums
L1GctJetFinderBase * m_jetFinderA
lowest jetFinder in phi
Pipeline< hfTowerSumsType > m_hfSumsPipe
etComponentType m_eySum
Emulation of the hardware jet finder.
Pipeline< etComponentType > m_exSumPipe
htComponentType m_hxSum
etComponentType m_exSum
L1GctJetLeafCard::~L1GctJetLeafCard ( )

Definition at line 87 of file L1GctJetLeafCard.cc.

References m_jetFinderA, m_jetFinderB, and m_jetFinderC.

88 {
89  delete m_jetFinderA;
90  delete m_jetFinderB;
91  delete m_jetFinderC;
92 }
L1GctJetFinderBase * m_jetFinderB
middle jetFinder in phi
L1GctJetFinderBase * m_jetFinderC
highest jetFinder in phi
L1GctJetFinderBase * m_jetFinderA
lowest jetFinder in phi

Member Function Documentation

void L1GctJetLeafCard::fetchInput ( )
virtual

set the input buffers

Implements L1GctProcessor.

Definition at line 189 of file L1GctJetLeafCard.cc.

References L1GctJetFinderBase::fetchInput(), m_jetFinderA, m_jetFinderB, and m_jetFinderC.

189  {
193 }
L1GctJetFinderBase * m_jetFinderB
middle jetFinder in phi
L1GctJetFinderBase * m_jetFinderC
highest jetFinder in phi
L1GctJetFinderBase * m_jetFinderA
lowest jetFinder in phi
virtual void fetchInput()=0
get input data from sources; to be filled in by derived jetFinders
std::vector< etTotalType > L1GctJetLeafCard::getAllOutputEt ( ) const
inline

get the Et output history

Definition at line 118 of file L1GctJetLeafCard.h.

References m_etSumPipe.

118 { return m_etSumPipe.contents; }
Pipeline< etTotalType > m_etSumPipe
std::vector< etComponentType > L1GctJetLeafCard::getAllOutputEx ( ) const
inline

Bunch crossing history acces methods get the Ex output history

Definition at line 108 of file L1GctJetLeafCard.h.

References m_exSumPipe.

108 { return m_exSumPipe.contents; }
Pipeline< etComponentType > m_exSumPipe
std::vector< etComponentType > L1GctJetLeafCard::getAllOutputEy ( ) const
inline

get the Ey output history

Definition at line 111 of file L1GctJetLeafCard.h.

References m_eySumPipe.

111 { return m_eySumPipe.contents; }
Pipeline< etComponentType > m_eySumPipe
std::vector< hfTowerSumsType > L1GctJetLeafCard::getAllOutputHfSums ( ) const
inline

Definition at line 121 of file L1GctJetLeafCard.h.

References m_hfSumsPipe.

121 { return m_hfSumsPipe.contents; }
Pipeline< hfTowerSumsType > m_hfSumsPipe
std::vector< etHadType > L1GctJetLeafCard::getAllOutputHt ( ) const
inline

Definition at line 119 of file L1GctJetLeafCard.h.

References m_htSumPipe.

119 { return m_htSumPipe.contents; }
Pipeline< etHadType > m_htSumPipe
std::vector< htComponentType > L1GctJetLeafCard::getAllOutputHx ( ) const
inline

get the output Ht components history

Definition at line 114 of file L1GctJetLeafCard.h.

References m_hxSumPipe.

114 { return m_hxSumPipe.contents; }
Pipeline< htComponentType > m_hxSumPipe
std::vector< htComponentType > L1GctJetLeafCard::getAllOutputHy ( ) const
inline

Definition at line 115 of file L1GctJetLeafCard.h.

References m_hySumPipe.

115 { return m_hySumPipe.contents; }
Pipeline< htComponentType > m_hySumPipe
std::vector< L1GctInternEtSum > L1GctJetLeafCard::getInternalEtSums ( ) const

get the Et sums in internal component format

Definition at line 268 of file L1GctJetLeafCard.cc.

References L1GctProcessor::bxMin(), L1GctInternEtSum::fromEmulatorJetMissEt(), L1GctInternEtSum::fromEmulatorJetTotEt(), L1GctInternEtSum::fromEmulatorJetTotHt(), m_etSumPipe, m_exSumPipe, m_eySumPipe, m_htSumPipe, L1GctProcessor::numOfBx(), and query::result.

269 {
270 
271  std::vector< L1GctInternEtSum > result;
272  for (int bx=0; bx<numOfBx(); bx++) {
273  result.push_back( L1GctInternEtSum::fromEmulatorJetTotEt ( m_etSumPipe.contents.at(bx).value(),
274  m_etSumPipe.contents.at(bx).overFlow(),
275  static_cast<int16_t> (bx-bxMin()) ) );
276  result.push_back( L1GctInternEtSum::fromEmulatorJetMissEt( m_exSumPipe.contents.at(bx).value(),
277  m_exSumPipe.contents.at(bx).overFlow(),
278  static_cast<int16_t> (bx-bxMin()) ) );
279  result.push_back( L1GctInternEtSum::fromEmulatorJetMissEt( m_eySumPipe.contents.at(bx).value(),
280  m_eySumPipe.contents.at(bx).overFlow(),
281  static_cast<int16_t> (bx-bxMin()) ) );
282  result.push_back( L1GctInternEtSum::fromEmulatorJetTotHt ( m_htSumPipe.contents.at(bx).value(),
283  m_htSumPipe.contents.at(bx).overFlow(),
284  static_cast<int16_t> (bx-bxMin()) ) );
285  }
286  return result;
287 }
static L1GctInternEtSum fromEmulatorJetTotEt(unsigned totEt, bool overFlow, int16_t bx)
Emulator constructors.
Pipeline< etHadType > m_htSumPipe
Pipeline< etTotalType > m_etSumPipe
int bxMin() const
Support for multiple beam crossing operation.
int numOfBx() const
static L1GctInternEtSum fromEmulatorJetTotHt(unsigned totHt, bool overFlow, int16_t bx)
Pipeline< etComponentType > m_eySumPipe
tuple result
Definition: query.py:137
Pipeline< etComponentType > m_exSumPipe
static L1GctInternEtSum fromEmulatorJetMissEt(int missEtxOrEty, bool overFlow, int16_t bx)
std::vector< L1GctInternHtMiss > L1GctJetLeafCard::getInternalHtMiss ( ) const

Definition at line 289 of file L1GctJetLeafCard.cc.

References L1GctProcessor::bxMin(), L1GctInternHtMiss::emulatorMissHtxHty(), m_hxSumPipe, m_hySumPipe, L1GctProcessor::numOfBx(), and query::result.

290 {
291 
292  std::vector< L1GctInternHtMiss > result;
293  for (int bx=0; bx<numOfBx(); bx++) {
294  result.push_back( L1GctInternHtMiss::emulatorMissHtxHty( m_hxSumPipe.contents.at(bx).value(),
295  m_hySumPipe.contents.at(bx).value(),
296  m_hxSumPipe.contents.at(bx).overFlow(),
297  static_cast<int16_t> (bx-bxMin()) ) );
298  }
299  return result;
300 
301 }
Pipeline< htComponentType > m_hxSumPipe
int bxMin() const
Support for multiple beam crossing operation.
int numOfBx() const
Pipeline< htComponentType > m_hySumPipe
tuple result
Definition: query.py:137
static L1GctInternHtMiss emulatorMissHtxHty(const int htx, const int hty, const bool overFlow, const int16_t bx)
Named ctor for making missing Ht x &amp; y components object from emulator (wheel input).
L1GctJetFinderBase* L1GctJetLeafCard::getJetFinderA ( ) const
inline

get pointers to associated jetfinders

Definition at line 81 of file L1GctJetLeafCard.h.

References m_jetFinderA.

81 { return m_jetFinderA; }
L1GctJetFinderBase * m_jetFinderA
lowest jetFinder in phi
L1GctJetFinderBase* L1GctJetLeafCard::getJetFinderB ( ) const
inline

Definition at line 82 of file L1GctJetLeafCard.h.

References m_jetFinderB.

82 { return m_jetFinderB; }
L1GctJetFinderBase * m_jetFinderB
middle jetFinder in phi
L1GctJetFinderBase* L1GctJetLeafCard::getJetFinderC ( ) const
inline

Definition at line 83 of file L1GctJetLeafCard.h.

References m_jetFinderC.

83 { return m_jetFinderC; }
L1GctJetFinderBase * m_jetFinderC
highest jetFinder in phi
etTotalType L1GctJetLeafCard::getOutputEt ( ) const
inline

get the Et output

Definition at line 101 of file L1GctJetLeafCard.h.

References m_etSum.

101 { return m_etSum; }
etComponentType L1GctJetLeafCard::getOutputEx ( ) const
inline

get the Ex output

Definition at line 91 of file L1GctJetLeafCard.h.

References m_exSum.

91 { return m_exSum; }
etComponentType m_exSum
etComponentType L1GctJetLeafCard::getOutputEy ( ) const
inline

get the Ey output

Definition at line 94 of file L1GctJetLeafCard.h.

References m_eySum.

94 { return m_eySum; }
etComponentType m_eySum
hfTowerSumsType L1GctJetLeafCard::getOutputHfSums ( ) const
inline

Definition at line 104 of file L1GctJetLeafCard.h.

References m_hfSums.

104 { return m_hfSums; }
hfTowerSumsType m_hfSums
etHadType L1GctJetLeafCard::getOutputHt ( ) const
inline

Definition at line 102 of file L1GctJetLeafCard.h.

References m_htSum.

102 { return m_htSum; }
etComponentType L1GctJetLeafCard::getOutputHx ( ) const
inline

get the output Ht components

Definition at line 97 of file L1GctJetLeafCard.h.

References m_hxSum.

97 { return m_hxSum; }
htComponentType m_hxSum
etComponentType L1GctJetLeafCard::getOutputHy ( ) const
inline

Definition at line 98 of file L1GctJetLeafCard.h.

References m_hySum.

98 { return m_hySum; }
htComponentType m_hySum
L1GctJetFinderBase::JetVector L1GctJetLeafCard::getOutputJetsA ( ) const

Output jetfinder A jets (lowest jetFinder in phi)

Definition at line 261 of file L1GctJetLeafCard.cc.

References L1GctJetFinderBase::getJets(), and m_jetFinderA.

L1GctJetFinderBase::JetVector L1GctJetLeafCard::getOutputJetsB ( ) const

Output jetfinder B jets (middle jetFinder in phi)

Definition at line 263 of file L1GctJetLeafCard.cc.

References L1GctJetFinderBase::getJets(), and m_jetFinderB.

L1GctJetFinderBase::JetVector L1GctJetLeafCard::getOutputJetsC ( ) const

Ouptut jetfinder C jets (highest jetFinder in phi)

Definition at line 265 of file L1GctJetLeafCard.cc.

References L1GctJetFinderBase::getJets(), and m_jetFinderC.

void L1GctJetLeafCard::process ( )
virtual

process the data and set outputs

Implements L1GctProcessor.

Definition at line 195 of file L1GctJetLeafCard.cc.

References L1GctProcessor::bxRel(), etTotalMaxValue, L1GctJetFinderBase::getEtSum(), L1GctJetFinderBase::getExSum(), L1GctJetFinderBase::getEySum(), L1GctJetFinderBase::getHfSums(), L1GctJetFinderBase::getHtSum(), L1GctJetFinderBase::getHxSum(), L1GctJetFinderBase::getHySum(), htTotalMaxValue, m_etSum, m_etSumPipe, m_exSum, m_exSumPipe, m_eySum, m_eySumPipe, m_hfSums, m_hfSumsPipe, m_htSum, m_htSumPipe, m_hxSum, m_hxSumPipe, m_hySum, m_hySumPipe, m_jetFinderA, m_jetFinderB, m_jetFinderC, L1GctUnsignedInt< nBits >::overFlow(), L1GctJetFinderBase::process(), setupOk(), and L1GctUnsignedInt< nBits >::setValue().

Referenced by ConfigBuilder.ConfigBuilder.PrintAllModules::leave().

195  {
196 
197  // Check the setup
198  if (setupOk()) {
199 
200  // Perform the jet finding
204 
205  // Finish Et and Ht sums for the Leaf Card
206  // First Et and missing Et
207  m_etSum =
212  m_exSum =
216  m_eySum =
220 
221  // Exactly the same procedure for Ht and missing Ht
222  m_htSum =
227  m_hxSum =
231  m_hySum =
235 
236  // And the same again for Hf Sums
237  m_hfSums =
241 
242  // Store the outputs in pipelines
243  m_exSumPipe.store (m_exSum, bxRel());
244  m_eySumPipe.store (m_eySum, bxRel());
245  m_hxSumPipe.store (m_hxSum, bxRel());
246  m_hySumPipe.store (m_hySum, bxRel());
247  m_etSumPipe.store (m_etSum, bxRel());
248  m_htSumPipe.store (m_htSum, bxRel());
249  m_hfSumsPipe.store (m_hfSums, bxRel());
250  }
251 }
htComponentType m_hySum
Pipeline< htComponentType > m_hxSumPipe
L1GctJetFinderBase * m_jetFinderB
middle jetFinder in phi
L1GctJetFinderBase * m_jetFinderC
highest jetFinder in phi
Pipeline< etHadType > m_htSumPipe
Pipeline< etTotalType > m_etSumPipe
etCompInternJfType getEySum() const
Get the y component of vector Et summed over the input regions.
int bxRel() const
etCompInternJfType getExSum() const
Get the x component of vector Et summed over the input regions.
Pipeline< etComponentType > m_eySumPipe
Pipeline< htComponentType > m_hySumPipe
etTotalType getEtSum() const
Get the scalar sum of Et summed over the input regions.
etHadType getHtSum() const
Get the scalar sum of Ht summed over jets above threshold.
virtual void process()=0
process the data, fill output buffers; to be filled in by derived jetFinders
htCompInternJfType getHySum() const
Get the y component of vector Ht summed over jets above threshold.
htCompInternJfType getHxSum() const
Get the x component of vector Ht summed over jets above threshold.
hfTowerSumsType m_hfSums
hfTowerSumsType getHfSums() const
Get the Hf tower Et sums and tower-over-threshold counts.
L1GctTwosComplement< L1GctInternHtMiss::kMissHxOrHyNBits > htComponentType
L1GctJetFinderBase * m_jetFinderA
lowest jetFinder in phi
void setValue(unsigned value)
Set value from unsigned.
Pipeline< hfTowerSumsType > m_hfSumsPipe
etComponentType m_eySum
bool setupOk() const
Check setup is Ok.
Pipeline< etComponentType > m_exSumPipe
L1GctTwosComplement< L1GctInternEtSum::kMissExOrEyNBits > etComponentType
bool overFlow() const
access overflow
htComponentType m_hxSum
etComponentType m_exSum
void L1GctJetLeafCard::reset ( void  )

clear internal buffers

clear buffers

Definition at line 145 of file L1GctJetLeafCard.cc.

References m_jetFinderA, m_jetFinderB, m_jetFinderC, and L1GctProcessor::reset().

145  {
147  m_jetFinderA->reset();
148  m_jetFinderB->reset();
149  m_jetFinderC->reset();
150 }
void reset()
complete reset of processor
L1GctJetFinderBase * m_jetFinderB
middle jetFinder in phi
L1GctJetFinderBase * m_jetFinderC
highest jetFinder in phi
L1GctJetFinderBase * m_jetFinderA
lowest jetFinder in phi
void L1GctJetLeafCard::resetPipelines ( )
protectedvirtual

Implements L1GctProcessor.

Definition at line 178 of file L1GctJetLeafCard.cc.

References m_etSumPipe, m_exSumPipe, m_eySumPipe, m_hfSumsPipe, m_htSumPipe, m_hxSumPipe, m_hySumPipe, and L1GctProcessor::numOfBx().

179 {
180  m_exSumPipe.reset(numOfBx());
181  m_eySumPipe.reset(numOfBx());
182  m_hxSumPipe.reset(numOfBx());
183  m_hySumPipe.reset(numOfBx());
184  m_etSumPipe.reset(numOfBx());
185  m_htSumPipe.reset(numOfBx());
186  m_hfSumsPipe.reset(numOfBx());
187 }
Pipeline< htComponentType > m_hxSumPipe
Pipeline< etHadType > m_htSumPipe
Pipeline< etTotalType > m_etSumPipe
int numOfBx() const
Pipeline< etComponentType > m_eySumPipe
Pipeline< htComponentType > m_hySumPipe
Pipeline< hfTowerSumsType > m_hfSumsPipe
Pipeline< etComponentType > m_exSumPipe
void L1GctJetLeafCard::resetProcessor ( )
protectedvirtual

Separate reset methods for the processor itself and any data stored in pipelines.

Implements L1GctProcessor.

Definition at line 167 of file L1GctJetLeafCard.cc.

References m_etSum, m_exSum, m_eySum, m_hfSums, m_htSum, m_hxSum, m_hySum, L1GctUnsignedInt< nBits >::reset(), L1GctTwosComplement< nBits >::reset(), and L1GctJetFinderBase::hfTowerSumsType::reset().

168 {
169  m_exSum.reset();
170  m_eySum.reset();
171  m_hxSum.reset();
172  m_hySum.reset();
173  m_etSum.reset();
174  m_htSum.reset();
175  m_hfSums.reset();
176 }
htComponentType m_hySum
hfTowerSumsType m_hfSums
void reset()
reset value and overflow to zero
etComponentType m_eySum
void reset()
reset value and overflow to zero
htComponentType m_hxSum
etComponentType m_exSum
void L1GctJetLeafCard::setBxRange ( const int  firstBx,
const int  numberOfBx 
)

define the bunch crossing range to process

partially clear buffers

Definition at line 153 of file L1GctJetLeafCard.cc.

References m_jetFinderA, m_jetFinderB, m_jetFinderC, and L1GctProcessor::setBxRange().

153  {
154  L1GctProcessor::setBxRange(firstBx, numberOfBx);
155  m_jetFinderA->setBxRange(firstBx, numberOfBx);
156  m_jetFinderB->setBxRange(firstBx, numberOfBx);
157  m_jetFinderC->setBxRange(firstBx, numberOfBx);
158 }
L1GctJetFinderBase * m_jetFinderB
middle jetFinder in phi
L1GctJetFinderBase * m_jetFinderC
highest jetFinder in phi
void setBxRange(const int firstBx, const int numberOfBx)
define the bunch crossing range to process
L1GctJetFinderBase * m_jetFinderA
lowest jetFinder in phi
void L1GctJetLeafCard::setNeighbourLeafCards ( std::vector< L1GctJetLeafCard * >  neighbours)

set pointers to neighbours - needed to complete the setup

set pointers to neighbours

Definition at line 95 of file L1GctJetLeafCard.cc.

References m_ctorInputOk, m_id, m_jetFinderA, m_jetFinderB, m_jetFinderC, L1GctProcessor::m_verbose, and L1GctJetFinderBase::setNeighbourJetFinders().

96 {
97  std::vector<L1GctJetFinderBase*> jfNeighbours(2);
98 
99  if (neighbours.size()==2) {
100 
101  jfNeighbours.at(0) = neighbours.at(0)->getJetFinderC();
102  jfNeighbours.at(1) = m_jetFinderB;
103  m_jetFinderA->setNeighbourJetFinders(jfNeighbours);
104 
105  jfNeighbours.at(0) = m_jetFinderA;
106  jfNeighbours.at(1) = m_jetFinderC;
107  m_jetFinderB->setNeighbourJetFinders(jfNeighbours);
108 
109  jfNeighbours.at(0) = m_jetFinderB;
110  jfNeighbours.at(1) = neighbours.at(1)->getJetFinderA();
111  m_jetFinderC->setNeighbourJetFinders(jfNeighbours);
112 
113  } else {
114  m_ctorInputOk = false;
115  if (m_verbose) {
116  edm::LogWarning("L1GctSetupError")
117  << "L1GctJetLeafCard::setNeighbourLeafCards() : In Jet Leaf Card ID " << m_id
118  << " size of input vector should be 2, but is in fact " << neighbours.size() << "\n";
119  }
120  }
121 }
L1GctJetFinderBase * m_jetFinderB
middle jetFinder in phi
L1GctJetFinderBase * m_jetFinderC
highest jetFinder in phi
bool m_verbose
Flag to control output messages.
void setNeighbourJetFinders(std::vector< L1GctJetFinderBase * > neighbours)
Set pointers to neighbours - needed to complete the setup.
L1GctJetFinderBase * m_jetFinderA
lowest jetFinder in phi
void L1GctJetLeafCard::setNextBx ( const int  bx)

partially clear buffers

Definition at line 160 of file L1GctJetLeafCard.cc.

References m_jetFinderA, m_jetFinderB, m_jetFinderC, and L1GctProcessor::setNextBx().

160  {
162  m_jetFinderA->setNextBx(bx);
163  m_jetFinderB->setNextBx(bx);
164  m_jetFinderC->setNextBx(bx);
165 }
L1GctJetFinderBase * m_jetFinderB
middle jetFinder in phi
L1GctJetFinderBase * m_jetFinderC
highest jetFinder in phi
L1GctJetFinderBase * m_jetFinderA
lowest jetFinder in phi
void setNextBx(const int bxnum)
clear input data buffers and process a new bunch crossing
virtual void L1GctJetLeafCard::setupObjects ( )
inlineprotectedvirtual

Initialise inputs with null objects for the correct bunch crossing if required.

Implements L1GctProcessor.

Definition at line 134 of file L1GctJetLeafCard.h.

134 {}
bool L1GctJetLeafCard::setupOk ( ) const

Check setup is Ok.

Definition at line 253 of file L1GctJetLeafCard.cc.

References m_ctorInputOk, m_jetFinderA, m_jetFinderB, m_jetFinderC, and L1GctJetFinderBase::setupOk().

Referenced by process().

253  {
254  return (m_ctorInputOk &&
255  m_jetFinderA->setupOk() &&
256  m_jetFinderB->setupOk() &&
257  m_jetFinderC->setupOk()); }
L1GctJetFinderBase * m_jetFinderB
middle jetFinder in phi
L1GctJetFinderBase * m_jetFinderC
highest jetFinder in phi
bool setupOk() const
Check setup is Ok.
L1GctJetFinderBase * m_jetFinderA
lowest jetFinder in phi

Friends And Related Function Documentation

std::ostream& operator<< ( std::ostream &  os,
const L1GctJetLeafCard card 
)
friend

Overload << operator.

Definition at line 123 of file L1GctJetLeafCard.cc.

124 {
125  using std::endl;
126 
127  s << "===L1GctJetLeafCard===" << endl;
128  s << "ID = " << card.m_id << endl;
129  s << "i_phi = " << card.phiPosition << endl;;
130  s << "Ex " << card.m_exSum << endl;
131  s << "Ey " << card.m_eySum << endl;
132  s << "Hx " << card.m_hxSum << endl;
133  s << "Hy " << card.m_hySum << endl;
134  s << "Et " << card.m_etSum << endl;
135  s << "Ht " << card.m_htSum << endl;
136  s << "JetFinder A : " << endl << (*card.m_jetFinderA);
137  s << "JetFinder B : " << endl << (*card.m_jetFinderB);
138  s << "JetFinder C : " << endl << (*card.m_jetFinderC);
139  s << endl;
140 
141  return s;
142 }
htComponentType m_hySum
L1GctJetFinderBase * m_jetFinderB
middle jetFinder in phi
L1GctJetFinderBase * m_jetFinderC
highest jetFinder in phi
L1GctJetFinderBase * m_jetFinderA
lowest jetFinder in phi
etComponentType m_eySum
htComponentType m_hxSum
etComponentType m_exSum

Member Data Documentation

bool L1GctJetLeafCard::m_ctorInputOk
private

Definition at line 171 of file L1GctJetLeafCard.h.

Referenced by L1GctJetLeafCard(), setNeighbourLeafCards(), and setupOk().

etTotalType L1GctJetLeafCard::m_etSum
private

Definition at line 157 of file L1GctJetLeafCard.h.

Referenced by getOutputEt(), operator<<(), process(), and resetProcessor().

Pipeline<etTotalType> L1GctJetLeafCard::m_etSumPipe
private

Definition at line 167 of file L1GctJetLeafCard.h.

Referenced by getAllOutputEt(), getInternalEtSums(), process(), and resetPipelines().

etComponentType L1GctJetLeafCard::m_exSum
private

Definition at line 153 of file L1GctJetLeafCard.h.

Referenced by getOutputEx(), operator<<(), process(), and resetProcessor().

Pipeline<etComponentType> L1GctJetLeafCard::m_exSumPipe
private

Definition at line 163 of file L1GctJetLeafCard.h.

Referenced by getAllOutputEx(), getInternalEtSums(), process(), and resetPipelines().

etComponentType L1GctJetLeafCard::m_eySum
private

Definition at line 154 of file L1GctJetLeafCard.h.

Referenced by getOutputEy(), operator<<(), process(), and resetProcessor().

Pipeline<etComponentType> L1GctJetLeafCard::m_eySumPipe
private

Definition at line 164 of file L1GctJetLeafCard.h.

Referenced by getAllOutputEy(), getInternalEtSums(), process(), and resetPipelines().

hfTowerSumsType L1GctJetLeafCard::m_hfSums
private

Definition at line 160 of file L1GctJetLeafCard.h.

Referenced by getOutputHfSums(), process(), and resetProcessor().

Pipeline<hfTowerSumsType> L1GctJetLeafCard::m_hfSumsPipe
private

Definition at line 169 of file L1GctJetLeafCard.h.

Referenced by getAllOutputHfSums(), process(), and resetPipelines().

etHadType L1GctJetLeafCard::m_htSum
private

Definition at line 158 of file L1GctJetLeafCard.h.

Referenced by getOutputHt(), operator<<(), process(), and resetProcessor().

Pipeline<etHadType> L1GctJetLeafCard::m_htSumPipe
private

Definition at line 168 of file L1GctJetLeafCard.h.

Referenced by getAllOutputHt(), getInternalEtSums(), process(), and resetPipelines().

htComponentType L1GctJetLeafCard::m_hxSum
private

Definition at line 155 of file L1GctJetLeafCard.h.

Referenced by getOutputHx(), operator<<(), process(), and resetProcessor().

Pipeline<htComponentType> L1GctJetLeafCard::m_hxSumPipe
private

Definition at line 165 of file L1GctJetLeafCard.h.

Referenced by getAllOutputHx(), getInternalHtMiss(), process(), and resetPipelines().

htComponentType L1GctJetLeafCard::m_hySum
private

Definition at line 156 of file L1GctJetLeafCard.h.

Referenced by getOutputHy(), operator<<(), process(), and resetProcessor().

Pipeline<htComponentType> L1GctJetLeafCard::m_hySumPipe
private

Definition at line 166 of file L1GctJetLeafCard.h.

Referenced by getAllOutputHy(), getInternalHtMiss(), process(), and resetPipelines().

int L1GctJetLeafCard::m_id
private

Definition at line 139 of file L1GctJetLeafCard.h.

Referenced by L1GctJetLeafCard(), operator<<(), and setNeighbourLeafCards().

L1GctJetFinderBase* L1GctJetLeafCard::m_jetFinderA
private
L1GctJetFinderBase* L1GctJetLeafCard::m_jetFinderB
private
L1GctJetFinderBase* L1GctJetLeafCard::m_jetFinderC
private
jetFinderType L1GctJetLeafCard::m_whichJetFinder
private

Definition at line 142 of file L1GctJetLeafCard.h.

Referenced by L1GctJetLeafCard().

const int L1GctJetLeafCard::MAX_JET_FINDERS = 3
static

Number of jetfinders per jet leaf card.

Definition at line 35 of file L1GctJetLeafCard.h.

int L1GctJetLeafCard::phiPosition
private

Definition at line 151 of file L1GctJetLeafCard.h.

Referenced by L1GctJetLeafCard(), and operator<<().