You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Ownership Issue is Inducing Segfault in Example #1
I'm sure you've probably already noticed this, but currently there is an ownership issue between ROOT and Python in the WorkspaceBuilder.ipynb code that will cause a segfault after the Jupyter kernel is restarted or if you export the Notebooks to .py and then try to run them. As I have discovered in similar code that I am writing for my own project this can be fixed by telling Python to not take ownership of a ROOT.RooStats.HistFactory object by calling ROOT.SetOwnership(object_name, False) after object creation. For example, after the creation of the first Channel() object in the example section of WorkspaceBuilder.ipynb one would call
It seems that this issue hasn't come up in Builder.py module, as exporting the WorkspaceBuilder.ipynb to .py and commenting out everything except for the lines
does NOT result in a segfault and so everything is good to go. So this doesn't seem to be an issue for you in terms of deployment of the code you really care about. However, if you notice in the future that you're getting weird segfaults this may be the issue.
I think it's possibly related but not the same. Builder.py is built independently of WorkspaceBuilder.ipynb as a philosophical choice. I use notebooks to test algorithms but then refactor them to use in 'real' code. I never use the export to .py function in Jupyter.
I remember testing this as a possible solution to the 'too many files opened' problem but it didn't help.
Activity
egpbos commentedon Jul 4, 2017
@vincecr0ft could this also be related to the too many files opened problem?
vincecr0ft commentedon Jul 11, 2017
I think it's possibly related but not the same. Builder.py is built independently of WorkspaceBuilder.ipynb as a philosophical choice. I use notebooks to test algorithms but then refactor them to use in 'real' code. I never use the export to .py function in Jupyter.
I remember testing this as a possible solution to the 'too many files opened' problem but it didn't help.