Problem with GDML binding

Please help me to see the attached files: emcgeo.py and emctest1.py
Each time I run this script, I got the errors just like the attached emctest1.log
I have no idea to solve it. Please give me some hints!
emctest1.txt (7.15 KB)
emctest1.py (202 Bytes)
emcgeo.py (2.96 KB)

Please see the attached file: emctest2.py and emctest2.txt
emctest2.txt (11.5 KB)
emctest2.py (641 Bytes)

Hi,

not quite sure about all the details (sorry, I’m at a conference and about to give my talk :slight_smile: ), but it looks like an ownership issue. If you set ownership of the mgr to C++, like so:[code]if name == ‘main’:
mgr = createEMCGeo(160., 2, 3.5, 7.6, 100.)
top = mgr.GetTopVolume()

mgr.SetVisLevel(2)
ROOT.SetOwnership(mgr,False)      # <= add this line
top.Draw()[/code]

then the crash goes away (for me, anyway). What I don’t understand is why Python is owning mgr to begin with, and whether cleanup is still done properly once ownership has been relinquished.

HTH for now,
Wim