CMS 3D CMS Logo

List of all members | Public Member Functions | Public Attributes
edm::MixingCache::Config Struct Reference

#include <BMixingModule.h>

Public Member Functions

 Config (edm::ParameterSet const &pset, unsigned int maxNbSources)
 

Public Attributes

int bunchSpace_
 
bool configFromDB_ = false
 
std::vector< std::shared_ptr< PileUpConfig > > inputConfigs_
 
int maxBunch_
 
int minBunch_
 
bool playback_
 
std::vector< std::string > sourceNames_
 

Detailed Description

Definition at line 29 of file BMixingModule.h.

Constructor & Destructor Documentation

◆ Config()

edm::MixingCache::Config::Config ( edm::ParameterSet const &  pset,
unsigned int  maxNbSources 
)

Definition at line 212 of file BMixingModule.cc.

References configFromDB_, inputConfigs_, maxBunch_, minBunch_, playback_, muonDTDigis_cfi::pset, and sourceNames_.

213  : bunchSpace_(pset.getParameter<int>("bunchspace")),
214  minBunch_((pset.getParameter<int>("minBunch") * 25) / bunchSpace_),
215  maxBunch_((pset.getParameter<int>("maxBunch") * 25) / bunchSpace_),
216  playback_(pset.getUntrackedParameter<bool>("playback", false)) {
217  if (playback_) {
218  //this could be explicitly checked
219  LogInfo("MixingModule") << " ATTENTION:Mixing will be done in playback mode! \n"
220  << " ATTENTION:Mixing Configuration must be the same as for the original mixing!";
221  }
222 
223  // Just for debugging print out.
224  sourceNames_.push_back("input");
225  sourceNames_.push_back("cosmics");
226  sourceNames_.push_back("beamhalo_plus");
227  sourceNames_.push_back("beamhalo_minus");
228 
229  for (size_t makeIdx = 0; makeIdx < maxNbSources; makeIdx++) {
230  inputConfigs_.push_back(maybeConfigPileUp(pset, sourceNames_[makeIdx], minBunch_, maxBunch_, playback_));
231  }
232 
233  if (pset.exists("readDB"))
234  configFromDB_ = pset.getParameter<bool>("readDB");
235  }
std::vector< std::string > sourceNames_
Definition: BMixingModule.h:36
Log< level::Info, false > LogInfo
std::vector< std::shared_ptr< PileUpConfig > > inputConfigs_
Definition: BMixingModule.h:37

Member Data Documentation

◆ bunchSpace_

int edm::MixingCache::Config::bunchSpace_

Definition at line 31 of file BMixingModule.h.

◆ configFromDB_

bool edm::MixingCache::Config::configFromDB_ = false

Definition at line 35 of file BMixingModule.h.

Referenced by Config(), and edm::MixingModule::MixingModule().

◆ inputConfigs_

std::vector<std::shared_ptr<PileUpConfig> > edm::MixingCache::Config::inputConfigs_

Definition at line 37 of file BMixingModule.h.

Referenced by edm::BMixingModule::BMixingModule(), and Config().

◆ maxBunch_

int edm::MixingCache::Config::maxBunch_

Definition at line 33 of file BMixingModule.h.

Referenced by Config().

◆ minBunch_

int edm::MixingCache::Config::minBunch_

Definition at line 32 of file BMixingModule.h.

Referenced by Config().

◆ playback_

bool edm::MixingCache::Config::playback_

Definition at line 34 of file BMixingModule.h.

Referenced by Config().

◆ sourceNames_

std::vector<std::string> edm::MixingCache::Config::sourceNames_

Definition at line 36 of file BMixingModule.h.

Referenced by Config().