![]() |
Belle II Software development
|
Public Member Functions | |
| __init__ (self, List[Tuple[str]] variables, Union[str, pathlib.PurePath] rootfile, description="") | |
| initialize (self) | |
| terminate (self) | |
Protected Attributes | |
| _variables = variables | |
| Remember the metadata. | |
| str | _rootfile = rootfile |
| And the name of the root file. | |
| _description = description | |
| Common description/information of/about all plots in this ROOT file (will be displayed above the plots) | |
| ROOT.TFile | _tfile = None |
| Shared pointer to the root file that will be closed when the last user disconnects. | |
Simple module to set the valdiation metadata for a given list of objects
automatically at the end of event processing
Just add this module **before** any
VariablesToNtuple/VariablesToHistogram modules and it will set the
correct validation metadata at the end of processing
Warning:
The module needs to be before the modules creating the objects
as terminate() functions are executed in reverse order from last to
first module. If this module is after the creation modules the metadata
might not be set correctly
Definition at line 191 of file metadata.py.
| __init__ | ( | self, | |
| List[Tuple[str]] | variables, | ||
| Union[str, pathlib.PurePath] | rootfile, | ||
| description = "" ) |
Initialize ValidationMetadataSetter
Arguments:
variables (list(tuple(str))): List of objects to set the metadata
for. Each entry should be the name of an object followed by the
metadata values which will be forwarded to
`validation_metadata_set`:
``(name, title, contact, description, check, xlabel, ylabel,
metaoptions)``
where ``xlabel``, ``ylabel`` and ``metaoptions`` are optional
rootfile (str or pathlib.PurePath): The name of the ROOT file where
the objects can be found
description (str): Common description/information of/about all plots
in this ROOT file (will be displayed above the plots)
Definition at line 207 of file metadata.py.
| initialize | ( | self | ) |
Make sure we keep the file open
Definition at line 243 of file metadata.py.
| terminate | ( | self | ) |
And update the metadata at the end
Definition at line 249 of file metadata.py.
|
protected |
Common description/information of/about all plots in this ROOT file (will be displayed above the plots)
Definition at line 238 of file metadata.py.
|
protected |
And the name of the root file.
Definition at line 235 of file metadata.py.
|
protected |
Shared pointer to the root file that will be closed when the last user disconnects.
Definition at line 241 of file metadata.py.
|
protected |
Remember the metadata.
Definition at line 231 of file metadata.py.