Problems when rebinning GATE root file

Hi ROOT users,

I am new to use ROOT. I try to rebin the root file from Gate into sinograms based on the code in http://www.opengatecollaboration.org/sites/default/files/Bin_GATE_v1.0.c

(1) Compile using this command line: g++ (name of file) root-config --cflags --libs
(2) run the command: ./a.out ‘directory name of root files’ ‘output file name’

When I run the command I get the following errors:

Total Number of Coincidence Events:= 343

*** Break *** segmentation violation
#0 0x00007f7044beea3c in waitpid () from /usr/lib64/libc.so.6
#1 0x00007f7044b6cde2 in do_system () from /usr/lib64/libc.so.6
#2 0x00007f704963a794 in TUnixSystem::StackTrace() () from /big_software/Gate/ROOT/root/lib/libCore.so
#3 0x00007f704963cecc in TUnixSystem::DispatchSignals(ESignals) () from /big_software/Gate/ROOT/root/lib/libCore.so
#4
#5 0x00000000004028f9 in main ()

I thought it can read the input root file because it prints the total coincidences events.
But is there anything wrong with the code or the root setting?

Thanks in advance!
Dawn

ROOT Version: Root6
Platform: Unix
Compiler: g++


The crash ‘seems’ to be located in Bin_GATE_v1.0.c, to see better what the problem is try with:

g++ (name of file) -O0 -g3 `root-config --cflags --libs`

Cheers,
Philippe.

Yes, the problem is in the code since I have changed some parameters to fit for my own scanner.
I have figured out the mistake. Thanks a lot!!!

All the best,
Dawn

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.