Hi all,
I ran into the exception thrown by the TryToJitExpression
function (https://root.cern.ch/doc/master/RDFInterfaceUtils_8cxx_source.html#l00531) when applying a filter action on variables with similar names. When using a define action to rename one of the variables, everything works fine.
I post the ouput of my script below, which illustrates the error. I hope this helps in debugging. If needed, I can make a small reproducer.
Cheers,
Marian
script without renaming variables (also note that I renamed the variable which didn’t raise the exception):
tree_trimmerRDF INFO: Applying Filter action: Xic_p_ProbNNp > 0.1 && ( abs(misID_DStar_M-145.4)>5.5 || (Xic_p_ProbNNpi < 0.4 && abs(KXicpXic_as_pi_M-1865.)>15) )
input_line_35:4:8: error: use of undeclared identifier 'Xic_p_ProbNNp'
return Xic_p_ProbNNp > 0.1 && ( abs(misID_DStar_M-145.4)>5.5 || (Xic_p_ProbNNpi < 0.4 && abs(KXicpXic_as_pi_M-1865.)>15) )
^
terminate called after throwing an instance of 'std::runtime_error'
what(): Cannot interpret the following expression:
Xic_p_ProbNNp > 0.1 && ( abs(misID_DStar_M-145.4)>5.5 || (Xic_p_ProbNNpi < 0.4 && abs(KXicpXic_as_pi_M-1865.)>15) )
Make sure it is valid C++.
Aborted (core dumped)
script with renamed variables:
tree_trimmerRDF DEBUG: transforming Xic_p_ProbNNpi to a new branch: blabla
tree_trimmerRDF INFO: Applying Filter action: Xic_p_ProbNNp > 0.1 && ( abs(misID_DStar_M-145.4)>5.5 || (blabla < 0.4 && abs(KXicpXic_as_pi_M-1865.)>15) )
tree_trimmerRDF INFO: [======== ] (16% - ETA: 112s - 1 thread)
ROOT Version: nightlies
Platform: x86_64-slc6-gcc8-opt
Compiler: g++ (GCC) 8.2.0