Gate icon indicating copy to clipboard operation
Gate copied to clipboard

Optical simulation is not working with vGATE v9.1

Open hangyookang opened this issue 2 years ago • 2 comments

Describe the bug The optical simulation is NOT working with vGATE v9.1. Error message is as following [G4- 0 cerr] ***** COMMAND NOT FOUND </gate/crystal/surfaces/name Detetion1> *****

It seems like that optical surface or boundary cannot be defined for some reason. image

Desktop (please complete the following information):

  • Gate version: vGate v9.1]

Minimal example GateContrib/imagingOpticsl/Optical_System.mac

Expected behavior Optical simulation is working well with root output

hangyookang avatar Apr 14 '22 11:04 hangyookang

I found the cause of the error for the optical simulation In virtual GATE v9.1. The "GATE_USE_OPTICAL" option was OFF from the beginning. That's why I faced the error when running the optical simulation. To solve this issue, I turned on the "GATE_USE_OPTICAL" option as ON, then re-compile the GATE. ================================================================================ (1) libxml2-dev was installed to enable the compilation of the GATE >sudo apt-get install libxml2-dev

(2) Go to the GATE source folder

cd /home/vgate/Software/Gate/src

(3) Turn the "GATE_USE_OPTICAL" option as ON in the ccmake.

ccmake .

2022_05_05_vGATEv9p1_GATE_USE_OPTICAL_ON

(4) Set the EXECUTABLE_OUTPUT_PATH -> /home/vgate/Software/Gate/bin

(5) Re-compiled the GATE.

make 2022_05_05_vGATEv9p1_ReCompiled_make

sudo make install

2022_05_05_vGATEv9p1_ReCompiled_sudo_make_install

================================================================================

Now optical simulation is working well without any problem. Below is an example of LUTDavisModel during the optical simulation. 2022_05_05_vGATEv9p1_Optical_Simulation_ScreenCapture

In my case, I don't use vGATE so much since I installed GATE on Linux. But for beginners, vGATE is the most simplest way to use GATE. For the release of the next vGATE, it is better to set the GATE_USE_OPTICAL option as ON status, so that everyone can run optical simulation easily.

hangyookang avatar May 05 '22 11:05 hangyookang

great thanks ! Indeed, I think we should try to set OPTICAL to ON by default. The only potential drawback is, that, in previous version, there were some warnings ... we will investigate to see what is feasible.

dsarrut avatar May 05 '22 14:05 dsarrut

Done with this PR: https://github.com/OpenGATE/Gate/pull/566

For the vGate, it will be done in the next release. Thank you

tbaudier avatar Jan 25 '23 12:01 tbaudier