[Gate-users] Segmentation violation for water geometry
Matthew Strugari
matthew.strugari at dal.ca
Wed Jul 3 16:56:24 CEST 2019
Hi Konstantinos,
Interesting. How much ram would you suggest to be enough? I have 8 GB allotted to vGate with over 4 GB free at the time of running, and 16 GB on my full installation. I would imagine this should be plenty for generating a simple shape and water is the only material which produces this fault.
Adding "/gate/application/noGlobalOutput" to the end of the uploaded macro doesn't change anything for me.
M
________________________________
From: Konstantinos P. Chatzipapas, MSc <konhat88 at yahoo.gr>
Sent: July 3, 2019 8:38 AM
To: gate-users at lists.opengatecollaboration.org; Matthew Strugari
Cc: David Boersma
Subject: Re: [Gate-users] Segmentation violation for water geometry
Hello,
I tried that again, with all 3 geometries on, with just the capillary. 10 times for each, with viewer and no viewer. With qt and without. I can't see the segfault.
Either you don't have enough ram, or if you add anything more in the simulation, you sure missing this command: /gate/application/noGlobalOutput
When you don't have output.
Regards
-----------------------------------------------------
Konstantinos Chatzipapas
Medical Physicist, MSc
University of Patras
web page: Physics Magazine<http://www.physicsmag.com/>
Στις Τετάρτη, 3 Ιουλίου 2019, 04:57:19 μ.μ. EEST, ο χρήστης Matthew Strugari <matthew.strugari at dal.ca> έγραψε:
Hi Konstantinos,
As previously mentioned, when all three tested water geometries are uncommented in the mac file (cylinder, sphere, and box), sometimes the viewer exits with the fault and sometimes without. Did you try it with only one of the geometries uncommented?
When I use the initially uploaded macro with vGate8.2 on macOS 10.14.5, the GateMaterials.db file from the GateContrib/misc/ folder, and one uncommented geometry, the program still crashes with the same segfault whether using the viewer or not. Thus, I am not convinced my install of Gate is the problem as I have successfully installed and benchmarked Gate to the best of my knowledge and have been using it successfully otherwise.
Cheers,
Matthew
________________________________
From: Konstantinos P. Chatzipapas, MSc <konhat88 at yahoo.gr>
Sent: July 3, 2019 2:00 AM
To: Matthew Strugari; gate-users at lists.opengatecollaboration.org
Cc: David Boersma
Subject: Re: [Gate-users] Segmentation violation for water geometry
Hello Matthew,
I tried to use your first mac (the one you upload here) and it works fine with me (I un-comment everything and used qt). Thus, there is nothing wrong with that (except that I used my own Materials Database). I used vGate8.2. I would suggest you, to know Gate better, to use vGate. Your problem is probably about the installation that you have make. I can't know what is exactly. (also, maybe your materials have something wrong, which is common)
Then, if you really need to install Gate the hard way, in Linux, I would suggest you to clean everything and start installing again, single core and watch for any warnings.
Kind Regards,
Konstantinos
-----------------------------------------------------
Konstantinos Chatzipapas
Medical Physicist, MSc
University of Patras
web page: Physics Magazine<http://www.physicsmag.com/>
Στις Τρίτη, 2 Ιουλίου 2019, 05:04:24 μ.μ. EEST, ο χρήστης Matthew Strugari <matthew.strugari at dal.ca> έγραψε:
Hi David,
Thank you for the info and I'm happy to help in any way I can. Here are the details:
* I am using Geant4 10.05.p01 - the "patch01" release from April 2019.
* When I run with/without the viewer, I appear to get the same segfault.
* My operating system is Ubuntu 18.04.2 LTS, and my compiler is gcc-7.4.0
* I see that the required dependencies for gate suggest gcc 4.8 to 7.3
* The build type set in cmake was "Release". I have attached the output log files with the appended backtrace in both "Release" and "Debug" mode.
* I have attached the GateMaterials.db file which contains my edits for additional materials. I cannot recall exactly where I copied this file from.
* I am using Gate version 8.2 which I obtained from the tar file on the opengatecollaboration website. Would you suggest that I change over to the git version?
Cheers,
Matthew
________________________________
From: Gate-users <gate-users-bounces at lists.opengatecollaboration.org> on behalf of David Boersma <david.boersma at acmit.at>
Sent: June 28, 2019 10:55 AM
To: gate-users at lists.opengatecollaboration.org
Subject: Re: [Gate-users] Segmentation violation for water geometry
Hi Matthew and Dimitris,
First: if you manage to get a segfault with Gate (or any other program), then you found a bug, period. No matter how wrong the input, a well-written program should never segfault, it should terminate with a helpful error message that explains which part of your input was problematic. (Unfortunately, it's actually quite easy to get segfaults with Gate, I suspect that users often just don't bother to report of them. It's great that you *do* report it!)
Second: I tried to reproduce this segfault and failed. I do get a crash, but a different one: Qt crashes due to some floating point exception, which seems unrelated to the segfault that you are reporting. When I completely disable the visualization, then Gate runs and terminates normally, no crash.
So... I am going to ask some more details:
* It looks like you are using geant4 10.05, is that the original release (7 December 2018) or the "patch01" release (17 April 2019)?
* If you run without the viewer (comment out all /vis lines, add a /vis/disable line, run without --qt), do you then still get the same segfault, or some other crash?
* What operating system and compiler are you using?
* What build type did you set in cmake? "Release" or something else? If you have some time to burn: could you rerun cmake and set it to "Debug", then reproduce the crash? The backtrace should then also quote filenames and line numbers for the items in Gate.
* There are several different GateMaterials.db files around (it's fine to edit your own, but we should harmonize the db files that we distribute in Gate and GateContrib). Could you send us the one that you are using?
* Which release of Gate are you using? If you got your code directly from github, could you quote to us the output from "git log -n 1", "git branch -l" and "git remote -v"?
Thanks,
David B.
________________________________
Von: Gate-users <gate-users-bounces at lists.opengatecollaboration.org> im Auftrag von Matthew Strugari <matthew.strugari at dal.ca>
Gesendet: Freitag, 28. Juni 2019 15:36:13
An: Dimitrios Thanasas
Cc: gate-users at lists.opengatecollaboration.org
Betreff: Re: [Gate-users] Segmentation violation for water geometry
Hi Dimitris,
Thanks for the suggestion. Unfortunately, I still encounter the same problem with spaces instead of tabs. I know Qt doesn't work when using tabs in the session command bar but I haven't had any problems using tabs in the macros.
Cheers,
Matthew
________________________________
From: Dimitrios Thanasas <dthanas at uoa.gr>
Sent: June 28, 2019 2:51 AM
To: Matthew Strugari
Cc: gate-users at lists.opengatecollaboration.org
Subject: Re: [Gate-users] Segmentation violation for water geometry
Hi Matthew,
Try not having tabs, only spaces when you write a command.
I think it will work.
See the attached file, I think it is working.
Cheers,
Dimitris
> Hi everyone,
>
> I am not sure if this is a bug, but I am having difficulty defining a
> water phantom. In short, I am able to visualize basic geometries such as a
> sphere, box, or cylinder using the Qt viewer. However, when the material
> is set to Water, the viewer exits with the segmentation violation as shown
> below.
>
> To diagnose, I've found that:
>
> 1. The fault doesn't appear to happen with G4_WATER or any other
> materials.
> 2. Water appears to be properly defined in the GateMaterials.db file.
> 3. If all three geometries are enabled, sometimes the viewer exits
> without the fault and other times with the fault.
>
> Please let me know if you have any ideas on the issue.
>
> Cheers,
> Matthew
>
>
> --
>
> Matthew Strugari
>
> Biomedical Translational Imaging Centre - BIOTIC,
> 5890 University Ave,
> Halifax, NS, B3K 6R8
>
>
>
> *** Break *** segmentation violation
>
>
>
> ===========================================================
> There was a crash.
> This is the entire stack trace of all threads:
> ===========================================================
> #0 0x00007f09e9b26687 in __GI___waitpid (pid=14368, stat_loc=stat_loc
> entry=0x7ffd32063968, options=options
> entry=0) at ../sysdeps/unix/sysv/linux/waitpid.c:30
> #1 0x00007f09e9a91067 in do_system (line=<optimized out>) at
> ../sysdeps/posix/system.c:149
> #2 0x00007f09f41200d3 in TUnixSystem::Exec (shellcmd=<optimized out>,
> this=0x55f88c467c50) at
> /home/matthew/Programs/root/root-6.14.04/core/unix/src/TUnixSystem.cxx:2119
> #3 TUnixSystem::StackTrace (this=0x55f88c467c50) at
> /home/matthew/Programs/root/root-6.14.04/core/unix/src/TUnixSystem.cxx:2413
> #4 0x00007f09f4122ac4 in TUnixSystem::DispatchSignals
> (this=0x55f88c467c50, sig=kSigSegmentationViolation) at
> /home/matthew/Programs/root/root-6.14.04/core/unix/src/TUnixSystem.cxx:3644
> #5 <signal handler called>
> #6 0x000055f88a6b5805 in GateMaterialDatabase::~GateMaterialDatabase() ()
> #7 0x000055f88a64b88e in
> GateDetectorConstruction::~GateDetectorConstruction() ()
> #8 0x000055f88a64b8a9 in
> GateDetectorConstruction::~GateDetectorConstruction() ()
> #9 0x00007f09f0d04496 in G4RunManager::DeleteUserInitializations() ()
> from /home/matthew/Programs/geant4/geant4.10.05-install/lib/libG4run.so
> #10 0x00007f09f0d056b0 in G4RunManager::~G4RunManager() () from
> /home/matthew/Programs/geant4/geant4.10.05-install/lib/libG4run.so
> #11 0x000055f88a602179 in GateRunManager::~GateRunManager() ()
> #12 0x000055f88a241ae6 in main ()
> ===========================================================
>
>
> The lines below might hint at the cause of the crash.
> You may get help by asking at the ROOT forum http://root.cern.ch/forum
> Only if you are really convinced it is a bug in ROOT then please submit a
> report at http://root.cern.ch/bugs Please post the ENTIRE stack trace
> from above as an attachment in addition to anything else
> that might help us fixing this issue.
> ===========================================================
> #6 0x000055f88a6b5805 in GateMaterialDatabase::~GateMaterialDatabase() ()
> #7 0x000055f88a64b88e in
> GateDetectorConstruction::~GateDetectorConstruction() ()
> #8 0x000055f88a64b8a9 in
> GateDetectorConstruction::~GateDetectorConstruction() ()
> #9 0x00007f09f0d04496 in G4RunManager::DeleteUserInitializations() ()
> from /home/matthew/Programs/geant4/geant4.10.05-install/lib/libG4run.so
> #10 0x00007f09f0d056b0 in G4RunManager::~G4RunManager() () from
> /home/matthew/Programs/geant4/geant4.10.05-install/lib/libG4run.so
> #11 0x000055f88a602179 in GateRunManager::~GateRunManager() ()
> #12 0x000055f88a241ae6 in main ()
> ===========================================================
>
> _______________________________________________
> Gate-users mailing list
> Gate-users at lists.opengatecollaboration.org
> http://lists.opengatecollaboration.org/mailman/listinfo/gate-users
_______________________________________________
Gate-users mailing list
Gate-users at lists.opengatecollaboration.org<mailto:Gate-users at lists.opengatecollaboration.org>
http://lists.opengatecollaboration.org/mailman/listinfo/gate-users
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opengatecollaboration.org/pipermail/gate-users/attachments/20190703/f743cd91/attachment-0001.html>
More information about the Gate-users
mailing list