CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Private Types | Private Attributes
cms::DigitizerFP420 Class Reference

#include <DigitizerFP420.h>

Inheritance diagram for cms::DigitizerFP420:
edm::EDProducer edm::ProducerBase edm::EDConsumerBase edm::ProductRegistryHelper

Public Member Functions

 DigitizerFP420 (const edm::ParameterSet &conf)
 
virtual void produce (edm::Event &e, const edm::EventSetup &c)
 
virtual ~DigitizerFP420 ()
 
- Public Member Functions inherited from edm::EDProducer
 EDProducer ()
 
ModuleDescription const & moduleDescription () const
 
virtual ~EDProducer ()
 
- Public Member Functions inherited from edm::ProducerBase
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
 ProducerBase ()
 
void registerProducts (ProducerBase *, ProductRegistry *, ModuleDescription const &)
 
std::function< void(BranchDescription
const &)> 
registrationCallback () const
 used by the fwk to register list of products More...
 
virtual ~ProducerBase ()
 
- Public Member Functions inherited from edm::EDConsumerBase
std::vector< ConsumesInfoconsumesInfo () const
 
 EDConsumerBase ()
 
ProductHolderIndexAndSkipBit indexFrom (EDGetToken, BranchType, TypeID const &) const
 
void itemsMayGet (BranchType, std::vector< ProductHolderIndexAndSkipBit > &) const
 
void itemsToGet (BranchType, std::vector< ProductHolderIndexAndSkipBit > &) const
 
std::vector
< ProductHolderIndexAndSkipBit >
const & 
itemsToGetFromEvent () const
 
void labelsForToken (EDGetToken iToken, Labels &oLabels) const
 
void modulesDependentUpon (const std::string &iProcessName, std::vector< const char * > &oModuleLabels) const
 
void modulesWhoseProductsAreConsumed (std::vector< ModuleDescription const * > &modules, ProductRegistry const &preg, std::map< std::string, ModuleDescription const * > const &labelsToDesc, std::string const &processName) const
 
bool registeredToConsume (ProductHolderIndex, bool, BranchType) const
 
bool registeredToConsumeMany (TypeID const &, BranchType) const
 
void updateLookup (BranchType iBranchType, ProductHolderIndexHelper const &)
 
virtual ~EDConsumerBase ()
 

Private Types

typedef std::map< unsigned int,
std::vector< PSimHit >
, std::less< unsigned int > > 
simhit_map
 
typedef simhit_map::iterator simhit_map_iterator
 
typedef std::vector< std::string > vstring
 

Private Attributes

std::vector< HDigiFP420collector
 
edm::ParameterSet conf_
 
int dn0
 
int numStrips
 
int pn0
 
int rn0
 
simhit_map SimHitMap
 
int sn0
 
FP420DigiMainstripDigitizer_
 
vstring trackerContainers
 
int verbosity
 

Additional Inherited Members

- Public Types inherited from edm::EDProducer
typedef EDProducer ModuleType
 
- Public Types inherited from edm::ProducerBase
typedef
ProductRegistryHelper::TypeLabelList 
TypeLabelList
 
- Public Types inherited from edm::EDConsumerBase
typedef ProductLabels Labels
 
- Static Public Member Functions inherited from edm::EDProducer
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &descriptions)
 
- Protected Member Functions inherited from edm::EDConsumerBase
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > consumes (edm::InputTag const &tag)
 
EDGetToken consumes (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken consumes (TypeToGet const &id, edm::InputTag const &tag)
 
ConsumesCollector consumesCollector ()
 Use a ConsumesCollector to gather consumes information from helper functions. More...
 
template<typename ProductType , BranchType B = InEvent>
void consumesMany ()
 
void consumesMany (const TypeToGet &id)
 
template<BranchType B>
void consumesMany (const TypeToGet &id)
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > mayConsume (edm::InputTag const &tag)
 
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 

Detailed Description

Definition at line 41 of file DigitizerFP420.h.

Member Typedef Documentation

typedef std::map<unsigned int, std::vector<PSimHit>,std::less<unsigned int> > cms::DigitizerFP420::simhit_map
private

Definition at line 62 of file DigitizerFP420.h.

typedef simhit_map::iterator cms::DigitizerFP420::simhit_map_iterator
private

Definition at line 63 of file DigitizerFP420.h.

typedef std::vector<std::string> cms::DigitizerFP420::vstring
private

Definition at line 61 of file DigitizerFP420.h.

Constructor & Destructor Documentation

cms::DigitizerFP420::DigitizerFP420 ( const edm::ParameterSet conf)
explicit

Definition at line 96 of file DigitizerFP420.cc.

References HLT_25ns14e33_v1_cff::alias, conf_, gather_cfg::cout, dn0, edm::ParameterSet::getParameter(), edm::ParameterSet::getUntrackedParameter(), pn0, rn0, sn0, AlCaHLTBitMon_QueryRunRegistry::string, trackerContainers, and verbosity.

96  :conf_(conf),stripDigitizer_(new FP420DigiMain(conf)) {
97 
98 
99  std::string alias ( conf.getParameter<std::string>("@module_label") );
100 
101  // produces<edm::DetSetVector<HDigiFP420> >().setBranchAlias( alias );
102  // produces<edm::DetSetVector<HDigiFP420SimLink> >().setBranchAlias ( alias + "hDigiFP420SimLink");
103  produces<DigiCollectionFP420>().setBranchAlias( alias );
104 
105  trackerContainers.clear();
106  trackerContainers = conf.getParameter<std::vector<std::string> >("ROUList");
107 
108  verbosity = conf_.getUntrackedParameter<int>("VerbosityLevel");
109  dn0 = conf_.getParameter<int>("NumberFP420Detectors");
110  sn0 = conf_.getParameter<int>("NumberFP420Stations");
111  pn0 = conf_.getParameter<int>("NumberFP420SPlanes");
112  rn0 = 7;
113  //rn0 = 3;
114 
115  // produces<DigiCollectionFP420>();
116 
117  // produces<StripDigiCollection>();
118  // produces<HDigiFP420>();
119  // produces<edm::DetSetVector<HDigiFP420> >().setBranchAlias( alias );
120 
121  // produces<DigiCollectionFP420>();
122  // produces<DigiCollectionFP420>("HDigiFP420");
123 
124  // produces<edm::DigiCollectionFP420>();
125 
126  // produces<edm::DetSetVector<DigiCollectionFP420> >();
127 
128  if(verbosity>0) {
129  std::cout << "Creating a DigitizerFP420" << std::endl;
130  std::cout << "DigitizerFP420: dn0=" << dn0 << " sn0=" << sn0 << " pn0=" << pn0 << " rn0=" << rn0 << std::endl;
131  std::cout << "DigitizerFP420:trackerContainers.size()=" << trackerContainers.size() << std::endl;
132 
133  }
134  }
T getParameter(std::string const &) const
T getUntrackedParameter(std::string const &, T const &) const
FP420DigiMain * stripDigitizer_
edm::ParameterSet conf_
tuple cout
Definition: gather_cfg.py:121
cms::DigitizerFP420::~DigitizerFP420 ( )
virtual

Definition at line 137 of file DigitizerFP420.cc.

References gather_cfg::cout, stripDigitizer_, and verbosity.

137  {
138  if(verbosity>0) {
139  std::cout << "Destroying a DigitizerFP420" << std::endl;
140  }
141  delete stripDigitizer_;
142 
143  }
FP420DigiMain * stripDigitizer_
tuple cout
Definition: gather_cfg.py:121

Member Function Documentation

void cms::DigitizerFP420::produce ( edm::Event e,
const edm::EventSetup c 
)
virtual

Implements edm::EDProducer.

Definition at line 148 of file DigitizerFP420.cc.

References HDigiFP420::adc(), HDigiFP420::channel(), collector, gather_cfg::cout, PSimHit::detUnitId(), dn0, plotBeamSpotDB::first, edm::Event::getByLabel(), i, cmsHarvester::index, estimatePileup::inputRange, convertSQLitetoXML_cfg::output, FP420NumberingScheme::packFP420Index(), FP420NumberingScheme::packMYIndex(), pn0, edm::Event::put(), rn0, FP420DigiMain::run(), SimHitMap, sn0, HDigiFP420::strip(), stripDigitizer_, HDigiFP420::stripV(), HDigiFP420::stripVW(), trackerContainers, FP420NumberingScheme::unpackFP420Index(), FP420NumberingScheme::unpackLayerIndex(), FP420NumberingScheme::unpackMYIndex(), FP420NumberingScheme::unpackOrientation(), verbosity, and ecaldqm::zside().

148  {
149  // be lazy and include the appropriate namespaces
150  using namespace edm;
151  using namespace std;
152 
153  if(verbosity>0) {
154  std::cout <<" ===" << std::endl;
155  std::cout <<" ============== DigitizerFP420: start produce= " << std::endl;
156  std::cout <<" ===" << std::endl;
157  }
158  // Get input
159  // std::cout << "DigitizerFP420 start produce" << std::endl;
160  // edm::ESHandle < ParticleDataTable > pdt;
161  // iSetup.getData( pdt );
162 
163  // Step A: Get Inputs for allTrackerHits
164 
165 
167  std::vector<const CrossingFrame<PSimHit> *> cf_simhitvec;
168  for(uint32_t i = 0; i< trackerContainers.size();i++){
169  iEvent.getByLabel("mix",trackerContainers[i],cf_simhit);
170  cf_simhitvec.push_back(cf_simhit.product()); }
171  std::auto_ptr<MixCollection<PSimHit> > allTrackerHits(new MixCollection<PSimHit>(cf_simhitvec));
172 
173  // use instead of the previous
174  /*
175  std::cout <<" ============== DigitizerFP420: start loop 1 " << std::endl;
176  edm::Handle<CrossingFrame<PSimHit> > xFrame;
177  std::cout <<" ============== DigitizerFP420: start loop 2 " << std::endl;
178  iEvent.getByLabel("mix","FP420SI",xFrame);
179  std::cout <<" ============== DigitizerFP420: start loop 3 " << std::endl;
180  std::auto_ptr<MixCollection<PSimHit> > allTrackerHits( new MixCollection<PSimHit>(xFrame.product()) );
181  std::cout <<" ============== DigitizerFP420: start loop 4 " << std::endl;
182  */
183 
184  // use instead of the previous
185  /*
186  edm::Handle<CrossingFrame<PSimHit> > crossingFrame;
187  const std::string FP420HitsName("FP420SI");
188  bool isHit = true;
189  iEvent.getByLabel("mix",FP420HitsName,crossingFrame);
190  MixCollection<PSimHit> * FP420Hits = 0 ;
191  std::cout <<" ============== DigitizerFP420: start loop 1 " << std::endl;
192  // std::auto_ptr<MixCollection<PSimHit> > allTrackerHits(new MixCollection<PSimHit>(crossingFrame.product()));
193  FP420Hits = new MixCollection<PSimHit>(crossingFrame.product());
194  std::cout <<" ============== DigitizerFP420: start loop 2 " << std::endl;
195  // if ( ! FP420Hits->inRegistry() ) isHit = false;
196  // if ( isHit ) {
197  std::auto_ptr<MixCollection<PSimHit> > allTrackerHits( FP420Hits );
198  std::cout <<" ============== DigitizerFP420: start loop 3 " << std::endl;
199  // }
200  */
201 
202  // std::cout << "DigitizerFP420 Step A done" << std::endl;
203 
204  //Loop on PSimHit
205 
206 
208  // Step C: create empty output collection
209  std::auto_ptr<DigiCollectionFP420> output(new DigiCollectionFP420);
210  // std::auto_ptr<edm::DetSetVector<HDigiFP420> > outputfinal(new edm::DetSetVector<HDigiFP420>(output) );
211  // std::auto_ptr<edm::DetSetVector<HDigiFP420> > outputfinal(new edm::DetSetVector<HDigiFP420>(output) );
212  // std::auto_ptr<edm::DetSetVector<HDigiFP420SimLink> > outputlink(new edm::DetSetVector<HDigiFP420SimLink>(output) );
213 
214  SimHitMap.clear();
215 
216  // ==================================
217  if(verbosity>0) {
218  std::cout <<" ===" << std::endl;
219  std::cout <<" ============== DigitizerFP420: MixCollection treatment= " << std::endl;
220  std::cout <<" ===" << std::endl;
221  }
222 
224  for (isim=allTrackerHits->begin(); isim!= allTrackerHits->end();isim++) {
225  unsigned int unitID = (*isim).detUnitId();
226  int det, zside, sector, zmodule;
227  FP420NumberingScheme::unpackFP420Index(unitID, det, zside, sector, zmodule);
228  // below, the continues plane index should be (for even different sensor index zside)
229  // unsigned int intindex = packMYIndex(rn0, pn0, sn0, det, zside, sector, zmodule);
230  unsigned int intindex = FP420NumberingScheme::packMYIndex(rn0, pn0, sn0, det, zside, sector, zmodule);
231  // int zScale=(rn0-1), sScale = (rn0-1)*(pn0-1), dScale = (rn0-1)*(pn0-1)*(sn0-1);
232  // unsigned int intindex = dScale*(det - 1)+sScale*(sector - 1)+zScale*(zmodule - 1)+zside;
233 
234  if(verbosity>0) {
235  double losenergy = (*isim).energyLoss();
236  std::cout <<" ===" << std::endl;
237  std::cout <<" ============== DigitizerFP420: losenergy= " << losenergy << std::endl;
238  std::cout <<" === for intindex = " << intindex << std::endl;
239  }
240  // does not matter which index is used: intindex or unitID - mainly to collect hits under every index
241  SimHitMap[intindex].push_back((*isim));
242  // for development later one( cal be used another index):
243  // SimHitMap[unitID].push_back((*isim));
244  }
245  //============================================================================================================================
246 
247  if(verbosity>0) {
248  std::cout <<" ===" << std::endl;
249  std::cout <<" ============== DigitizerFP420: put zero to container " << std::endl;
250  std::cout <<" ===" << std::endl;
251  }
252  // put zero to container info from the beginning (important! because not any detID is updated with coming of new event !!!!!!
253  // clean info of container from previous event
254  for (int det=1; det<dn0; det++) {
255  for (int sector=1; sector<sn0; sector++) {
256  for (int zmodule=1; zmodule<pn0; zmodule++) {
257  for (int zside=1; zside<rn0; zside++) {
258  // intindex is a continues numbering of FP420
259  unsigned int detID = FP420NumberingScheme::packMYIndex(rn0, pn0, sn0, det, zside, sector, zmodule);
260  // int zScale=(rn0-1), sScale = (rn0-1)*(pn0-1), dScale = (rn0-1)*(pn0-1)*(sn0-1);
261  // unsigned int detID = dScale*(det - 1)+sScale*(sector - 1)+zScale*(zmodule - 1)+zside;
262  std::vector<HDigiFP420> collector;
263  collector.clear();
265  inputRange.first = collector.begin();
266  inputRange.second = collector.end();
267  output->putclear(inputRange,detID);
268  }//for
269  }//for
270  }//for
271  }//for
272  // !!!!!!
273  // if we want to keep Digi container/Collection for one event uncomment the line below and vice versa
274  output->clear(); //container_.clear() --> start from the beginning of the container
275 
276  //============================================================================================================================================
277 
278 
279  if(verbosity>0) {
280  std::cout <<" ===" << std::endl;
281  std::cout <<" ============== DigitizerFP420: start loop over det iu " << std::endl;
282  std::cout <<" ============== DigitizerFP420: SimHitMap.size()= " << SimHitMap.size() << std::endl;
283  std::cout <<" ===" << std::endl;
284  }
285  bool first = true;
286 
288  /*
289  if(verbosity>0) std::cout <<"======= DigitizerFP420: SimHitMap size = " << SimHitMap.size() << std::endl;
290  for(unsigned int i = 0; i < SimHitMap.size(); i++ ) {
291  // std::cout <<" ====== DigitizerFP420: i= " << i << std::endl;
292  vector<PSimHit>::const_iterator simHitIter = SimHitMap[i].begin();
293  vector<PSimHit>::const_iterator simHitIterEnd = SimHitMap[i].end();
294  for (;simHitIter != simHitIterEnd; ++simHitIter) {
295  const PSimHit ihit = *simHitIter;
296  unsigned int unitID = ihit.detUnitId();
297  if(verbosity>0) std::cout <<" ====== DigitizerFP420: unitID= " << unitID << " i= " << i << std::endl;
298  int det, zside, sector, zmodule;
299  FP420NumberingScheme::unpackFP420Index(unitID, det, zside, sector, zmodule);
300  int zScale=(rn0-1), sScale = (rn0-1)*(pn0-1), dScale = (rn0-1)*(pn0-1)*(sn0-1);
301  unsigned int iu = dScale*(det - 1)+sScale*(sector - 1)+zScale*(zmodule - 1)+zside;
302  }
303  }
304 */
306  //============================================================================================================================================
307  // new: <------
308  for(unsigned int i = 0; i < SimHitMap.size(); i++ ) {
309  vector<PSimHit>::const_iterator simHitIter = SimHitMap[i].begin();
310  vector<PSimHit>::const_iterator simHitIterEnd = SimHitMap[i].end();
311  for (;simHitIter != simHitIterEnd; ++simHitIter) {
312  const PSimHit ihit = *simHitIter;
313  unsigned int unitID = ihit.detUnitId();
314  if(verbosity>0 || verbosity==-50) std::cout <<" ====== DigitizerFP420: unitID= " << unitID << "Hit number i= " << i << std::endl;
315  int det, zside, sector, zmodule;
316  FP420NumberingScheme::unpackFP420Index(unitID, det, zside, sector, zmodule);
317  // <------
318  // old: <------
319  // for (int det=1; det<dn0; det++) {
320  // for (int sector=1; sector<sn0; sector++) {
321  // for (int zmodule=1; zmodule<pn0; zmodule++) {
322  // for (int zside=1; zside<rn0; zside++) {
323  // <------
324 
325 
326 
327 
328 
329  unsigned int iu = FP420NumberingScheme::packMYIndex(rn0, pn0, sn0, det, zside, sector, zmodule);
330  if(verbosity>0 || verbosity==-50) std::cout <<"for Hits iu = " << iu <<" sector = " << sector <<" zmodule = " << zmodule <<" zside = " << zside << " det=" << det << std::endl;
331  // int zScale=(rn0-1), sScale = (rn0-1)*(pn0-1), dScale = (rn0-1)*(pn0-1)*(sn0-1);
332  // unsigned int iu = dScale*(det - 1)+sScale*(sector - 1)+zScale*(zmodule - 1)+zside;
333 
334  if(verbosity>0) {
335  unsigned int index = FP420NumberingScheme::packFP420Index(det, zside, sector, zmodule);
336  std::cout << " DigitizerFP420: index = " << index << " iu = " << iu << std::endl;
337  }
338 
339  // GlobalVector bfield=pSetup->inTesla((*iu)->surface().position());
340  // CLHEP::Hep3Vector Bfieldloc=bfield();
341  G4ThreeVector bfield( 0., 0., 0.0 );
342  // G4ThreeVector bfield( 0.5, 0.5, 1.0 );
343 
344 
345  if(verbosity>0) {
346  std::cout <<" ===" << std::endl;
347  std::cout <<" ============== DigitizerFP420: call run for iu= " << iu << std::endl;
348  std::cout <<" ===" << std::endl;
349  }
350  collector.clear();
351 
352  collector= stripDigitizer_->run( SimHitMap[iu],
353  bfield,
354  iu
355  ); // stripDigitizer_.run... return
356  // ,sScale
357 
358 
359 
360  if(verbosity>0) {
361  std::cout <<" ===" << std::endl;
362  std::cout <<" ===" << std::endl;
363  std::cout <<"======= DigitizerFP420: collector size = " << collector.size() << std::endl;
364  std::cout <<" ===" << std::endl;
365  std::cout <<" ===" << std::endl;
366  }
367  /*
368 
369  std::vector<HDigiFP420> collector;
370  collector.clear();
371  DigiCollectionFP420::Range inputRange;
372  inputRange.first = collector.begin();
373  inputRange.second = collector.end();
374  output->putclear(inputRange,detID);
375  */
376  if (collector.size()>0){
377  if(verbosity>0) {
378  std::cout <<" ============= DigitizerFP420:collector start!!!!!!!!!!!!!!" << std::endl;
379  }
380  DigiCollectionFP420::Range outputRange;
381  outputRange.first = collector.begin();
382  outputRange.second = collector.end();
383 
384  if ( first ) {
385  // use it only if ClusterCollectionFP420 is the ClusterCollection of one event, otherwise, do not use (loose 1st cl. of 1st event only)
386  first = false;
387  unsigned int detID0= 0;
388  output->put(outputRange,detID0); // !!! put into adress 0 for detID which will not be used never
389  } //if ( first )
390 
391  // put !!!
392  output->put(outputRange,iu);
393 
394  } // if(collector.size()>0
395 
396  // } // for
397  // } // for
398  // } // for
399  // } // for
400 
401  }//for
402  }//for
403 
404  // END
405 
406  /*
407  if(verbosity>0) {
408  std::vector<HDigiFP420> theAllDigis;
409  theAllDigis.clear();
410  DigiCollectionFP420::Range outputRange;
411  DigiCollectionFP420::ContainerIterator sort_begin = outputRange.first;
412  DigiCollectionFP420::ContainerIterator sort_end = outputRange.second;
413  theAllDigis.insert(theAllDigis.end(), sort_begin, sort_end);
414  std::cout <<"====== theAllDigis size = " << theAllDigis.size() << std::endl;
415  for (std::vector<HDigiFP420>::iterator isim = theAllDigis.begin();
416  isim != theAllDigis.end(); ++isim){
417  const HDigiFP420 istrip = *isim;
418  std::cout << "*******************************************DigitizerFP420:check1" << std::endl;
419  std::cout << " strip number=" << istrip.strip() << " adc=" << istrip.adc() << std::endl;
420  std::cout <<" channel =" << istrip.channel() <<" V " << istrip.stripV() <<" VW " << istrip.stripVW() << std::endl;
421  std::cout <<" ===" << std::endl;
422  std::cout <<" ===" << std::endl;
423  std::cout <<" =======================" << std::endl;
424  }// for
425  }
426 */
427  if(verbosity==-50) {
428  // check of access to the collector:
429  for (int det=1; det<dn0; det++) {
430  for (int sector=1; sector<sn0; sector++) {
431  for (int zmodule=1; zmodule<pn0; zmodule++) {
432  for (int zside=1; zside<rn0; zside++) {
433  unsigned int iu = FP420NumberingScheme::packMYIndex(rn0, pn0, sn0, det, zside, sector, zmodule);
434  int layer = FP420NumberingScheme::unpackLayerIndex(rn0,zside);
435  int orient = FP420NumberingScheme::unpackOrientation(rn0,zside);
436  std::cout << "****DigitizerFP420:check2" << std::endl;
437  // std::cout <<" iu = " << iu <<" sector = " << sector <<" zmodule = " << zmodule <<" zside = " << zside << " det=" << det << std::endl;
438  // std::cout <<" layer = " << layer <<" orient = " << orient << std::endl;
439  int newdet, newzside, newsector, newzmodule;
440  FP420NumberingScheme::unpackMYIndex(iu, rn0, pn0, sn0, newdet, newzside, newsector, newzmodule);
441  std::cout <<" newdet = " << newdet <<" newsector = " << newsector <<" newzmodule = " << newzmodule <<" newzside = " << newzside << std::endl;
442 
443  collector.clear();
444  DigiCollectionFP420::Range outputRange;
445  // outputRange = output->get(iu);
446  outputRange = output->get(iu);
447 
448  // fill output in collector vector (for may be sorting? or other checks)
449  std::vector<HDigiFP420> collector;
450  // collector.clear();
451  DigiCollectionFP420::ContainerIterator sort_begin = outputRange.first;
452  DigiCollectionFP420::ContainerIterator sort_end = outputRange.second;
453  for ( ;sort_begin != sort_end; ++sort_begin ) {
454  collector.push_back(*sort_begin);
455  } // for
456  // std::sort(collector.begin(),collector.end());
457  std::cout <<" ===" << std::endl;
458  std::cout <<"====== collector size = " << collector.size() << std::endl;
459  if(collector.size()>0) {
460  std::cout <<" iu = " << iu <<" sector = " << sector <<" zmodule = " << zmodule <<" zside = " << zside << " det=" << det <<" layer = " << layer <<" orient = " << orient << std::endl;
461  std::cout <<" ===" << std::endl;
462  }
463  vector<HDigiFP420>::const_iterator simHitIter = collector.begin();
464  vector<HDigiFP420>::const_iterator simHitIterEnd = collector.end();
465  for (;simHitIter != simHitIterEnd; ++simHitIter) {
466  const HDigiFP420 istrip = *simHitIter;
467  std::cout << " strip number=" << istrip.strip() << " adc=" << istrip.adc() << std::endl;
468  std::cout <<" channel =" << istrip.channel() <<" V " << istrip.stripV() <<" VW " << istrip.stripVW() << std::endl;
469  std::cout <<" ===" << std::endl;
470  std::cout <<" ===" << std::endl;
471  std::cout <<" ===================================================" << std::endl;
472  }
473 
474  //==================================
475 
476  } // for
477  } // for
478  } // for
479  } // for
480 
481  // end of check of access to the strip collection
482 
483  }// if(verbosity
484  //
485 
486 
487  // Step D: write output to file
488  // iEvent.put(output);
489 
490  if(verbosity>0) {
491  std::cout << "DigitizerFP420 recoutput" << std::endl;
492  }
493  // Step D: write output to file
494  iEvent.put(output);
495  // iEvent.put(outputlink);
496  // iEvent.put(pDigis);
497 
498  // Step D: write output to file
499  // iEvent.put(output);
500  // iEvent.put(outputlink);
501  //-------------------------------------------------------------------
502  // std::cout << "DigitizerFP420 recoutput" << std::endl;
503  // iEvent.put(pDigis);
504 
505 
506 
507 
508  }//produce
int channel() const
Definition: HDigiFP420.h:22
int i
Definition: DBlmapReader.cc:9
inputRange
Get input source.
FP420DigiMain * stripDigitizer_
int stripVW() const
Definition: HDigiFP420.h:24
std::vector< HDigiFP420 >::const_iterator ContainerIterator
static void unpackFP420Index(const unsigned int &idx, int &det, int &zside, int &station, int &superplane)
int zside(DetId const &)
static int unpackLayerIndex(int rn0, int zside)
std::vector< HDigiFP420 > collector
static void unpackMYIndex(const int &idx, int rn0, int pn0, int sn0, int &det, int &zside, int &sector, int &zmodule)
std::vector< HDigiFP420 > run(const std::vector< PSimHit > &input, const G4ThreeVector &, unsigned int)
int strip() const
Definition: HDigiFP420.h:20
int iEvent
Definition: GenABIO.cc:230
static unsigned packMYIndex(int rn0, int pn0, int sn0, int det, int zside, int sector, int zmodule)
int adc() const
Definition: HDigiFP420.h:21
static unsigned int packFP420Index(int det, int zside, int station, int superplane)
std::pair< ContainerIterator, ContainerIterator > Range
tuple cout
Definition: gather_cfg.py:121
static int unpackOrientation(int rn0, int zside)
unsigned int detUnitId() const
Definition: PSimHit.h:93
int stripV() const
Definition: HDigiFP420.h:26

Member Data Documentation

std::vector<HDigiFP420> cms::DigitizerFP420::collector
private

Definition at line 78 of file DigitizerFP420.h.

Referenced by produce().

edm::ParameterSet cms::DigitizerFP420::conf_
private

Definition at line 66 of file DigitizerFP420.h.

Referenced by DigitizerFP420().

int cms::DigitizerFP420::dn0
private

Definition at line 75 of file DigitizerFP420.h.

Referenced by DigitizerFP420(), and produce().

int cms::DigitizerFP420::numStrips
private

Definition at line 73 of file DigitizerFP420.h.

int cms::DigitizerFP420::pn0
private

Definition at line 75 of file DigitizerFP420.h.

Referenced by DigitizerFP420(), and produce().

int cms::DigitizerFP420::rn0
private

Definition at line 75 of file DigitizerFP420.h.

Referenced by DigitizerFP420(), and produce().

simhit_map cms::DigitizerFP420::SimHitMap
private

Definition at line 64 of file DigitizerFP420.h.

Referenced by produce().

int cms::DigitizerFP420::sn0
private

Definition at line 75 of file DigitizerFP420.h.

Referenced by DigitizerFP420(), and produce().

FP420DigiMain* cms::DigitizerFP420::stripDigitizer_
private

Definition at line 71 of file DigitizerFP420.h.

Referenced by produce(), and ~DigitizerFP420().

vstring cms::DigitizerFP420::trackerContainers
private

Definition at line 67 of file DigitizerFP420.h.

Referenced by DigitizerFP420(), and produce().

int cms::DigitizerFP420::verbosity
private

Definition at line 75 of file DigitizerFP420.h.

Referenced by DigitizerFP420(), produce(), and ~DigitizerFP420().