38 void endJob()
override;
45 std::map<l1t::demo::LinkId, std::vector<ap_uint<64>>>
linkData_;
51 algoBitMask_(
config.getParameter<
std::
array<unsigned long long, 9>>(
"algoBitMask")),
59 config.getParameter<unsigned
int>(
"maxLines"),
62 for (
unsigned int channel :
channels) {
73 auto algoBlockIt = algoBlocks.begin();
78 linkData_[{
"Algos", channel}] = std::vector<ap_uint<64>>(18, 0);
82 ap_uint<64>
mask = algoMaskIt !=
algoBitMask_.end() ? *algoMaskIt++ : ~static_cast<
unsigned long long>(0);
84 for (std::size_t
idx = 0;
idx < 64 && algoBlockIt != algoBlocks.end();
idx++, algoBlockIt++) {
85 auto& [
algoName, algoBlock] = *algoBlockIt;
87 idx, algoBlock.decisionBeforeBxMaskAndPrescale() &&
mask.bit(
idx));
112 desc.add<std::vector<unsigned int>>(
"channels");
113 desc.add<std::vector<unsigned long long>>(
"algoBitMask",
114 {0xffffffffffffffffull,
115 0xffffffffffffffffull,
116 0xffffffffffffffffull,
117 0xffffffffffffffffull,
118 0xffffffffffffffffull,
119 0xffffffffffffffffull,
120 0xffffffffffffffffull,
121 0xffffffffffffffffull,
122 0xffffffffffffffffull});
123 desc.add<
unsigned int>(
"maxLines", 1024);
const std::array< unsigned long long, 9 > algoBitMask_
Logical ID for link within any given time slice (e.g. ["tracks", 0] -> ["tracks", 17] for links from ...
const edm::EDGetTokenT< P2GTAlgoBlockMap > algoBlocksToken_
void addEvent(const EventData &data)
std::map< std::string, P2GTAlgoBlock > P2GTAlgoBlockMap
FileFormat parseFileFormat(const std::string &)
example_stream void analyze(const edm::Event &, const edm::EventSetup &) override
void analyze(const edm::Event &, const edm::EventSetup &) override
void addDefault(ParameterSetDescription const &psetDescription)
L1GTAlgoBoardWriter(const edm::ParameterSet &)
const std::array< unsigned int, 2 > channels_
#define DEFINE_FWK_MODULE(type)
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
std::map< LinkId, std::pair< ChannelSpec, std::vector< size_t > > > ChannelMap_t
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
std::map< l1t::demo::LinkId, std::vector< ap_uint< 64 > > > linkData_
Class representing information phase-2 ATCA I/O data corresponding to a single event, with logical channel IDs (essentially string-uint pairs, e.g. tracks-0 to tracks-17).
l1t::demo::BoardDataWriter boardDataWriter_