10 #include "TMVA/MethodBDT.h" 11 #include "TMVA/Reader.h" 19 std::vector<float>
output = {
67 if ( trk->dxy(spot) > 0. ) {
74 rho_ =
static_cast<float>(rho);
116 for (
auto&
name : conf.
getParameter< std::vector<std::string> >(
"ModelNames") )
118 names_.push_back(
name);
126 thresholds_.push_back(
thresh);
128 if ( names_.size() != models_.size() ) {
130 <<
"'ModelNames' size (" << names_.size()
131 <<
") != 'ModelWeights' size (" << models_.size()
134 if ( models_.size() != thresholds_.size() ) {
136 <<
"'ModelWeights' size (" << models_.size()
137 <<
") != 'ModelThresholds' size (" << thresholds_.size()
152 std::vector<std::string>::const_iterator iter =
std::find( names_.begin(),
155 if ( iter != names_.end() ) {
158 features.
set(ecal,hcal,rho,spot,ecalTools);
159 std::vector<float>
inputs = features.get();
160 float output = models_.at(index)->GetResponse( inputs.data() );
161 bool pass = output > thresholds_.at(index);
162 ecal.
setMVA(pass,output,index);
166 <<
"'Name given: '" << name
167 <<
"'. Check against configuration file.\n";
T getParameter(std::string const &) const
float ktf_ecal_cluster_r9_
bool isNonnull() const
Checks for non-null.
reco::TrackRef trackRef() const
float ktf_hcal_cluster_e_
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
float preid_trk_gsf_chiratio_
float ktf_ecal_cluster_covPhiPhi_
float ktf_ecal_cluster_covEtaPhi_
void setMVA(bool accepted, float mva, unsigned n=0)
std::vector< float > get()
void set(const reco::PreId &ecal, const reco::PreId &hcal, double rho, const reco::BeamSpot &spot, noZS::EcalClusterLazyTools &ecalTools)
float ktf_ecal_cluster_e_
float ktf_ecal_cluster_dphi_
HeavyObjectCache(const edm::ParameterSet &)
float ktf_ecal_cluster_e3x3_
float ktf_hcal_cluster_deta_
bool eval(const std::string &name, reco::PreId &ecal, reco::PreId &hcal, double rho, const reco::BeamSpot &spot, noZS::EcalClusterLazyTools &ecalTools) const
float ktf_ecal_cluster_covEtaEta_
float ktf_ecal_cluster_deta_
static TrackQuality qualityByName(const std::string &name)
float ktf_ecal_cluster_circularity_
PFClusterRef clusterRef() const
const std::vector< float > & geomMatching() const
Access methods.
float ktf_hcal_cluster_dphi_
float ktf_ecal_cluster_e5x5_