33 const auto& me0_ch_ids =
detIds();
34 for (
const auto&
id : me0_ch_ids) {
37 edm::LogInfo(
"ME0SimHitMatcher") <<
"me0chid " <<
ME0DetId(
id) <<
": nHits " << me0_simhits.size() <<
" phi " 52 if (
h.trackId() != track_id)
54 int pdgid =
h.particleType();
70 const auto& detids =
detIds();
71 for (
const auto&
d : detids) {
77 for (
const auto&
h :
hits) {
79 pads.insert(1 + static_cast<int>(
roll->padTopology().channel(lp)));
86 std::set<unsigned int>
result;
93 std::set<unsigned int>
result;
100 std::set<unsigned int>
result;
113 set<int> layers_with_hits;
115 for (
const auto&
h :
hits) {
117 layers_with_hits.insert(idd.layer());
119 return layers_with_hits.size();
138 if (sim_hits.empty())
143 for (
const auto&
h : sim_hits) {
146 const auto&
d =
h.detUnitId();
164 1 +
static_cast<int>(
dynamic_cast<const ME0Geometry*
>(
geometry_)->etaPartition(
id)->topology().channel(lp));
165 int smin = central_strip - margin_n_strips;
166 smin = (smin > 0) ? smin : 1;
167 int smax = central_strip + margin_n_strips;
168 smax = (smax <= max_nstrips) ? smax : max_nstrips;
169 for (
int ss = smin;
ss <= smax; ++
ss)
185 const auto& detids =
detIds();
186 for (
const auto&
id : detids) {
195 const auto& pad_ids =
detIds();
196 for (
const auto&
id : pad_ids) {
const edm::PSimHitContainer & hitsInChamber(unsigned int) const
T getParameter(std::string const &) const
const TrackingGeometry * geometry_
edm::PSimHitContainer hits_
edm::ESGetToken< ME0Geometry, MuonGeometryRecord > geomToken_
std::set< int > hitPadsInDetId(unsigned int) const
T const & getData(const ESGetToken< T, R > &iToken) const noexcept(false)
std::map< unsigned int, edm::PSimHitContainer > detid_to_hits_
GlobalPoint simHitsMeanPosition(const edm::PSimHitContainer &sim_hits) const
ParameterSet const & getParameterSet(std::string const &) const
std::map< unsigned int, std::set< int > > detids_to_pads_
std::vector< unsigned > track_ids_
void matchSimHitsToSimTrack()
int nLayersWithHitsInSuperChamber(unsigned int) const
int nPadsWithHits() const
std::set< unsigned int > detIds() const
edm::PSimHitContainer simHits_
float simHitsMeanStrip(const edm::PSimHitContainer &sim_hits) const
edm::ParameterSet simHitPSet_
std::map< unsigned int, edm::PSimHitContainer > chamber_to_hits_
Abs< T >::type abs(const T &t)
std::set< unsigned int > superChamberIdsCoincidences(int min_n_layers=4) const
void init(const edm::Event &e, const edm::EventSetup &eventSetup)
initialize the event
Log< level::Info, false > LogInfo
edm::PSimHitContainer no_hits_
ME0SimHitMatcher(const edm::ParameterSet &iPS, edm::ConsumesCollector &&iC)
void match(const SimTrack &t, const SimVertex &v)
do the matching
std::set< unsigned int > superChamberIds() const
edm::EDGetTokenT< edm::PSimHitContainer > simHitInput_
int nCoincidenceChambers(int min_n_layers=4) const
std::set< int > hitPartitions() const
const edm::PSimHitContainer & hitsInDetId(unsigned int) const
void match(const SimTrack &t, const SimVertex &v)
do the matching
std::set< unsigned int > chamberIds() const
std::set< int > hitStripsInDetId(unsigned int, int margin_n_strips=0) const
strips
#turn off noise in all subdetectors simHcalUnsuppressedDigis.doNoise = False mix.digitizers.hcal.doNoise = False simEcalUnsuppressedDigis.doNoise = False mix.digitizers.ecal.doNoise = False simEcalUnsuppressedDigis.doESNoise = False simSiPixelDigis.AddNoise = False mix.digitizers.pixel.AddNoise = False simSiStripDigis.Noise = False mix.digitizers.strip.AddNoise = False
std::vector< PSimHit > PSimHitContainer
void init(const edm::Event &e, const edm::EventSetup &eventSetup)
initialize the event
const edm::PSimHitContainer & hitsInSuperChamber(unsigned int) const
The Signals That Services Can Subscribe To This is based on ActivityRegistry h
Helper function to determine trigger accepts.
std::map< unsigned int, edm::PSimHitContainer > superChamber_to_hits_