40 produces<RPCRecHitCollection>();
46 string theAlgoName = config.
getParameter<
string>(
"recAlgo");
62 std::cerr <<
"Masked Strips File cannot not be opened" << std::endl;
68 if (
inputFile.good() ) MaskVec.push_back(Item);
79 std::cerr <<
"Dead Strips File cannot not be opened" << std::endl;
85 if (
inputFile.good() ) DeadVec.push_back(Item);
96 delete RPCMaskedStripsObj;
97 delete RPCDeadStripsObj;
111 RPCMaskedStripsObj->MaskVec = tmp_obj->
MaskVec;
115 std::vector<RPCMaskedStrips::MaskItem>::iterator posVec;
116 for ( posVec = MaskVec.begin(); posVec != MaskVec.end(); ++posVec ) {
118 Item.
rawId = (*posVec).rawId;
119 Item.
strip = (*posVec).strip;
120 RPCMaskedStripsObj->MaskVec.push_back(Item);
130 RPCDeadStripsObj->DeadVec = tmp_obj->
DeadVec;
134 std::vector<RPCDeadStrips::DeadItem>::iterator posVec;
135 for ( posVec = DeadVec.begin(); posVec != DeadVec.end(); ++posVec ) {
137 Item.
rawId = (*posVec).rawId;
138 Item.
strip = (*posVec).strip;
139 RPCDeadStripsObj->DeadVec.push_back(Item);
157 event.getByToken(theRPCDigiLabel,digis);
161 theAlgo->setES(setup);
170 for (rpcdgIt = digis->begin(); rpcdgIt != digis->end();
174 const RPCDetId& rpcId = (*rpcdgIt).first;
177 const RPCRoll* roll = rpcGeom->roll(rpcId);
179 edm::LogError(
"BadDigiInput")<<
"Failed to find RPCRoll for ID "<<rpcId;
190 int rawId = rpcId.
rawId();
191 int Size = RPCMaskedStripsObj->MaskVec.size();
192 for (
int i = 0;
i < Size;
i++ ) {
193 if ( RPCMaskedStripsObj->MaskVec[
i].rawId == rawId ) {
194 int bit = RPCMaskedStripsObj->MaskVec[
i].strip;
199 Size = RPCDeadStripsObj->DeadVec.size();
200 for (
int i = 0;
i < Size;
i++ ) {
201 if ( RPCDeadStripsObj->DeadVec[
i].rawId == rawId ) {
202 int bit = RPCDeadStripsObj->DeadVec[
i].strip;
210 theAlgo->reconstruct(*roll, rpcId, range, mask);
212 if(recHits.
size() > 0)
213 recHitCollection->put(rpcId, recHits.
begin(), recHits.
end());
216 event.put(recHitCollection);
T getParameter(std::string const &) const
std::vector< MaskItem > MaskVec
virtual void beginRun(const edm::Run &, const edm::EventSetup &) override
uint32_t rawId() const
get the raw id
virtual void produce(edm::Event &event, const edm::EventSetup &setup) override
The method which produces the rechits.
std::bitset< maskSIZE > RollMask
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision and the trigger will pass if any such matching triggers are FAIL or EXCEPTION A wildcarded negative criterion that matches more than one trigger in the trigger but the state exists so we define the behavior If all triggers are the negative crieriion will lead to accepting the event(this again matches the behavior of"!*"before the partial wildcard feature was incorporated).The per-event"cost"of each negative criterion with multiple relevant triggers is about the same as!*was in the past
virtual ~RPCRecHitProducer()
Destructor.
edm::RangeMap< RPCDetId, edm::OwnVector< RPCRecHit, edm::ClonePolicy< RPCRecHit > >, edm::ClonePolicy< RPCRecHit > > RPCRecHitCollection
RPCRecHitProducer(const edm::ParameterSet &config)
Constructor.
T const * product() const
std::vector< DeadItem > DeadVec
std::pair< const_iterator, const_iterator > Range
std::string fullPath() const
void setup(std::vector< TH2F > &depth, std::string name, std::string units="")
T get(const Candidate &c)