CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Member Functions | Public Attributes | Static Public Attributes
goodseedhelpers::HeavyObjectCache Struct Reference

Public Member Functions

 HeavyObjectCache (const edm::ParameterSet &conf)
 

Public Attributes

std::array< std::unique_ptr
< const GBRForest >
, kMaxWeights
gbr
 

Static Public Attributes

static constexpr unsigned int kMaxWeights = 9
 

Detailed Description

Definition at line 61 of file GoodSeedProducer.cc.

Constructor & Destructor Documentation

goodseedhelpers::HeavyObjectCache::HeavyObjectCache ( const edm::ParameterSet conf)

Definition at line 593 of file GoodSeedProducer.cc.

References createGBRForest(), gbr, edm::ParameterSet::getParameter(), edm::ParameterSet::getUntrackedParameter(), dqmiolumiharvest::j, and HLT_FULL_cff::weights.

593  {
594  // mvas
595  const bool useTmva = conf.getUntrackedParameter<bool>("UseTMVA", false);
596 
597  if (useTmva) {
598  std::array<edm::FileInPath, kMaxWeights> weights = {{edm::FileInPath(conf.getParameter<string>("Weights1")),
599  edm::FileInPath(conf.getParameter<string>("Weights2")),
600  edm::FileInPath(conf.getParameter<string>("Weights3")),
601  edm::FileInPath(conf.getParameter<string>("Weights4")),
602  edm::FileInPath(conf.getParameter<string>("Weights5")),
603  edm::FileInPath(conf.getParameter<string>("Weights6")),
604  edm::FileInPath(conf.getParameter<string>("Weights7")),
605  edm::FileInPath(conf.getParameter<string>("Weights8")),
606  edm::FileInPath(conf.getParameter<string>("Weights9"))}};
607 
608  for (UInt_t j = 0; j < gbr.size(); ++j) {
609  gbr[j] = createGBRForest(weights[j]);
610  }
611  }
612  }
T getUntrackedParameter(std::string const &, T const &) const
std::array< std::unique_ptr< const GBRForest >, kMaxWeights > gbr
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
std::unique_ptr< const GBRForest > createGBRForest(const std::string &weightsFile)

Member Data Documentation

std::array<std::unique_ptr<const GBRForest>, kMaxWeights> goodseedhelpers::HeavyObjectCache::gbr

Definition at line 64 of file GoodSeedProducer.cc.

Referenced by HeavyObjectCache().

constexpr unsigned int goodseedhelpers::HeavyObjectCache::kMaxWeights = 9
static

Definition at line 62 of file GoodSeedProducer.cc.