RooAbsReal::defaultEvalBackend(RooAbsReal::legacy); with ROOT 6.30/04

How to use RooAbsReal::defaultEvalBackend(RooAbsReal::legacy); with ROOT 6.30/04

Hello @liuwe,
welcome to the ROOT forum!
There is no RooAbsReal::defaultEvalBackend object in ROOT 6.30/04. Could you be more descriptive on what you want to do?

Cheers,
Monica

Do you mean this?

RooFit::EvalBackend::defaultValue() = RooFit::EvalBackend::Legacy;

This is how you set the default RooFit evaluation backend from ROOT 6.30 onward. However, using such global flags is not recommended, which is why they are not documented. We recommend to add RooFit::EvalBackend("legacy") to your calls to fitTo and createNLL, as explained in the docs for RooAbsPdf:
https://root.cern.ch/doc/master/classRooAbsPdf.html#a24b1afec4fd149e08967eac4285800de

However, setting the default to RooFit::EvalBackend::Legacy in 6.30 is redundant, because the “default default” only changed to RooFit::EvalBackend::Cpu in 6.32.

May I ask why you’re not using 6.32? The new CPU backend can give great speedups, and in 6.32 many of its remaining bugs were ironed out.

If there is still something that doesn’t work with the new CPU backend but does work with the legacy backend, please report it in an GitHub issue, including a reproducer:

Cheers,
Jonas

Hi Moncia,
I’m having some issues. My current code is based on root5, but now CERN’s data needs root6.30 or above to open, I want to use root6.30 to open the root file to get the data, but some functions in the program can use root5.

Cheers,
weijie

Hi jonas,
Thank you for your help, I’m going to try. I’m having some issues. My current code is based on root5, but now CERN’s data needs root6.30 or above to open, I want to use root6.30 to open the root file to get the data, but some functions in the program can use root5. Do you have any suggestions?

Cheers,
Weijie

I don’t think you need ROOT 6.30 or above to read data, even though the ROOT version you’re using is quite old (ROOT6 has been released 10 years ago). You have two ways to proceed: upgrade to a more recent ROOT release (and change your code consequently) or read your data in ROOT5.


I don’t know why I can’t open this root file with root5.

Can you verify that you are able to read the file in any recent release of ROOT? You can simply download the binaries to check it

Hi @liuwe, your follow up question on opening this old ROOT file has nothing to do with the original RooFit question :slight_smile: It would be better if you open a new thread for this problem in particular, so that the ROOT file experts can pick it up.

Cheers,
Jonas

ok, thank you for your help!


yes, the root6.30 can open this root file. so, what do binaries mean? i don’t where to find it.

I mean the root6 binaries, but it’s unnecessary as you already have an installation… Following Jonas suggesting, please open a new thread so we can redirect you to our IO expert!

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.