14 produces<l1t::RegionalMuonCandBxCollection>(
"BMTF");
15 produces<l1t::RegionalMuonCandBxCollection>(
"BMTF2");
32 edm::LogInfo(
"L1TDQM") <<
"copy RegionalMuonCandBxCollections created";
33 edm::LogInfo(
"L1TDQM") <<
"bmtfKalman_copy address: " << bmtfKalman_copy;
34 edm::LogInfo(
"L1TDQM") <<
"bmtfLegacy_copy address: " << bmtfLegacy_copy;
38 if (
feds->FEDData(1376).size() > 0)
40 else if (
feds->FEDData(1377).size() > 0)
43 edm::LogError(
"L1TDQM") <<
"[L1TBMTFAlgoSelector] Both BMTF feds (1376, 1377) seem empty." 44 <<
"Using Default Configuration." 45 <<
"Will be wrong if this is Kalman triggering and ZS is enabled";
47 std::unique_ptr<l1t::RegionalMuonCandBxCollection> bmtfTriggering, bmtfSecondary;
48 bmtfTriggering.reset(bmtfLegacy_copy);
49 bmtfSecondary.reset(bmtfKalman_copy);
51 edm::LogInfo(
"L1TDQM") <<
"Triggering and Secondary pointers filled:";
52 edm::LogInfo(
"L1TDQM") <<
"bmtfTriggering address: " << bmtfTriggering.get();
53 edm::LogInfo(
"L1TDQM") <<
"bmtfSecondary address: " << bmtfSecondary.get();
62 edm::LogInfo(
"L1TDQM") <<
"L1T Rcd taken from the FEDData.";
63 edm::LogInfo(
"L1TDQM") <<
"l1tRcd.size=" << l1tRcd.
size() <<
" for fed:" << nonEmptyFed;
65 const unsigned char *
data = l1tRcd.
data();
67 edm::LogInfo(
"L1TDQM") <<
"header and data extracted from the Rcd.";
83 if (!packet.
payload().empty()) {
85 const uint32_t *
start = (
const uint32_t *)payload64.get();
86 const uint32_t *end =
start + (packet.
payload().at(0).size() * 2);
89 algo_ver =
payload.getAlgorithmFWVersion();
91 edm::LogInfo(
"L1TDQM") <<
"algo-ver = " << algo_ver << std::endl;
93 edm::LogError(
"L1TDQM") <<
"amc13 payload is empty, cannot extract AMC13 Packet...";
98 std::unique_ptr<l1t::RegionalMuonCandBxCollection> bmtfTriggering, bmtfSecondary;
99 if (algo_ver >= 2499805536) {
101 bmtfTriggering.reset(bmtfKalman_copy);
102 bmtfSecondary.reset(bmtfLegacy_copy);
105 bmtfTriggering.reset(bmtfLegacy_copy);
106 bmtfSecondary.reset(bmtfKalman_copy);
109 edm::LogInfo(
"L1TDQM") <<
"Triggering and Secondary pointers filled:";
110 edm::LogInfo(
"L1TDQM") <<
"bmtfTriggering address: " << bmtfTriggering.get();
111 edm::LogInfo(
"L1TDQM") <<
"bmtfSecondary address: " << bmtfSecondary.get();
T getParameter(std::string const &) const
OrphanHandle< PROD > put(std::unique_ptr< PROD > product)
Put a new product.
~L1TBMTFAlgoSelector() override
BXVector< RegionalMuonCand > RegionalMuonCandBxCollection
size_t size() const
Lenght of the data buffer in bytes.
bool getByToken(EDGetToken token, Handle< PROD > &result) const
Log< level::Error, false > LogError
edm::EDGetToken bmtfLegacyToken
L1TBMTFAlgoSelector(const edm::ParameterSet &ps)
#define DEFINE_FWK_MODULE(type)
void produce(edm::Event &, const edm::EventSetup &) override
Log< level::Info, false > LogInfo
unsigned long long uint64_t
edm::EDGetToken bmtfKalmanToken
bool parse(const uint64_t *start, const uint64_t *data, unsigned int size, unsigned int lv1, unsigned int bx, bool legacy_mc=false, bool mtf7_mode=false)
char data[epos_bytes_allocation]
std::vector< amc::Packet > payload() const
const unsigned char * data() const
Return a const pointer to the beginning of the data buffer.