Currently, this code also looks for generator information in the data, which is not there. Need to fix.
More information
In data, we don't have generator-level information.
If you pick a data root file and try to run. Then, the code will try to find the generator-level information in the data root file, which is not there. And then it will, through error, say that no branch exists.
Currently, this code also looks for generator information in the data, which is not there. Need to fix.
More information
In data, we don't have generator-level information.
If you pick a data root file and try to run. Then, the code will try to find the generator-level information in the data root file, which is not there. And then it will, through error, say that no branch exists.
Possible solution
Utilize the variable
isMCTrueFalse
defined in post-proc (its better to rename isMCTrueFalse -> isMC): https://github.com/ram1123/nanoAOD_skim/blob/7e7653dc68018f2cb5a7d4fb7e6c843fe19f7ae3/post_proc.py#L40and pass it to module
HZZAnalysisCppProducer
. Furthermore it would be good if it does this automatically. It can be achieved like:Then use this to skip all gen related part. something like this: