Variable usage statistics

Last update: 03 Apr 2019 [History] [Edit]

If you would like to know how often each of the variables inside the xAOD are accessed by your analysis code, you can simply add the following lines to your steering macro (ATestRun_eljob.cxx) after you have defined the EL::Job object:

  // print to screen information about xAOD variables used 
  job.options()->setDouble (EL::Job::optXAODPerfStats, 1);
  job.options()->setDouble (EL::Job::optPrintPerFileStats, 1);

When you run the code you will get a long print out listing all the variables inside the xAOD and how many times you’ve accessed each of them. You probably don’t want to run this by default, but it might be useful if you are trying to determine which variables to save to a derived xAOD.

Athena users who are using any of the xAOD read modes (ClassAccess, BranchAccess, or AthenaAccess) can also print this information by adding the following to their job options (see main athena tutorial for more info):

#Add this line in joboptions after specifying the AccessMode property
svcMgr.EventSelector.PrintPerfStats = True