|
ATLAS Offline Software
|
Go to the documentation of this file.
35 return StatusCode::SUCCESS;
46 return StatusCode::SUCCESS;
51 std::map<
Identifier, std::vector<const TileTTL1*>> &towerMap)
const
60 std::map<Identifier, std::vector<const TileTTL1*>>
::iterator test = towerMap.find(
id );
62 if (
test != towerMap.end()) {
64 test->second.push_back(tower);
68 std::vector<const TileTTL1*>
towers;
70 towerMap.emplace(
id,
towers);
83 const std::string &
label)
const
86 std::map<Identifier, std::vector<const TileTTL1*>> towerMap;
91 ATH_MSG_ERROR(
"Could not get background " <<
label <<
" TileTTL1Container container " << bkgTowers.
name() <<
" from store " << bkgTowers.
store());
92 return StatusCode::FAILURE;
99 ATH_MSG_ERROR(
"Could not get signal " <<
label <<
" TileTTL1Container container " << signalTowers.
name() <<
" from store " << signalTowers.
store());
100 return StatusCode::FAILURE;
109 ATH_CHECK( outputContainer.
record(std::make_unique<TileTTL1Container>()) );
116 std::vector<float> mergedAmps;
118 if (mergedAmps.empty()) {
119 mergedAmps = tower->fsamples();
121 std::vector<float> amps = tower->fsamples();
122 if (amps.size() != mergedAmps.size()) {
123 ATH_MSG_WARNING(
"Tile " <<
label <<
" vectors have different lengths: " << amps.size() <<
", " << mergedAmps.size());
125 for (
size_t i = 0;
i < amps.size(); ++
i) {
126 mergedAmps[
i] += amps[
i];
133 std::unique_ptr<TileTTL1> ttL1 = std::make_unique<TileTTL1>(Id, mergedAmps);
134 outputContainer->
push_back(ttL1.release());
137 return StatusCode::SUCCESS;
JetConstituentVector::iterator iterator
TileTTL1Overlay(const std::string &name, ISvcLocator *pSvcLocator)
void groupTowers(const TileTTL1Container *towers, std::map< Identifier, std::vector< const TileTTL1 * >> &towerMap) const
Real Tile overlay towers and overlay on existing event.
SG::ReadHandleKey< TileTTL1Container > m_signalTileMBTSTTL1Key
const_pointer_type cptr()
Dereference the pointer.
SG::WriteHandleKey< TileTTL1Container > m_outputTileTTL1Key
const std::string & name() const
Return the StoreGate ID for the referenced object.
SG::WriteHandleKey< TileTTL1Container > m_outputTileMBTSTTL1Key
#define ATH_MSG_VERBOSE(x)
Property holding a SG store/key/clid from which a ReadHandle is made.
eFexTowerBuilder creates xAOD::eFexTowerContainer from supercells (LATOME) and triggerTowers (TREX) i...
SG::ReadHandleKey< TileTTL1Container > m_signalTileTTL1Key
An algorithm that can be simultaneously executed in multiple threads.
StatusCode overlay(const EventContext &ctx, const SG::ReadHandleKey< TileTTL1Container > &bkgKey, const SG::ReadHandleKey< TileTTL1Container > &signalKey, const SG::WriteHandleKey< TileTTL1Container > &outputKey, const std::string &label) const
Main algorithm execute.
Handle class for recording to StoreGate.
Property holding a SG store/key/clid from which a WriteHandle is made.
::StatusCode StatusCode
StatusCode definition for legacy code.
SG::ReadHandleKey< TileTTL1Container > m_bkgTileMBTSTTL1Key
std::string store() const
Return the name of the store holding the object we are proxying.
SG::ReadHandleKey< TileTTL1Container > m_bkgTileTTL1Key
virtual bool isValid() override final
Can the handle be successfully dereferenced?
value_type push_back(value_type pElem)
Add an element to the end of the collection.
StatusCode record(std::unique_ptr< T > data)
Record a const object to the store.
#define ATH_MSG_WARNING(x)
virtual StatusCode execute(const EventContext &ctx) const override final
Main algorithm execute.
Handle class for reading from StoreGate.
virtual StatusCode initialize() override final