<div dir="ltr">Hi Salvatore, <div><br></div><div style>happy to see that you manage to make it works. </div><div style><br></div><div style>And yes the development trunk will be available soon as a git repository. This git repository contains several branches. The "master" branch is read-only and represents the current version (6.2). The "develop" branch is read-only for users and allow write for collaboration members. As user you will be able to clone that branch and make modification on you own. If you think it is interesting for other people you will be able to send us a "pull request" together with a short description of your modifications in order that we could integrate your development in the develop branch. The other solution is to become a full member of the collaboration to be able to write directly in the repository.</div>
<div style><br></div><div style>Albertine will send information on the git repository soon (in the next days we will be travelling, so expect end of next week). </div><div style><br></div><div style>I am glad to see that users contribute to the code, thanks Salvatore !</div>
<div style>Sincerely, </div><div style>David</div><div style><br></div><div style><br></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Tue, May 14, 2013 at 6:21 PM, Salvatore Di Guida <span dir="ltr"><<a href="mailto:salvatore.di.guida@cern.ch" target="_blank">salvatore.di.guida@cern.ch</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Robert!<br>
As I said in my previous mail, I am currently using Gate v6.1. I adapted the phase space actor for that release, and patched my version using the patch file in attachment. I tested it, it just works.<br>
Anyhow, it would be great to see the development trunk of GATE. Which VCS (SVN, Mercurial, Git) do the GATE developers use? Can users be granted access to the repository? If so, which is the address?<br>
<br>
Thanks<br>
<br>
Salvatore<br>
<br>
________________________________<br>
From: <a href="mailto:david.sarrut@gmail.com">david.sarrut@gmail.com</a> [<a href="mailto:david.sarrut@gmail.com">david.sarrut@gmail.com</a>] on behalf of David Sarrut [<a href="mailto:David.Sarrut@creatis.insa-lyon.fr">David.Sarrut@creatis.insa-lyon.fr</a>]<br>
Sent: 10 May 2013 09:13<br>
To: Irene Torres; Salvatore Di Guida<br>
Cc: <a href="mailto:robert@imnc.in2p3.fr">robert@imnc.in2p3.fr</a>; Dubois Albertine; gate-users<br>
Subject: Re: [Gate-users] Simulate a beam with spaced bunches in GATE<br>
<div class="im"><br>
Hello Irene and Salvatore,<br>
<br>
the enhanced phase space actor is in the develop part of the current gate repository and you will be able to access to this current development version (without guarantee) in some times, but we still need to setup correctly the system, so please be patient. In the meantime, you can look at the code and try to modify the classes GatePhaseSpaceActor.<br>
<br>
Sincerely,<br>
David<br>
<br>
<br>
</div><div class="im">On Mon, Apr 29, 2013 at 9:08 PM, Irene Torres <<a href="mailto:ireneta@ific.uv.es">ireneta@ific.uv.es</a><mailto:<a href="mailto:ireneta@ific.uv.es">ireneta@ific.uv.es</a>>> wrote:<br>
Hello David,<br>
<br>
Thank you for your help!<br>
<br>
I have tried the last option you suggested and I got an error during GATE compilation:<br>
<br>
./tmp/Linux-g++/Gate/libGate.so: undefined reference to `GatePhaseSpaceActor::GatePhaseSpaceActor(G4String, int)'<br>
collect2: ld returned 1 exit status<br>
make: *** [bin/Linux-g++/Gate] Error 1<br>
</div>root@cormorant:/opt/OpenGate6/gate_v6.1#<mailto:<a href="mailto:root@cormorant">root@cormorant</a>:/opt/OpenGate6/gate_v6.1#> exit<br>
<div class="im"><br>
Any idea where I should start searching??<br>
Thanks again!<br>
<br>
Cheers,<br>
<br>
Irene<br>
<br>
<br>
On 04/29/2013 08:00 AM, David Sarrut wrote:<br>
Hello Salvatore,<br>
<br>
I haven't got the time to look at in detail, but this is true that phase-space dose not store runID, eventID, and that, in that case, the time is no taken into account with the source.<br>
<br>
I think the best solution for your problem is to write a new type of source. That should not be too difficult (even if it requires some times), starting from a new class inheriting from GateVSource. You will need also to slightly modify GateSourceMgr (in function AddSource) to enable your new source type. Maybe instead of a new source type, you can alternatively add timing option to the GPS source type. I am convinced that it could be useful to other too.<br>
<br>
Another alternative option, simpler but maybe not as useful, could be to add RunID and EvenID branch in the phase space. I attached to this mail a new version of the PhaseSpaceActor that store eventID and runID. You can try it (without any guarantee) by adding the files in the src/include folders of the digits_hits folder.<br>
<br>
Sincerely,<br>
David<br>
<br>
<br>
</div><div><div class="h5">On Mon, Apr 22, 2013 at 5:58 PM, Salvatore Di Guida <<a href="mailto:salvatore.di.guida@cern.ch">salvatore.di.guida@cern.ch</a><mailto:<a href="mailto:salvatore.di.guida@cern.ch">salvatore.di.guida@cern.ch</a>>> wrote:<br>
Dear GATE users and developers,<br>
since I have been using the framework for few weeks, I apologize for my misunderstandings and mistakes.<br>
I have simulated the detector I am working on as two water boxes (equivalent to gas detectors), two plastic scintillator boxes plus a scanner system made up of 30 plastic scintillators. I have attached one phase space to each water box (in order to describe the incoming particles from the source and from the first box, respectively), to the air box between the water boxes (in order to look at the particles outgoing the first water box) and to the air box between the second water fox and the first scintillator (in order to look at the particles outgoing the second water box). Moreover, I have defined a proton pencil beam source: I have implemented it both via G4 GeneralParticleSource and using the PencilBeam template in GATE.<br>
If you like, you can check the geometry and the sources in details in the archive I am attaching to this mail: there you can find the macros I am using. I am working with GATE 6.1 on vGATE 2.0.<br>
The output I want to retrieve is, for each proton, the x and y position in each water box, and the energy deposition in each level of the scanner system.<br>
In my first attempt, I simply created the geometry, the source, and the digitizer system, and launched the simulation with 1000 primaries, producing ROOT files as output. My idea was to distinguish the incoming protons by the (runID, eventID) pair: unfortunately, the phase space does not store this piece of information [1].<br>
Then, since both the phase space and the scanner keep time information, my next attempt was to calculate the coincidences of each proton in the water boxes and in the first scintillator: in this way, I could mark the protons propagating outside the scanner with the same (runID, eventID) pair established inside it. Unfortunately, both sources generate all the protons at t = 0, so it is impossible to get an adequate result via coincidence computations [2].<br>
Next, I tried to overcome this issue using time slices in Data Acquisition: I defined 1000 time slices, where each slice has a time duration larger than the time of flight of the proton, so that I had one primary per slice, and the association between data in water and data in the scanner could be quite easy. Unfortunately, when the second time slice starts, GATE crashes with a segmentation violation with both the PencilBeam source and with GPS source (even when I tried to set GeneralParticleSource::number or setActivity in GATE). Debugging with gdb did not help.<br>
<br>
My question is: is there a way in GATE to produce a beam source where a given number of protons are grouped in bunches spaced by a given time interval (say: 100 protons-per-bunch, bunches spaced by 100 ms).<br>
<br>
Thanks in advance for your help!<br>
<br>
Salvatore<br>
<br>
[1]<br>
$ root -l<br>
root [] TFile* gem0RootFile = TFile::Open("GEM0PHS_1000primaries_perfectPBS.root")<br>
root [] TTree* gem0PhaseSpaceTree = (TTree*) gem0RootFile->Get( "PhaseSpace" )<br>
root [] phaseSpaceTree->Print()<br>
<br>
[2] the source is 0.05 mm far from the phase space, which is at the origin of the world; so, all protons enter the water box associated to the phase space at t > 0:<br>
root [] TFile* gem0RootFile = TFile::Open("GEM0PHS_1000primaries_perfectPBS.root")<br>
root [] TTree* gem0PhaseSpaceTree = (TTree*) gem0RootFile->Get( "PhaseSpace" )<br>
root [] gem0PhaseSpaceTree->Scan( "ParticleName:Time:X:Y:Z:dX:dY:dZ:Ekine" )<br>
************************************************************************************************************************<br>
* Row * ParticleN * Time * X * Y * Z * dX * dY * dZ * Ekine *<br>
************************************************************************************************************************<br>
* 0 * proton * 0.0003519 * 0 * 0 * 0 * -2.63e-08 * 2.610e-08 * 1 * 100 *<br>
* 1 * proton * 0.0003519 * 0 * 0 * 0 * 2.421e-08 * 9.183e-11 * 1 * 100 *<br>
* 2 * proton * 0.0003519 * 0 * 0 * 0 * 1.011e-09 * 2.843e-09 * 1 * 100 *<br>
* 3 * proton * 0.0003519 * 0 * 0 * 0 * -5.11e-09 * 7.478e-10 * 1 * 100 *<br>
* 4 * proton * 0.0003519 * 0 * 0 * 0 * 2.031e-08 * -2.61e-08 * 1 * 100 *<br>
* 5 * proton * 0.0003519 * 0 * 0 * 0 * 2.153e-08 * 9.473e-09 * 1 * 100 *<br>
...<br>
And here it is how the ROOT file for the phase space between the two water boxes look like: there is a very slight difference in timing between protons...<br>
root [] TFile* gemSpacingRootFile = TFile::Open("GEMSpacingPHS_1000primaries_perfectPBS.root")<br>
root [] TTree* gemSpacingPhaseSpaceTree = (TTree*) gemSpacingRootFile->Get( "PhaseSpace" )<br>
root [] gemSpacingPhaseSpaceTree->Scan( "ParticleName:Time:X:Y:Z:dX:dY:dZ:Ekine" )<br>
************************************************************************************************************************<br>
* Row * ParticleN * Time * X * Y * Z * dX * dY * dZ * Ekine *<br>
************************************************************************************************************************<br>
* 0 * proton * 0.0194233 * 0.0030443 * -0.001321 * 2.7000000 * 0.0042755 * -0.001657 * 0.9999895 * 98.147529 *<br>
* 1 * proton * 0.0194286 * -0.002575 * 0.0078605 * 2.7000000 * -0.002732 * 0.0060394 * 0.9999780 * 97.927230 *<br>
* 2 * proton * 0.0194189 * 0.0081350 * -0.003375 * 2.7000000 * 0.0061967 * -0.000981 * 0.9999803 * 98.123619 *<br>
* 3 * proton * 0.0194209 * 0.0102742 * -0.006316 * 2.7000000 * -0.002067 * -0.004013 * 0.9999898 * 97.984443 *<br>
* 4 * proton * 0.0194191 * -0.007278 * 0.0019697 * 2.7000000 * -0.005616 * 0.0024906 * 0.9999811 * 98.163551 *<br>
...<br>
<br>
_______________________________________________<br>
Gate-users mailing list<br>
</div></div><a href="mailto:Gate-users@lists.opengatecollaboration.org">Gate-users@lists.opengatecollaboration.org</a><mailto:<a href="mailto:Gate-users@lists.opengatecollaboration.org">Gate-users@lists.opengatecollaboration.org</a>><br>
<div class="im"><a href="http://lists.opengatecollaboration.org/mailman/listinfo/gate-users" target="_blank">http://lists.opengatecollaboration.org/mailman/listinfo/gate-users</a><br>
<br>
<br>
<br>
--<br>
David Sarrut, Phd<br>
Chargé de recherche CNRS<br>
CREATIS, UMR CNRS 5220, Inserm U 1044<br>
Centre de lutte contre le cancer Léon Bérard<br>
28 rue Laënnec, 69373 Lyon cedex 08<br>
Tel : 04 78 78 51 51 / 06 74 72 05 42<br>
</div><a href="http://www.creatis.insa-lyon.fr/~dsarrut" target="_blank">http://www.creatis.insa-lyon.fr/~dsarrut</a><<a href="http://www.creatis.insa-lyon.fr/%7Edsarrut" target="_blank">http://www.creatis.insa-lyon.fr/%7Edsarrut</a>><br>
<div class="im">_________________________________<br>
"2 + 2 = 5, for extremely large values of 2"<br>
_________________________________<br>
<br>
<br>
_______________________________________________<br>
Gate-users mailing list<br>
</div><a href="mailto:Gate-users@lists.opengatecollaboration.org">Gate-users@lists.opengatecollaboration.org</a><mailto:<a href="mailto:Gate-users@lists.opengatecollaboration.org">Gate-users@lists.opengatecollaboration.org</a>><br>
<div class="HOEnZb"><div class="h5"><a href="http://lists.opengatecollaboration.org/mailman/listinfo/gate-users" target="_blank">http://lists.opengatecollaboration.org/mailman/listinfo/gate-users</a><br>
<br>
<br>
<br>
<br>
--<br>
David Sarrut, Phd<br>
Chargé de recherche CNRS<br>
CREATIS, UMR CNRS 5220, Inserm U 1044<br>
Centre de lutte contre le cancer Léon Bérard<br>
28 rue Laënnec, 69373 Lyon cedex 08<br>
Tel : 04 78 78 51 51 / 06 74 72 05 42<br>
<a href="http://www.creatis.insa-lyon.fr/~dsarrut" target="_blank">http://www.creatis.insa-lyon.fr/~dsarrut</a><br>
_________________________________<br>
"2 + 2 = 5, for extremely large values of 2"<br>
_________________________________<br>
</div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br><div dir="ltr">David Sarrut, Phd<br>Chargé de recherche CNRS<br>CREATIS, UMR CNRS 5220, Inserm U 1044<div>Centre de lutte contre le cancer Léon Bérard<br>
28 rue Laënnec, 69373 Lyon cedex 08<br>Tel : 04 78 78 51 51 / 06 74 72 05 42<br><a href="http://www.creatis.insa-lyon.fr/~dsarrut" target="_blank">http://www.creatis.insa-lyon.fr/~dsarrut</a><br>_________________________________</div>
<div> "2 + 2 = 5, for extremely large values of 2"<br>_________________________________</div></div>
</div>