RReader and spectator variables

Dear experts,

I use the experimental RReader function to compactly evaluate a TMVA xml file in an RDataFrame based framework.
Is there a recommended way of using “spectator variables” in the RReader?

The following declaration :
ROOT.TMVA.Experimental.RReader(model.xml)
crashes with the error below:
: Dataset[Default] : You declared 0 spectators in the Reader while there are 1 spectators declared in the file

I am aware of the TTree based methods where one explicitly declares a spectator variable, but would not want to roll back to explicitly looping over events for the purposes of TMVA evaluation.

Thanks in advance for your help and happy holidays!

@moneta will most probably able to help you once back from vacation

thanks, looking forward to it!

Hi there,

Sorry for the late reply!

Unfortunately, the TMVA::RReader does not support spectator variables and apparently also does not neglect if they are defined. Feel free to open an issue here!

A short term solution is simply removing the spectators from the xml file, or training without any spectators.

Best
Stefan

1 Like

Created issue #7900 and submitted PR #7899.

1 Like

Thank you !