ATLAS Offline Software
Loading...
Searching...
No Matches
ITkStripRawDataProviderTool.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3*/
4
6
9
11
12// Initialize
14{
15 ATH_CHECK(m_decoder.retrieve());
16
17 return StatusCode::SUCCESS;
18}
19
20
21// Convert method
22StatusCode ITkStripRawDataProviderTool::convert(std::vector<const ROBFragment*>& vecROBFrags,
23 SCT_RDO_Container& rdoIDCont,
25 DataPool<SCT3_RawData>* dataItemsPool,
26 const EventContext& ctx) const
27{
28
29 ATH_MSG_DEBUG("ITkStripRawDataProviderTool::convert()");
30 if (vecROBFrags.empty()) return StatusCode::SUCCESS;
31 // loop over the ROB fragments
32 StatusCode sc{StatusCode::SUCCESS};
33 ATH_MSG_DEBUG("vecROBFrags size: " << vecROBFrags.size());
34 for (const ROBFragment* robFrag : vecROBFrags) {
35 // get the ID of this ROB/ROD
36 sc = m_decoder->fillCollection(*robFrag, rdoIDCont, errs, dataItemsPool, ctx);
37 if (sc == StatusCode::FAILURE) {
38 if (m_decodeErrCount <= 100) {
39 if (100 == m_decodeErrCount) {
40 ATH_MSG_ERROR("Too many Problem with ITk Strip Decoding messages, turning message off.");
41 }
42 else {
43 ATH_MSG_ERROR("Problem with ITk Strip ByteStream Decoding!");
44 }
46 }
47 }
48 }
49
50 if (sc == StatusCode::FAILURE) {
51 ATH_MSG_ERROR("There was a problem with ITk Strip ByteStream conversion");
52 return sc;
53 }
54
55 return sc;
56}
#define ATH_CHECK
Evaluate an expression and check for errors.
#define ATH_MSG_ERROR(x)
#define ATH_MSG_DEBUG(x)
InDetRawDataContainer< InDetRawDataCollection< SCT_RDORawData > > SCT_RDO_Container
Handle class for reading from StoreGate.
a typed memory pool that saves time spent allocation small object.
Definition DataPool.h:63
IDC like storage for BS errors, TODO, customise implementation further so that we store int rather th...
std::atomic_int m_decodeErrCount
Number of decode errors encountered in decoding.
virtual StatusCode convert(std::vector< const OFFLINE_FRAGMENTS_NAMESPACE::ROBFragment * > &vecROBFrags, SCT_RDO_Container &rdoIDCont, IDCInDetBSErrContainer &errs, DataPool< SCT3_RawData > *dataItemsPool, const EventContext &ctx) const override
Main decoding method.
virtual StatusCode initialize() override
Initialize.
ToolHandle< IITkStripsRodDecoder > m_decoder
Algorithm Tool to decode ROD byte stream into RDO.
eformat::ROBFragment< PointerType > ROBFragment
Definition RawEvent.h:27