43 return StatusCode::SUCCESS;
51 auto trigEventInfoContainer = std::make_unique< xAOD::TrigCompositeContainer>();
52 auto trigEventInfoContainerAux = std::make_unique< xAOD::TrigCompositeAuxContainer>();
54 trigEventInfoContainer->setStore(trigEventInfoContainerAux.get());
58 trigEventInfoContainer->push_back(trigEI);
61 ATH_CHECK(trigEventInfoHandle.
record( std::move( trigEventInfoContainer ),
62 std::move( trigEventInfoContainerAux ) ) );
67 return StatusCode::SUCCESS;
78 double rho=0, rho_EMT = 0;
89 eventShape = rhRhoKey_PF.
cptr();
92 ATH_MSG_WARNING(
"Event density not found in handle, but handle found.");
93 ATH_MSG_FATAL(
"Could not retrieve xAOD::EventShape::Density from xAOD::EventShape.");
94 return StatusCode::FAILURE;
108 for (
unsigned int i_vtx = 0; i_vtx < vertex_container->
size(); i_vtx++)
110 privtx = vertex_container->
at(i_vtx);
124 ATH_MSG_VERBOSE(
"Found event density container HLT_Kt4EMTopoEventShape");
125 eventShape = rhRhoKey_EMT.
cptr();
127 ATH_MSG_WARNING(
"Event density not found in handle, but handle found.");
128 ATH_MSG_FATAL(
"Could not retrieve xAOD::EventShape::Density from xAOD::EventShape.");
129 return StatusCode::FAILURE;
135 ATH_MSG_DEBUG(
"Retrieved Jet Density Rho(EMTopo): " << rho_EMT);
148 return StatusCode::SUCCESS;
#define ATH_CHECK
Evaluate an expression and check for errors.
#define ATH_MSG_VERBOSE(x)
#define ATH_MSG_WARNING(x)
Handle class for reading from StoreGate.
Handle class for adding a decoration to an object.
Handle class for recording to StoreGate.
std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > renounce(T &h)
An algorithm that can be simultaneously executed in multiple threads.
const T * at(size_type n) const
Access an element, as an rvalue.
size_type size() const noexcept
Returns the number of elements in the collection.
virtual bool isValid() override final
Can the handle be successfully dereferenced?
const_pointer_type cptr()
Dereference the pointer.
const_pointer_type get() const
Dereference the pointer, but don't cache anything.
StatusCode record(std::unique_ptr< T > data)
Record a const object to the store.
Gaudi::Property< bool > m_decoratePFlowInfo
SG::ReadHandleKey< xAOD::EventShape > m_rhoKeyPF
SG::WriteDecorHandleKey< xAOD::TrigCompositeContainer > m_rhoDecor
virtual StatusCode initialize() override
ToolHandle< ILumiBlockMuTool > m_lumiBlockMuTool
SG::WriteHandleKey< xAOD::TrigCompositeContainer > m_TrigEventInfoKey
SG::ReadHandleKey< xAOD::VertexContainer > m_PrimaryVxInputName
virtual StatusCode execute(const EventContext &ctx) const override
SG::WriteDecorHandleKey< xAOD::TrigCompositeContainer > m_rhoEMTDecor
SG::WriteDecorHandleKey< xAOD::TrigCompositeContainer > m_muDecor
SG::WriteDecorHandleKey< xAOD::TrigCompositeContainer > m_numPVDecor
Gaudi::Property< bool > m_decorateEMTopoInfo
Gaudi::Property< bool > m_renounceAll
SG::ReadHandleKey< xAOD::EventShape > m_rhoKeyEMT
StatusCode decorateWithEventInfo(const EventContext &ctx, xAOD::TrigComposite *trigEI) const
TrigEventInfoRecorderAlg(const std::string &name, ISvcLocator *pSvcLocator)
bool getDensity(EventDensityID id, double &v) const
Get a density variable from the object.
size_t nTrackParticles() const
Get the number of tracks associated with this vertex.
SG::ReadCondHandle< T > makeHandle(const SG::ReadCondHandleKey< T > &key, const EventContext &ctx=Gaudi::Hive::currentContext())
TrigComposite_v1 TrigComposite
Declare the latest version of the class.
VertexContainer_v1 VertexContainer
Definition of the current "Vertex container version".
Vertex_v1 Vertex
Define the latest version of the vertex class.
EventShape_v1 EventShape
Definition of the current event format version.