Hi all,
I’m trying to analyze cluster size (from PixelHit) and collected/deposited energy (from PixelCharge) for an ALPIDE-like detector. The ROOT file contains the trees and branches I expect, but I get a segfault when I run my script analyze_allpix.C.
$ root -l root_data_set.root
root [0]
Attaching file root_data_set.root as _file0…
Warning in TClass::Init: no dictionary for class allpix::MCParticle is available
Warning in TClass::Init: no dictionary for class allpix::Object is available
Warning in TClass::Init: no dictionary for class allpix::Object::PointerWrapperallpix::MCParticle is available
Warning in TClass::Init: no dictionary for class allpix::Object::BaseWrapperallpix::MCParticle is available
Warning in TClass::Init: no dictionary for class allpix::Object::PointerWrapperallpix::MCTrack is available
Warning in TClass::Init: no dictionary for class allpix::Object::BaseWrapperallpix::MCTrack is available
Warning in TClass::Init: no dictionary for class allpix::MCTrack is available
Warning in TClass::Init: no dictionary for class allpix::PixelCharge is available
Warning in TClass::Init: no dictionary for class allpix::Pixel is available
Warning in TClass::Init: no dictionary for class allpix::Pulse is available
Warning in TClass::Init: no dictionary for class allpix::Object::PointerWrapperallpix::PropagatedCharge is available
Warning in TClass::Init: no dictionary for class allpix::Object::BaseWrapperallpix::PropagatedCharge is available
Warning in TClass::Init: no dictionary for class allpix::PixelHit is available
Warning in TClass::Init: no dictionary for class allpix::Object::PointerWrapperallpix::PixelCharge is available
Warning in TClass::Init: no dictionary for class allpix::Object::BaseWrapperallpix::PixelCharge is available
Warning in TClass::Init: no dictionary for class allpix::Object::PointerWrapperallpix::PixelPulse is available
Warning in TClass::Init: no dictionary for class allpix::Object::BaseWrapperallpix::PixelPulse is available
(TFile *) 0x5fe9795a6410root [1] .L ../../../lib/libAllpixObjects.so
root [2] .L analyze_allpix.C
Then when I run
root [4] analyze_allpix(“root_data_set.root”,“T0”)
[OK ] Opened: root_data_set.root
[.. ] Events (PixelHit) : 10
[.. ] Events (PixelCharge): 10
- event 0/10
*** Break *** segmentation violation
===========================================================
There was a crash.
This is the entire stack trace of all threads:#0 0x00007ef7162ea3ea in __GI___wait4 (pid=1033335, stat_loc=stat_loc
entry=0x7ffd21219b58, options=options
entry=0, usage=usage
entry=0x0) at ../sysdeps/unix/sysv/linux/wait4.c:30
#1 0x00007ef7162ea3ab in __GI___waitpid (pid=, stat_loc=stat_loc
entry=0x7ffd21219b58, options=options
entry=0) at ./posix/waitpid.c:38
#2 0x00007ef716250bdb in do_system (line=) at ../sysdeps/posix/system.c:171
#3 0x00007ef716d16946 in TUnixSystem::StackTrace() () from /data/Abdul/root/root_install/lib/libCore.so
#4 0x00007ef716d13c25 in TUnixSystem::DispatchSignals(ESignals) () from /data/Abdul/root/root_install/lib/libCore.so
#5
#6 0x00007ef715d70780 in TEmulatedCollectionProxy::Shrink(unsigned int, unsigned int, bool) () from /data/Abdul/root/root_install/lib/libRIO.so
#7 0x00007ef715d72ea9 in TEmulatedCollectionProxy::ReadBuffer(TBuffer&, void*) () from /data/Abdul/root/root_install/lib/libRIO.so
#8 0x00007ef715d14281 in TBufferFile::ReadFastArray(void*, TClass const*, int, TMemberStreamer*, TClass const*) () from /data/Abdul/root/root_install/lib/libRIO.so
#9 0x00007ef715f10a6a in int TStreamerInfoActions::ReadSTL<&TStreamerInfoActions::ReadSTLMemberWiseSameClass, &TStreamerInfoActions::ReadSTLObjectWiseFastArray>(TBuffer&, void*, TStreamerInfoActions::TConfiguration const*) () from /data/Abdul/root/root_install/lib/libRIO.so
#10 0x00007ef715d132b5 in TBufferFile::ApplySequence(TStreamerInfoActions::TActionSequence const&, void*) () from /data/Abdul/root/root_install/lib/libRIO.so
#11 0x00007ef6fbd0be0e in TBranchElement::ReadLeavesMember(TBuffer&) () from /data/Abdul/root/root_install/lib/libTree.so
#12 0x00007ef6fbd03cb0 in TBranch::GetEntry(long long, int) () from /data/Abdul/root/root_install/lib/libTree.so
#13 0x00007ef6fbd1a1a8 in TBranchElement::GetEntry(long long, int) () from /data/Abdul/root/root_install/lib/libTree.so
#14 0x00007ef6fbd7de98 in TTree::GetEntry(long long, int) () from /data/Abdul/root/root_install/lib/libTree.so
#15 0x00007ef7161c5c2f in ?? ()
#16 0x0000000000000002 in ?? ()
#17 0x00005fe978328e00 in ?? ()
#18 0x00007ffd2121d3b0 in ?? ()
#19 0x00007ffd2121d490 in ?? ()
#20 0x00007ffd2121d390 in ?? ()
#21 0x00007ef7162a5453 in __GI___libc_free (mem=) at ./malloc/malloc.c:3391
#22 0x00007ef711422b89 in llvm::orc::InProgressFullLookupState::complete(std::unique_ptr<llvm::orc::InProgressLookupState, std::default_deletellvm::orc::InProgressLookupState >) () from /data/Abdul/root/root_install/lib/libCling.so
#23 0x00007ef71140ca9f in llvm::orc::ExecutionSession::OL_applyQueryPhase1(std::unique_ptr<llvm::orc::InProgressLookupState, std::default_deletellvm::orc::InProgressLookupState >, llvm::Error) () from /data/Abdul/root/root_install/lib/libCling.so
#24 0x00005fe97e2118d0 in ?? ()
#25 0x00005fe97e7687b8 in ?? ()
#26 0x00007ef7161c16a0 in ?? ()
#27 0x00007ef7161c1690 in ?? ()
#28 0x00005fe97e75dbb8 in ?? ()
#29 0x00007ef7161c1650 in ?? ()
#30 0x00007ef7161c1630 in ?? ()
#31 0x00007ef7161c6e00 in ?? ()
#32 0x00007ef7161c6de0 in ?? ()
#33 0x00005fe97e769bb0 in ?? ()
#34 0x00007ef7161c6d80 in ?? ()
#35 0x00007ef7161c6d60 in ?? ()
#36 0x00007ef7161c6cd0 in ?? ()
#37 0x00007ef7166d1850 in ?? () from /usr/lib/x86_64-linux-gnu/libstdc++.so.6
#38 0x00007ef7161c6b60 in ?? ()
#39 0x00005fe97c3f0150 in ?? ()
#40 0x00007ef7161c137e in ?? ()
#41 0x00007ef7161c1529 in ?? ()
#42 0x00007ef7161c151e in ?? ()
#43 0x00007ef716829540 in ?? () from /usr/lib/x86_64-linux-gnu/libstdc++.so.6
#44 0x028f5c28f5c28f5c in ?? ()
#45 0x8f5c28f5c28f5c29 in ?? ()
#46 0x00007ffd2121d5c8 in ?? ()
#47 0x0000000000000000 in ?? ()The lines below might hint at the cause of the crash. If you see question
marks as part of the stack trace, try to recompile with debugging information
enabled and export CLING_DEBUG=1 environment variable before running.
You may get help by asking at the ROOT forum https://root.cern/forum
preferably using the command (.forum bug) in the ROOT prompt.
Only if you are really convinced it is a bug in ROOT then please submit a
report at https://root.cern/bugs or (preferably) using the command (.gh bug) in
the ROOT prompt. Please post the ENTIRE stack trace
from above as an attachment in addition to anything else
that might help us fixing this issue.
strong text
and this is my analyze_allpix.C code:
analyze_apx.C.txt (7.0 KB)
I’m trying to debug it. This looks like a dictionary mismatch?
Can anyone help me with how to fix it?
Thanks.