Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Review implicit usage of ROOT globals in TTree handling #93

Closed
hegner opened this issue May 29, 2020 · 2 comments
Closed

Review implicit usage of ROOT globals in TTree handling #93

hegner opened this issue May 29, 2020 · 2 comments

Comments

@hegner
Copy link
Collaborator

hegner commented May 29, 2020

There are quite a few calls to ROOT relying on global states like creating TTrees implicitly within the current gDirectory. Would it make sense to be more explicit in these calls?

@tmadlener
Copy link
Collaborator

I am adding the proposal of a general review of the internals of the ROOTReader here as well. Currently the handling of switching files in the events TChain is not handled properly everywhere, (see e.g. #132). it might be worthwhile to check whether it is possible to do only once per event and keep track of which "local" event is currently being read.

@tmadlener
Copy link
Collaborator

This is handled properly for Frame writing (introduced in #287). See, e.g.:

catInfo.tree = new TTree(category.c_str(), (category + " data tree").c_str());
catInfo.tree->SetDirectory(m_file.get());

Closing this since the ROOTReader will eventually be deprecated (before v1.0)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants