|
|
Go to the documentation of this file.
23 edm::LogWarning(
"RPCSimHitMatcher") <<
"+++ Info: RPC geometry is unavailable. +++\n";
41 for (
const auto&
id : ch_ids) {
45 << simhits_gp.eta() <<
" phi " << simhits_gp.phi() <<
" nCh "
61 if (
h.trackId() != track_id)
63 int pdgid =
h.particleType();
79 std::set<unsigned int>
result;
81 const auto&
id =
p.first;
93 std::set<unsigned int>
result;
95 const auto&
id =
p.first;
120 if (sim_hits.empty())
125 for (
const auto&
h : sim_hits) {
127 const auto&
d =
h.detUnitId();
128 sums += dynamic_cast<const RPCGeometry*>(
geometry_)->roll(
d)->strip(lp);
139 for (
const auto& roll : dynamic_cast<const RPCGeometry*>(
geometry_)->
chamber(
id)->rolls()) {
140 int max_nstrips = roll->nstrips();
143 int central_strip = static_cast<int>(roll->topology().channel(lp));
144 int smin = central_strip - margin_n_strips;
145 smin = (smin > 0) ? smin : 1;
146 int smax = central_strip + margin_n_strips;
147 smax = (smax <= max_nstrips) ? smax : max_nstrips;
148 for (
int ss = smin;
ss <= smax; ++
ss)
int region() const
Region id: 0 for Barrel, +/-1 For +/- Endcap.
const TrackingGeometry * geometry_
void match(const SimTrack &t, const SimVertex &v)
do the matching
std::map< unsigned int, edm::PSimHitContainer > detid_to_hits_
RPCSimHitMatcher(const edm::ParameterSet &iPS, edm::ConsumesCollector &&iC)
GlobalPoint simHitsMeanPosition(const edm::PSimHitContainer &sim_hits) const
edm::PSimHitContainer simHits_
std::set< unsigned int > chamberIds(int type=MuonHitHelper::RPC_ALL) const
edm::ParameterSet simHitPSet_
void init(const edm::Event &e, const edm::EventSetup &eventSetup)
initialize the event
std::vector< unsigned > track_ids_
void match(const SimTrack &t, const SimVertex &v)
do the matching
std::set< int > hitStripsInDetId(unsigned int, int margin_n_strips=0) const
static int toRPCType(int re, int st, int ri)
edm::ESHandle< RPCGeometry > rpc_geom_
float simHitsMeanStrip(const edm::PSimHitContainer &sim_hits) const
std::map< unsigned int, edm::PSimHitContainer > chamber_to_hits_
edm::EDGetTokenT< edm::PSimHitContainer > simHitInput_
T getParameter(std::string const &) const
const edm::PSimHitContainer & hitsInDetId(unsigned int) const
void matchSimHitsToSimTrack()
bool hitStation(int st) const
const edm::PSimHitContainer & hitsInChamber(unsigned int) const
Abs< T >::type abs(const T &t)
std::vector< PSimHit > PSimHitContainer
edm::PSimHitContainer hits_
void init(const edm::Event &e, const edm::EventSetup &eventSetup)
initialize the event
strips
#turn off noise in all subdetectors simHcalUnsuppressedDigis.doNoise = False mix.digitizers....
std::set< unsigned int > detIds(int type=MuonHitHelper::RPC_ALL) const
ParameterSet const & getParameterSet(std::string const &) const