GSI Forum - RDF feed
type: channel
description: GSI Helmholtzzentrum für Schwerionenforschung
items: How to write Macros with newest trunk code
items: Re: How to write Macros with newest trunk code

How to write Macros with newest trunk code
type: item
description: Hello, I updated to the newest FairRoot (17.03) and pandaroot code (trunk), and cannot get the lmd macros to work (or also the macros in macro/run). Our lmd macros seem not to be compatible with the current development trunk as the all create double free corruption errors. Is there any macros that should work and have been tested with this development setup? Then I have some guideline on how to steer the whole simulation and reconstruction chain and adapt our macros to the new FairRoot. Thanks in advance Stefan
creator: Stefan Pflueger
date: 2017-09-14T16:11:39-00:00

Re: How to write Macros with newest trunk code
type: item
description: Hallo Stefan, Just to be clear on your setup: Did you install FairSoft may16p1 FairRoot v-17.03 PandaRoot trunk ROOT version 6 ? The macros in macro/run are phasing out. Please go on in macro/master for the default configuration. I know there is a double free message upon quitting root 6, which should not harm the calculations. Other than that, some error message log would be helpful. Cheers! Ralf
creator: Ralf Kliemt
date: 2017-09-15T07:23:04-00:00

Re: How to write Macros with newest trunk code
type: item
description: Hi Ralf, yes exactly that's my configuration. I should add that i used gcc 6.4.0. So everyone gets the double free error messages at the end of the macro runtime? I almost assume so... Because it crashes at the end of the runtime, the macros should still deliver valid output like you said. Strangely most of the output files for the lmd reconstruction chain are empty. I will investigate further today and compare our lmd macros with the master ones. Maybe some change in fairroot etc is not implemented correctly in our lmd macro code up to now. Nevertheless if everyone using root6 and the trunk code of pandaroot gets these double free issues, its quite embarrassing to me... Because it is a double free at the end of the runtime done by the root "garbage collector", it is also a bit hard to debug that. But I checked some of the code yesterday and there are a lot of delete statements in the code, which could be responsible for this kind of thing. I will post the output later, however I don't think it will be of much help. Stefan
creator: Stefan Pflueger
date: 2017-09-15T07:54:21-00:00

Re: How to write Macros with newest trunk code
type: item
description: Dear Stefan, the reason for the double free error is well known. It is a problem inside root. We can bypass it but it should be fixed inside root which has not happened up to now. If this is causing a problem I can fix it in PandaRoot. Cheers, Tobias
creator: Tobias Stockmanns
date: 2017-09-15T08:11:07-00:00

Re: How to write Macros with newest trunk code
type: item
description: Hi Ralf, here is the stacktrace as promised #5 0x00002af63f04f7ec in TObjArray::Delete(char const*) () from /software/fairsoft/fairsoft_may16p1_root6/lib/root/libCore.so.6.08 #6 0x00002af64405d01e in TGeoManager::~TGeoManager() () from /software/fairsoft/fairsoft_may16p1_root6/lib/root/libGeom.so.6.08 #7 0x00002af64405d239 in TGeoManager::~TGeoManager() () from /software/fairsoft/fairsoft_may16p1_root6/lib/root/libGeom.so.6.08 #8 0x00002af63f048445 in TList::Delete(char const*) () from /software/fairsoft/fairsoft_may16p1_root6/lib/root/libCore.so.6.08 #9 0x00002af63ef497b2 in TROOT::~TROOT() () from /software/fairsoft/fairsoft_may16p1_root6/lib/root/libCore.so.6.08 #10 0x0000003aeda35b22 in __run_exit_handlers (status=0) at exit.c:78 #11 exit (status=0) at exit.c:100 #12 0x0000003aeda1ed64 in __libc_start_main (main=0x402814 , argc=1, ubp_av=0x7fffe4463698, init=<value optimized out>, fini=<value optimized out>, rtld_fini=<value optimized out>, stack_end=0x7fffe4463688) at libc-start.c:258 #13 0x0000000000402059 in _start ()
creator: Stefan Pflueger
date: 2017-09-15T08:22:56-00:00

Re: How to write Macros with newest trunk code
type: item
description: Hi Tobias, hmm I'm not sure I understand correctly. So the root6 team knows there is a bug in their code and their working on it? In my opinion our code does a "non root conform" delete in some destructor that causes this problem. I will ignore the double free for now and try to get the lmd macros running again. Thanks for the information. Stefan
creator: Stefan Pflueger
date: 2017-09-15T08:38:42-00:00

Re: How to write Macros with newest trunk code
type: item
description: Hi Tobias, I think your statement is not 100% correct. We had a discussion with the ROOT developers since we think that the problem is due to ROOT. Their opinion is that the problem is inside our geometries. Up to now we have not been able to prove that the problem is not our geometry. To overcome the problem on can do the following steps at the end of the macro gGeoManager->GetListOfVolumes()->Delete(); gGeoManager->GetListOfShapes()->Delete(); delete gGeoManager; Ciao Florian
creator: Florian Uhlig
date: 2017-09-15T10:59:53-00:00

Re: How to write Macros with newest trunk code
type: item
description: Hi Florian, ok thx for the tip. I saw that reason that the lmd macros did not deliver any results was that the simulation macro did not generate geant hits in the lumi detector geometry. As if the lumi geometry is not seen by it. Below is the output log of the macro until geant start propagating particles. I stumbled across the line Error in <TGeoVoxelFinder::SortAll>: Volume lmd_vol_ref_sys: Cannot make slices on any axis Is that normal? Does anyone know if this is an error that can be ignored? Quote: [INFO ] Media file used: /home/pflueger/pandaroot/geometry/media_pnd.geo Info in (PndGeoHandling::Instance): Making a new instance using the framework. - I - PndLmdDetector: fListOfSensitives contains: LumActive Info in <TGeoManager::TGeoManager>: Geometry FAIRGeom, FAIR geometry created ************************************************************* initialisation for run id 1505472465 ************************************************************* -I- FairRunTimeDB::InitContainer() PndSensorNamePar [ERROR ] init() PndSensorNamePar not initialized Error in <FairRuntimeDb::initContainers()>: Error occured during initialization Loading Geant4 libraries (using geant4-config) ... 31 Loading VGM libraries ... Loading g4root library ... Loading geant4vmc library ... Loading mtroot library ... ============================================================= Geant4 Virtual Monte Carlo Version 3.3 ( 15 January 2016 ) WWW : http://root.cern.ch/drupal/content/geant4-vmc ============================================================= Info in <TGeoManager::SetTopVolume>: Top volume is cave. Master volume is cave Info in <TGeoNavigator::BuildCache>: --- Maximum geometry depth set to 100 PndPipe - Using geometry /home/pflueger/pandaroot/geometry/beampipe_201309.root Info in <TGeoManager::CheckGeometry>: Fixing runtime shapes... Info in <TGeoManager::CheckGeometry>: ...Nothing to fix Info in <TGeoManager::CloseGeometry>: Counting nodes... Info in <TGeoManager::Voxelize>: Voxelizing... Error …
creator: Stefan Pflueger
date: 2017-09-15T11:09:34-00:00

Re: How to write Macros with newest trunk code
type: item
description: Hi Florian, your code snippet indeed fixes the double free crash at the end of the macro. However the lmd uses a special backtracking task, more precisely FairGeane & FairGeaneApplication. I still get the same double free crash report in the geant3 initialization phase (see log below). It crashes in the Geant3 vmc InitMC() function. From the stack trace it looks like that the problem is the same as before, something inside the TGeoManager getting deleted again that was deleted before. Quote: *** glibc detected *** /software/fairsoft/fairsoft_may16p1_root6/bin/root.exe: double free or corruption (!prev): 0x00000000096bb140 *** ======= Backtrace: ========= /lib64/libc.so.6(+0x75f4e)[0x2b0192deff4e] /lib64/libc.so.6(+0x78cf0)[0x2b0192df2cf0] /software/fairsoft/fairsoft_may16p1_root6/lib/root/libCore.so.6.08(_ZN9T ObjArray6DeleteEPKc+0x10c)[0x2b0191f5c7ec] /software/fairsoft/fairsoft_may16p1_root6/lib/root/libGeom.so.6.08(_ZN11 TGeoManagerD1Ev+0x29e)[0x2b019fc6501e] /software/fairsoft/fairsoft_may16p1_root6/lib/root/libGeom.so.6.08(_ZN11 TGeoManagerD0Ev+0x9)[0x2b019fc65239] /software/fairsoft/fairsoft_may16p1_root6/lib/root/libCore.so.6.08(_ZN5T List6DeleteEPKc+0x205)[0x2b0191f55445] /software/fairsoft/fairsoft_may16p1_root6/lib/root/libCore.so.6.08(_ZN5T ROOT20EndOfProcessCleanupsEv+0x4c)[0x2b0191e57c8c] /lib64/libc.so.6(exit+0xe2)[0x2b0192dafb22] /software/fairsoft/fairsoft_may16p1_root6/lib/libgeant321.so(+0x2719de)[ 0x2b01b43639de] /software/fairsoft/fairsoft_may16p1_root6/lib/libgeant321.so(zabend_+0x3 f)[0x2b01b42eecaf] /software/fairsoft/fairsoft_may16p1_root6/lib/libgeant321.so(zfatal_+0x7 92)[0x2b01b42f3b42] /software/fairsoft/fairsoft_may16p1_root6/lib/libgeant321.so(mztabc_+0x2 1a)[0x2b01b42e4b7a] /software/fairsoft/fairsoft_may16p1_root6/lib/libgeant321.so(mztabr_+0x1 55)[0x2b01b42e1645] /software/fairsoft/fairsoft_may16p1_root6/lib/libgeant321.so(mzgar1_+0x2 10)[0x2b01b42f2480] /software/fairsoft/fairsoft_may16p1_root6/lib/libgeant321.so(mzlift_+0x3 df)[0x2…
creator: Stefan Pflueger
date: 2017-09-15T13:37:04-00:00