10 : m_consumesCollector(iC),
11 m_l1tAlgBlkInputTag(
pset.getParameter<
edm::
InputTag>(
"l1tAlgBlkInputTag")),
12 m_l1tExtBlkInputTag(
pset.getParameter<
edm::
InputTag>(
"l1tExtBlkInputTag")),
13 m_findL1TAlgBlk(
false),
14 m_findL1TExtBlk(
false),
15 m_readPrescalesFromFile(
pset.getParameter<
bool>(
"ReadPrescalesFromFile")),
16 m_foundPreferredL1TAlgBlk(
false),
17 m_foundPreferredL1TExtBlk(
false) {
25 desc.
add<
bool>(
"ReadPrescalesFromFile",
false);
51 if (branchDescription.
dropped()) {
55 std::vector<edm::InputTag> preferredL1TAlgBlkInputTag = {
edm::InputTag(
"gtStage2Digis"),
58 std::vector<edm::InputTag> preferredL1TExtBlkInputTag = {
edm::InputTag(
"gtStage2Digis"),
63 if (m_findL1TAlgBlk && (!m_foundMultipleL1TAlgBlk) &&
69 if (m_foundPreferredL1TAlgBlk) {
75 if ((m_l1tAlgBlkInputTag.label() == branchDescription.
moduleLabel()) &&
77 (m_l1tAlgBlkInputTag.process() != branchDescription.
processName()))) {
78 LogDebug(
"L1TGlobalUtil") <<
"\nWARNING: Found multiple preferred input tags for GlobalAlgBlkBxCollection, "
79 <<
"\nwith different instaces or processes."
80 <<
"\nInput tag already found: " << (m_l1tAlgBlkInputTag) <<
"\nActual tag: " << (
tag)
81 <<
"\nInput tag set to empty tag." << std::endl;
83 m_foundMultipleL1TAlgBlk =
true;
88 for (std::vector<edm::InputTag>::const_iterator itPrefTag = preferredL1TAlgBlkInputTag.begin(),
89 itPrefTagEnd = preferredL1TAlgBlkInputTag.end();
90 itPrefTag != itPrefTagEnd;
92 if (branchDescription.
moduleLabel() == itPrefTag->label()) {
93 m_l1tAlgBlkInputTag =
tag;
95 m_foundPreferredL1TAlgBlk =
true;
99 <<
"\nWARNING: Input tag for GlobalAlgBlkBxCollection product set to preferred input tag" << (
tag)
106 if (!m_foundPreferredL1TAlgBlk) {
110 if (m_inputTagsL1TAlgBlk.size() > 1) {
111 LogDebug(
"L1TGlobalUtil") <<
"\nWARNING: Found multiple input tags for GlobalAlgBlkBxCollection product."
112 <<
"\nNone is in the preferred input tags - no safe choice."
113 <<
"\nInput tag already found: " << (m_l1tAlgBlkInputTag) <<
"\nActual tag: " << (
tag)
114 <<
"\nInput tag set to empty tag." << std::endl;
116 m_foundMultipleL1TAlgBlk =
true;
119 if (m_l1tAlgBlkToken.isUninitialized()) {
120 m_l1tAlgBlkInputTag =
tag;
121 m_inputTagsL1TAlgBlk.push_back(
tag);
124 LogDebug(
"L1TGlobalUtil") <<
"\nWARNING: No preferred input tag found for GlobalAlgBlkBxCollection."
125 <<
"\nInput tag set to " << (
tag) << std::endl;
133 if (m_findL1TExtBlk && (!m_foundMultipleL1TExtBlk) &&
139 if (m_foundPreferredL1TExtBlk) {
145 if ((m_l1tExtBlkInputTag.label() == branchDescription.
moduleLabel()) &&
147 (m_l1tExtBlkInputTag.process() != branchDescription.
processName()))) {
148 LogDebug(
"L1TGlobalUtil") <<
"\nWARNING: Found multiple preferred input tags for GlobalExtBlkBxCollection, "
149 <<
"\nwith different instaces or processes."
150 <<
"\nInput tag already found: " << (m_l1tExtBlkInputTag) <<
"\nActual tag: " << (
tag)
151 <<
"\nInput tag set to empty tag." << std::endl;
153 m_foundMultipleL1TExtBlk =
true;
159 for (std::vector<edm::InputTag>::const_iterator itPrefTag = preferredL1TExtBlkInputTag.begin(),
160 itPrefTagEnd = preferredL1TExtBlkInputTag.end();
161 itPrefTag != itPrefTagEnd;
163 if (branchDescription.
moduleLabel() == itPrefTag->label()) {
164 m_l1tExtBlkInputTag =
tag;
166 m_foundPreferredL1TExtBlk =
true;
170 <<
"\nWARNING: Input tag for GlobalExtBlkBxCollection product set to preferred input tag" << (
tag)
177 if (!m_foundPreferredL1TExtBlk) {
181 if (m_inputTagsL1TExtBlk.size() > 1) {
182 LogDebug(
"L1TGlobalUtil") <<
"\nWARNING: Found multiple input tags for GlobalExtBlkBxCollection."
183 <<
"\nNone is in the preferred input tags - no safe choice."
184 <<
"\nInput tag already found: " << (m_l1tExtBlkInputTag) <<
"\nActual tag: " << (
tag)
185 <<
"\nInput tag set to empty tag." << std::endl;
187 m_foundMultipleL1TExtBlk =
true;
190 if (m_l1tExtBlkToken.isUninitialized()) {
191 m_l1tExtBlkInputTag =
tag;
192 m_inputTagsL1TExtBlk.push_back(
tag);
195 LogDebug(
"L1TGlobalUtil") <<
"\nWARNING: No preferred input tag found for GlobalExtBlkBxCollection product."
196 <<
"\nInput tag set to " << (
tag) << std::endl;