Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:01:05

0001 #ifndef CommonTools_MVAUtils_GBRForestTools_h
0002 #define CommonTools_MVAUtils_GBRForestTools_h
0003 
0004 //--------------------------------------------------------------------------------------------------
0005 //
0006 // GRBForestTools
0007 //
0008 // Utility to parse an XML weights files specifying an ensemble of decision trees into a GRBForest.
0009 //
0010 // Author: Jonas Rembser
0011 //--------------------------------------------------------------------------------------------------
0012 
0013 #include "CondFormats/GBRForest/interface/GBRForest.h"
0014 #include "FWCore/ParameterSet/interface/FileInPath.h"
0015 
0016 #include <memory>
0017 
0018 // Create a GBRForest from an XML weight file
0019 std::unique_ptr<const GBRForest> createGBRForest(const std::string &weightsFile);
0020 std::unique_ptr<const GBRForest> createGBRForest(const edm::FileInPath &weightsFile);
0021 
0022 // Overloaded versions which are taking string vectors by reference to strore the variable names in
0023 std::unique_ptr<const GBRForest> createGBRForest(const std::string &weightsFile, std::vector<std::string> &varNames);
0024 std::unique_ptr<const GBRForest> createGBRForest(const edm::FileInPath &weightsFile,
0025                                                  std::vector<std::string> &varNames);
0026 
0027 #endif