![]() |
Belle II Software
light-2303-iriomote
|
Wrapper class for some utility functions. More...
#include <Utility.h>
Static Public Member Functions | |
| static void | download (const std::string &identifier, const std::string &filename, int experiment=0, int run=0, int event=0) |
| Convenience function which downloads a given weightfile from the database. More... | |
| static void | upload (const std::string &filename, const std::string &identifier, int exp1=0, int run1=0, int exp2=-1, int run2=-1) |
| Convenience function which uploads a given weightfile to the database. More... | |
| static void | upload_array (const std::vector< std::string > &filenames, const std::string &identifier, int exp1=0, int run1=0, int exp2=-1, int run2=-1) |
| Convenience function which uploads an array of weightfiles to the database. More... | |
| static bool | available (const std::string &filename, int experiment=0, int run=0, int event=0) |
| Convenience function which checks if an experise is available. More... | |
| static void | extract (const std::string &filename, const std::string &directory) |
| Convenience function which extracts the expertise in a given weightfile into a temporary directory. More... | |
| static std::string | info (const std::string &filename) |
| Print information about the classifier stored in the given weightfile. More... | |
| static void | save_custom_weightfile (const GeneralOptions &general_options, const SpecificOptions &specific_options, const std::string &custom_weightfile, const std::string &output_identifier="") |
| Convenience function which saves a pre-existing weightfile in a mva package-compliant format. More... | |
| static void | teacher (const GeneralOptions &general_options, const SpecificOptions &specific_options, const MetaOptions &meta_options=MetaOptions()) |
| Convenience function which performs a training with the given options. More... | |
| static void | expert (const std::vector< std::string > &filenames, const std::vector< std::string > &datafiles, const std::string &treename, const std::string &outputfile, int experiment=0, int run=0, int event=0, bool copy_target=true) |
| Convenience function applies experts on given data. More... | |
| static std::unique_ptr< Belle2::MVA::Expert > | teacher_dataset (GeneralOptions general_options, const SpecificOptions &specific_options, Dataset &data) |
| Convenience function which performs a training on a dataset. More... | |
| static std::unique_ptr< Belle2::MVA::Expert > | teacher_splot (const GeneralOptions &general_options, const SpecificOptions &specific_options, const MetaOptions &meta_options) |
| Performs an splot training, convenience function. More... | |
| static std::unique_ptr< Belle2::MVA::Expert > | teacher_sideband_subtraction (const GeneralOptions &general_options, const SpecificOptions &specific_options, const MetaOptions &meta_options) |
| Performs a sideband subtraction training, convenience function. More... | |
| static std::unique_ptr< Belle2::MVA::Expert > | teacher_reweighting (const GeneralOptions &general_options, const SpecificOptions &specific_options, const MetaOptions &meta_options) |
| Performs a MC vs data pre-training and afterwards reweighted training, convenience function. More... | |
|
static |
Convenience function which checks if an experise is available.
| filename | filename or identifier of the expertise |
| experiment | current experiment |
| run | current run |
| event | current event |
Definition at line 125 of file Utility.cc.
|
static |
Convenience function which downloads a given weightfile from the database.
| identifier | identifier in the database |
| filename | of the weightfile |
| experiment | current experiment |
| run | current run |
| event | current event |
Definition at line 31 of file Utility.cc.
|
static |
Convenience function applies experts on given data.
| filenames | vector of filenames or database identifiers |
| datafiles | ROOT files containing the data |
| treename | treename of ROOT file |
| outputfile | name of the output ROOT file |
| experiment | number of the experiment |
| run | number of the run |
| event | number of the event |
| copy_target | define if the target variable should be copied, if no target is found, an exception will be raised |
Definition at line 137 of file Utility.cc.
|
static |
Convenience function which extracts the expertise in a given weightfile into a temporary directory.
| filename | of the weightfile |
| directory | temporary directory to use |
Definition at line 82 of file Utility.cc.
|
static |
Print information about the classifier stored in the given weightfile.
| filename | filename of the weightfile |
Definition at line 97 of file Utility.cc.
|
static |
Convenience function which saves a pre-existing weightfile in a mva package-compliant format.
| general_options | shared options |
| specific_options | method specific options |
| custom_weightfile | path to the pre-existing weightfile |
| output_identifier | an optional string to append to the output file name. By default the function overwrites the input file. |
Definition at line 231 of file Utility.cc.
|
static |
Convenience function which performs a training with the given options.
| general_options | shared options |
| specific_options | method specific options |
| meta_options | optional options |
Definition at line 252 of file Utility.cc.
|
static |
Convenience function which performs a training on a dataset.
| general_options | shared options |
| specific_options | method specific options |
| data | data to use |
Definition at line 281 of file Utility.cc.
|
static |
Performs a MC vs data pre-training and afterwards reweighted training, convenience function.
| general_options | shared options of all methods |
| specific_options | of the used mva method |
| meta_options | options defining the splot training |
Definition at line 423 of file Utility.cc.
|
static |
Performs a sideband subtraction training, convenience function.
| general_options | shared options of all methods |
| specific_options | of the used mva method |
| meta_options | optional options |
Definition at line 476 of file Utility.cc.
|
static |
Performs an splot training, convenience function.
| general_options | shared options of all methods |
| specific_options | of the used mva method |
| meta_options | optional options |
Definition at line 312 of file Utility.cc.
|
static |
Convenience function which uploads a given weightfile to the database.
| filename | of the weightfile |
| identifier | identifier in the database |
| exp1 | first valid experiment |
| run1 | first valid run |
| exp2 | last valid experiment |
| run2 | last valid run |
Definition at line 45 of file Utility.cc.
|
static |
Convenience function which uploads an array of weightfiles to the database.
| filenames | array of names of the weightfiles |
| identifier | identifier in the database |
| exp1 | first valid experiment |
| run1 | first valid run |
| exp2 | last valid experiment |
| run2 | last valid run |
Definition at line 60 of file Utility.cc.