ATLAS Offline Software
Public Member Functions | Private Attributes | List of all members
LVL1::JetInputProvider Class Reference

#include <JetInputProvider.h>

Inheritance diagram for LVL1::JetInputProvider:
Collaboration diagram for LVL1::JetInputProvider:

Public Member Functions

 JetInputProvider (const std::string &type, const std::string &name, const IInterface *parent)
 
virtual ~JetInputProvider ()
 
virtual StatusCode initialize ()
 
virtual StatusCode fillTopoInputEvent (TCS::TopoInputEvent &) const
 

Private Attributes

ToolHandle< GenericMonitoringToolm_monTool {this, "MonTool", "", "Monitoring tool to create online histograms"}
 
SG::ReadHandleKey< DataVector< JetCMXTopoData > > m_jetLocation
 Jet ROIs SG key. More...
 

Detailed Description

Definition at line 16 of file JetInputProvider.h.

Constructor & Destructor Documentation

◆ JetInputProvider()

JetInputProvider::JetInputProvider ( const std::string &  type,
const std::string &  name,
const IInterface *  parent 
)

Definition at line 15 of file JetInputProvider.cxx.

16  :
17  base_class(type, name, parent),
19 {
20  declareInterface<LVL1::IInputTOBConverter>( this );
21  declareProperty( "JetROILocation", m_jetLocation, "Storegate key for the Jet ROIs" );
22 }

◆ ~JetInputProvider()

JetInputProvider::~JetInputProvider ( )
virtual

Definition at line 24 of file JetInputProvider.cxx.

25 {}

Member Function Documentation

◆ fillTopoInputEvent()

StatusCode JetInputProvider::fillTopoInputEvent ( TCS::TopoInputEvent inputEvent) const
virtual

Definition at line 38 of file JetInputProvider.cxx.

38  {
39  // https://indico.cern.ch/conferenceDisplay.py?confId=284687
40 
41 
42 
44 
45  if(!jettobdata.isValid()){
46  ATH_MSG_WARNING("No DataVector<JetCMXTopoData> with SG key '" << m_jetLocation.key() << "' found in the event. No JET input for the L1Topo simulation.");
47  return StatusCode::RECOVERABLE;
48  }
49 
50 
51  ATH_MSG_DEBUG("Filling the input event. Number of jet topo data objects: " << jettobdata->size());
52  for(const JetCMXTopoData * topoData : * jettobdata) {
53 
54  // fill the vector of TOBs
55  std::vector< JetTopoTOB > tobs;
56  topoData->tobs(tobs);
57 
58  ATH_MSG_DEBUG("Jet topo data object has # TOBs: " << tobs.size());
59  for(const JetTopoTOB & tob: tobs) {
60 
61  ATH_MSG_DEBUG( "JET TOB with : et large = " << setw(4) << tob.etLarge() << ", et small " << tob.etSmall()
62  << ", eta = " << setw(2) << tob.eta() << ", phi = " << tob.phi()
63  << ", ieta = " << setw(2) << tob.ieta() << ", iphi = " << tob.iphi()
64  << ", word = " << hex << tob.roiWord() << dec
65  );
66 
67  TCS::JetTOB jet( tob.etLarge(), tob.etSmall(), tob.ieta(), tob.iphi(), tob.roiWord() );
68  jet.setEtaDouble( tob.eta() );
69  jet.setPhiDouble( tob.phi() );
70  inputEvent.addJet( jet );
71  auto mon_hPt1 = Monitored::Scalar("TOBPt1", jet.Et1());
72  auto mon_hPt2 = Monitored::Scalar("TOBPt2", jet.Et2());
73  auto mon_hPhi = Monitored::Scalar("TOBPhi", jet.phi());
74  auto mon_hEta = Monitored::Scalar("TOBEta", jet.eta());
75  Monitored::Group(m_monTool, mon_hPt1, mon_hPt2, mon_hPhi, mon_hEta);
76  }
77  if(topoData->overflow()){
78  inputEvent.setOverflowFromJetInput(true);
79  ATH_MSG_DEBUG("setOverflowFromJetInput : true");
80  }
81  }
82  return StatusCode::SUCCESS;
83 }

◆ initialize()

StatusCode JetInputProvider::initialize ( )
virtual

Definition at line 28 of file JetInputProvider.cxx.

28  {
29 
30  CHECK(m_jetLocation.initialize());
31 
32  if (!m_monTool.empty()) ATH_CHECK(m_monTool.retrieve());
33 
34  return StatusCode::SUCCESS;
35 }

Member Data Documentation

◆ m_jetLocation

SG::ReadHandleKey< DataVector<JetCMXTopoData> > LVL1::JetInputProvider::m_jetLocation
private

Jet ROIs SG key.

Definition at line 31 of file JetInputProvider.h.

◆ m_monTool

ToolHandle<GenericMonitoringTool> LVL1::JetInputProvider::m_monTool {this, "MonTool", "", "Monitoring tool to create online histograms"}
private

Definition at line 29 of file JetInputProvider.h.


The documentation for this class was generated from the following files:
TrigDefs::Group
Group
Properties of a chain group.
Definition: GroupProperties.h:13
SG::ReadHandle
Definition: StoreGate/StoreGate/ReadHandle.h:70
LVL1::JetInputProvider::m_jetLocation
SG::ReadHandleKey< DataVector< JetCMXTopoData > > m_jetLocation
Jet ROIs SG key.
Definition: JetInputProvider.h:31
LVL1::JetInputProvider::m_monTool
ToolHandle< GenericMonitoringTool > m_monTool
Definition: JetInputProvider.h:29
jet
Definition: JetCalibTools_PlotJESFactors.cxx:23
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
LVL1::JetTopoTOB
Jet TOB data for L1Topo.
Definition: JetTopoTOB.h:19
test_pyathena.parent
parent
Definition: test_pyathena.py:15
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
CHECK
#define CHECK(...)
Evaluate an expression and check for errors.
Definition: Control/AthenaKernel/AthenaKernel/errorcheck.h:422
TrigConf::name
Definition: HLTChainList.h:35
LVL1::TrigT1CaloDefs::JetTopoTobLocation
static const std::string JetTopoTobLocation
Definition: TrigT1CaloDefs.h:87
LVL1::JetCMXTopoData
Definition: JetCMXTopoData.h:22
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
TCS::JetTOB
Definition: JetTOB.h:18
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
TCS::TopoInputEvent::addJet
StatusCode addJet(const JetTOB &jet)
Definition: TopoInputEvent.cxx:82
Monitored::Scalar
Declare a monitored scalar variable.
Definition: MonitoredScalar.h:34
TCS::TopoInputEvent::setOverflowFromJetInput
void setOverflowFromJetInput(bool v)
Definition: TopoInputEvent.cxx:228