/
githubmirror
/
cmssw
Обзор
Документация
Войти
/
githubmirror
/
cmssw
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
CommonTools/MVAUtils/interface/TMVAZipReader.h
42 строки
1 KB
Jonas Rembser
clang-format CommonTools_MVAUtils
25 апр 2019, 03:35
25 апр 2019, 03:35
3c6606f
Код
Авторство
О чём код?
/* * ===================================================================================== * * Filename: TMVAZipReader.h * * Description: A stupid function that initializes a TMVA Reader * using a gzipped or non-zipped xml file. * * The file will be unzipped if it ends in .gz or .gzip * It will be passed as normal if it ends in .xml * * This file is header-only. * * Usage: loadTMVAWeights(&myReader, "BDT", "path_to_file.xml.gz"); * * * Author: Evan Friis, evan.friis@cern.ch * Company: UW Madison * * ===================================================================================== */ #ifndef CommonTools_MVAUtils_TMVAZipReader_h #define CommonTools_MVAUtils_TMVAZipReader_h #include "TMVA/IMethod.h" #include "TMVA/Reader.h" #include <string> namespace reco::details { bool hasEnding(std::string const& fullString, std::string const& ending); char* readGzipFile(const std::string& weightFile); TMVA::IMethod* loadTMVAWeights(TMVA::Reader* reader, const std::string& method, const std::string& weightFile, bool verbose = false); } // namespace reco::details #endif