|
ATLAS Offline Software
|
Go to the documentation of this file.
9 #include "GaudiKernel/SystemOfUnits.h"
12 const std::string&
name,
22 return StatusCode::SUCCESS;
28 ATH_MSG_DEBUG (
"prepareEvent: there are " << nInputEvents <<
" subevents in this event." );
39 return StatusCode::SUCCESS;
48 while (iEvt != eSubEvents) {
51 bunchXing, iEvt).isSuccess()) {
53 if ( !inputJetContainer ) {
55 return StatusCode::FAILURE;
57 ATH_MSG_DEBUG (
"processBunchXing: bunch Crossing = " << bunchXing <<
" JetContainer size = " << inputJetContainer->
size());
67 ATH_MSG_VERBOSE (
"Don't include signal events in output Truth Jet Containers.");
74 ATH_MSG_VERBOSE (
"highest jet pT in the current background event = " << pileup_this_pT);
79 const float timeOfBCID(
static_cast<float>(iEvt->time()));
84 ATH_MSG_DEBUG (
"processBunchXing: No JetContainers found." );
91 return StatusCode::SUCCESS;
102 <<
". Therefore filtering this hard-scatter event." );
113 ATH_CHECK( evtStore()->record( std::move(
117 return StatusCode::SUCCESS;
135 TruthJetList truthList;
137 if (!truthList.empty()) {
139 TruthJetList::const_iterator jetColl_iter(truthList.begin());
140 const TruthJetList::const_iterator endOfJetColls(truthList.end());
141 while (jetColl_iter!=endOfJetColls) {
144 if (
static_cast<int>((jetColl_iter)->
first.time())==0) {
152 ATH_MSG_VERBOSE (
"Don't include signal events in output Truth Jet Containers.");
159 ATH_MSG_VERBOSE (
"highest jet pT in the current background event = " << pileup_this_pT);
164 const float timeOfBCID(
static_cast<float>((jetColl_iter)->
first.time()));
175 ATH_MSG_DEBUG (
"processAllSubEvents: TruthJetList is empty" );
179 ATH_MSG_ERROR (
"processAllSubEvents: Can not find TruthJetList" );
185 <<
". Therefore filtering this hard-scatter event." );
195 ATH_CHECK( evtStore()->record( std::move(
199 return StatusCode::SUCCESS;
208 for (
const xAOD::Jet *origTruthJet : *inputJetContainer) {
210 if (!origTruthJet || origTruthJet->pt()<ptCut) {
211 ATH_MSG_VERBOSE(
"processJetContainer: Jet with pT = " << origTruthJet->pt() <<
" GeV failed ptCut of " << ptCut <<
"GeV." );
214 if (max_pT<origTruthJet->
pt()) max_pT=origTruthJet->pt();
215 ATH_MSG_VERBOSE(
"processJetContainer: Jet with pT = " << origTruthJet->pt() <<
" GeV passed ptCut of " << ptCut <<
"GeV." );
218 ATH_MSG_ERROR (
"Failed to find Truth jet pT for Jet in a BCID at time = " << timeOfBCID );
220 if (!outputJetContainer)
continue;
222 outputJetContainer->
push_back(outputTruthJet);
223 *outputTruthJet = *origTruthJet;
225 timingAccessor(*outputTruthJet) = timeOfBCID + timingAccessor(*origTruthJet);
227 timingAccessor(*outputTruthJet) = timeOfBCID;
230 eventNumberAccessor(*outputTruthJet) =
eventNumber;
Helper class to provide type-safe access to aux data.
#define ATH_MSG_VERBOSE(x)
std::list< value_t > type
type of the collection of timed data object
::StatusCode StatusCode
StatusCode definition for legacy code.
Helpers for checking error return status codes and reporting errors.
value_type push_back(value_type pElem)
Add an element to the end of the collection.
bool isAvailable(const ELT &e) const
Test to see if this variable exists in the store.
size_type size() const noexcept
Returns the number of elements in the collection.
Jet_v1 Jet
Definition of the current "jet version".