|
HighLAND
|
#include <AnalysisLoop.hxx>
Public Member Functions | |
| AnalysisLoop (AnalysisAlgorithm *ana, int argc, char *argv[]) | |
| Constructor which parses and sanity checks the command line options. | |
| void | Loop (int nmax=0, int imin=0) |
| void | Execute () |
| void | SetEvent (AnaEventC *event) |
Protected Member Functions | |
| bool | Initialize () |
| void | Finalize () |
| bool | InitializeSpill () |
| void | FinalizeSpill () |
| void | InitializeBunch () |
| void | FinalizeBunch () |
| void | InitializeConfiguration () |
| bool | FinalizeConfiguration () |
| void | InitializeToy () |
| bool | FinalizeToy () |
| Called after each toy experiment is complete. | |
| void | InitializeSelection (const SelectionBase &sel) |
| void | FinalizeSelection (const SelectionBase &sel) |
| bool | Process (SelectionBase &selec) |
| void | DefineCorrections () |
| Define the corrections to be applied. | |
| void | DefineConfigurations () |
| Define the configurations (micro-trees) and which systematics should be applied in each "configuration". | |
| void | DefineMicroTrees () |
| Define the variables that should be stored in the output micro-trees. | |
| void | DefineTruthTree () |
| Define the "truth" tree. See FillTruthTree(). | |
| void | FillCategories () |
| void | FillMicroTrees () |
| Fill the standard configurations trees: More... | |
| void | FillToyVarsInMicroTrees () |
| Fill the standard configurations only toy-dependent variables. | |
| void | PrintUsage (const std::string &programName) |
More... | |
| AnalysisAlgorithm & | ana () |
| void | FillHeaderTree () |
| Fill the "header" tree, which includes POT information etc. | |
| void | FillConfigTree () |
| Fill the "config" tree, which includes details of the analysis cuts etc. | |
Protected Attributes | |
| Long64_t | _entry |
| Fill the "truth" tree. More... | |
| std::string | _inputFileName |
| Path to the input file, as defined by the user. | |
| std::string | _inputFileType |
| std::string | _outputFileName |
| What to call the output file, as defined by the user. | |
| std::string | _inputSkimFileName |
| Path to the file with the list of events to skim, as defined by the user. | |
| bool | _enableTruthTree |
| Whether the "truth" tree should be filled. See FillTruthTree(). | |
| bool | _cosmicMode |
| bool | _versionCheck |
| Check version compatibility between nd280AnalysisTools compilation and oaAnalysis file. | |
| bool | _fillTrees |
| Whether to fill the trees and create an output file or not. | |
| MemoryUsage | _memory |
| Tools for tracking memory usage. | |
| AnaEventC * | _event |
This class is a base class for analyses.
It specifies the interface that analyses should conform to, although user analyses should inherit from baseAnalysis, not AnalysisLoop directly. baseAnalysis implements all the required functions, so the user doesn't have to implement all the functions themselves.
The class also contains the low-level functionality for running the analysis, including the all-important Loop function.
Definition at line 17 of file AnalysisLoop.hxx.
| void AnalysisLoop::Execute | ( | ) |
Simply calls Loop with the appropriate parameters as read from the command line.
Definition at line 1333 of file AnalysisLoop.cxx.
|
protected |
Fill the track categories for color drawing. There is a definition in baseAnalysis, and the user can specify their own if they have defined their own custom categories.
|
protected |
Fill the standard configurations trees:
Fill the truth tree. The truth tree is designed to contain information about all true signal events, including those that the analysis didn't select as signal.
The derived version should fill the relevant variables, and return whether the tree should be written or not. The derived function is only called once per spill!
Definition at line 1173 of file AnalysisLoop.cxx.
|
protected |
Called after all processing is complete. Cleans up, then writes to and closes the output file.
Definition at line 500 of file AnalysisLoop.cxx.
|
protected |
Called after each bunch is finished, simply calling the user's derived version.
Definition at line 449 of file AnalysisLoop.cxx.
|
protected |
Fill the tree for this bunch, including the "truth" tree if it is enabled. The derived version should fill any variabled in the micro-tree that don't depend on the exact analysis.
Definition at line 409 of file AnalysisLoop.cxx.
|
protected |
Compute the weight for this selection by applying the systematic weights. Only for MC when any of the weight systematics is enabled,
Definition at line 357 of file AnalysisLoop.cxx.
|
protected |
Called after each spill is finished. Calls the user's derived version before deleting the current active Spill in the InputManager.
Definition at line 464 of file AnalysisLoop.cxx.
|
protected |
Initialize the entire analysis. Calls the Initialize() function in the user's derived class as part of the initialization.
Definition at line 152 of file AnalysisLoop.cxx.
|
protected |
Initialize each bunch of each spill, simply calling the user's derived version.
Definition at line 273 of file AnalysisLoop.cxx.
|
protected |
Initialize each configuration for each bunch. The current active configuration should already have been changed by Loop().
Definition at line 289 of file AnalysisLoop.cxx.
|
protected |
Initialize each spill, including reading it from the input file, and applying any corrections specified by the user. Calls the user's derived version after applying the corrections.
Definition at line 226 of file AnalysisLoop.cxx.
|
protected |
Initialize each toy experiment for each configuration, including applying any systematic variations. The user's derived version is called after variations have been applied.
Definition at line 329 of file AnalysisLoop.cxx.
| void AnalysisLoop::Loop | ( | int | nmax = 0, |
| int | imin = 0 |
||
| ) |
This is the main looping function that controls the analysis. It initializes the analysis, then loops over
Definition at line 957 of file AnalysisLoop.cxx.
|
protected |
Simple usage statement, for if the user gave bad command line options.
Definition at line 1315 of file AnalysisLoop.cxx.
|
protected |
The main function called to run the analysis. The derived version should apply any cuts, and return whether the current active bunch passed the cuts or not.
Definition at line 1156 of file AnalysisLoop.cxx.
|
protected |
Whether to run in "cosmics" mode, where all the tracks are saved in a single bunch.
Definition at line 166 of file AnalysisLoop.hxx.
|
protected |
Fill the "truth" tree.
The number of entries we have read in.
Definition at line 146 of file AnalysisLoop.hxx.
|
protected |
This was used when the user could specify what type of input file they had provided. Now this is done automatically.
Definition at line 153 of file AnalysisLoop.hxx.
1.8.13