|
|
Go to the documentation of this file.
47 : g4Label_(ps.getParameter<
std::
string>(
"moduleLabel")),
48 caloHitSource_(ps.getParameter<
std::
string>(
"caloHitSource")),
49 nameSense_(ps.getParameter<
std::
string>(
"nameSense")),
50 nameDetector_(ps.getParameter<
std::
string>(
"nameDevice")),
51 verbosity_(ps.getParameter<
int>(
"Verbosity")),
64 desc.add<
int>(
"Verbosity", 0);
65 descriptions.
add(
"hgcalHitIdCheckEE",
desc);
70 edm::LogVerbatim(
"HitStudy") <<
"Run = " <<
e.id().run() <<
" Event = " <<
e.id().event();
74 const std::vector<DetId>& validIds =
geom->getValidDetIds();
78 bool getHits = (hitsCalo.
isValid());
79 uint32_t
nhits = (getHits) ? hitsCalo->size() : 0;
82 edm::LogVerbatim(
"HitStudy") <<
"HGcalHitIdCheck: Input flags Hits " << getHits <<
" with " <<
nhits <<
" hits";
85 std::vector<PCaloHit>
hits;
86 hits.insert(
hits.end(), hitsCalo->begin(), hitsCalo->end());
91 if (
std::find(validIds.begin(), validIds.end(),
id) != validIds.end()) {
110 bool ok = (
std::find(validIds.begin(), validIds.end(),
DetId(hid2)) != validIds.end());
112 << hid2 <<
" in list " <<
ok;
115 <<
"Hit[" <<
all <<
":" <<
good <<
"]" << std::hex <<
id.rawId() <<
std::dec <<
" not valid *****";
123 <<
" Invalid DetIds = " << (
all -
good);
const auto good
min quality of good
int iphi() const
get the phi index
int ring() const
get the eta index
void analyze(edm::Event const &, edm::EventSetup const &) override
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
int layer() const
get the layer #
#define DEFINE_FWK_MODULE(type)
void add(std::string const &label, ParameterSetDescription const &psetDescription)
HGcalHitIdCheck(const edm::ParameterSet &ps)
const edm::EDGetTokenT< edm::PCaloHitContainer > tok_calo_
const std::string g4Label_
int type() const
get/set the type
const std::string caloHitSource_
bool getData(T &iHolder) const
const std::string nameDetector_
~HGcalHitIdCheck() override
Log< level::Info, true > LogVerbatim
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
std::vector< PCaloHit > PCaloHitContainer
const edm::ESGetToken< HGCalGeometry, IdealGeometryRecord > geomToken_
const std::string nameSense_