[Gate-users] problem with .IAEAphsp format

Luc SIMON uhqd75 at gmail.com
Tue Mar 14 14:30:30 CET 2017


Dear all,
please find hereafter my  low level user experience :-)
If it is possible for you I recommand (everybody won't agree) to use
IAEAphsp file instead of ROOT.
ROOT is powerfull to treat and process data but files are huge ! (even when
you store a few info)
IAEAphsp is like a LMF format, with no useless bytes...

In a context of external RT I do this to put particles from a first
simulation in a plane (named outPhSp here):




















*/gate/actor/addActor PhaseSpaceActor
IAEAPhaseSpace/gate/actor/IAEAPhaseSpace/save
output/myIAEA.IAEAphsp/gate/actor/IAEAPhaseSpace/attachTo
outPhSp/gate/actor/IAEAPhaseSpace/enableEkine
true/gate/actor/IAEAPhaseSpace/enableXPosition
true/gate/actor/IAEAPhaseSpace/enableYPosition
true/gate/actor/IAEAPhaseSpace/enableZPosition
true/gate/actor/IAEAPhaseSpace/enableXDirection
true/gate/actor/IAEAPhaseSpace/enableYDirection
true/gate/actor/IAEAPhaseSpace/enableZDirection
true/gate/actor/IAEAPhaseSpace/enableProductionVolume
false/gate/actor/IAEAPhaseSpace/enableProductionProcess
false/gate/actor/IAEAPhaseSpace/enableParticleName
true/gate/actor/IAEAPhaseSpace/enableWeight true# Store coordinates in the
actor coordinates/gate/actor/IAEAPhaseSpace/useVolumeFrame true# Warning :
set this line to true make the particles generated twice# when the output
file is used as an input/gate/actor/IAEAPhaseSpace/storeSecondaries false*


In a second simulation I use these lines as an input (you must move your
data from output/ to data/)




*/gate/source/addSource MyBeam
phaseSpace/gate/source/MyBeam/addPhaseSpaceFile
data/myIAEA.IAEAphsp/gate/source/MyBeam/attachTo outPhSp*
Last thing, get the last version of GATE because some bug were fixed
concerning .IAEAphsp read/write files
Regards
Luc



2017-03-13 10:44 GMT+01:00 David Sarrut <David.Sarrut at creatis.insa-lyon.fr>:

> Hello,
>
> - for IAEA phase-space -> sorry, I dont know
>
> - for root phase-space, please explain precisely what the issue is. When
> compiling ? When writing or when reading a phsp ? What is you goal ?
>
> Short information:
>
> To write a phsp, it is managed by the PhaseSpaceActor
> <https://github.com/OpenGATE/Gate/blob/develop/source/digits_hits/src/GatePhaseSpaceActor.cc>.
> There are a lot of options (see the macros in the messenger
> <https://github.com/OpenGATE/Gate/blob/develop/source/digits_hits/src/GatePhaseSpaceActorMessenger.cc>).
> Do you setEnablePartName to true to store the particle name in the phsp ?
>
> To read a phsp as a source of particles, it is managed by the
> SourcePhaseSpace
> <https://github.com/OpenGATE/Gate/blob/develop/source/physics/src/GateSourcePhaseSpace.cc>.
> Also, have a look at the code and the associated messengers to get the full
> list of options.
>
> Phase Space is a large piece of code and could be quite powerful, but it
> is complex. Please note that some bug fixes and modifications have been
> done since the last Gate version. You may have a better luck to give a try
> with the current Gate version (develop branch, which will be the next Gate
> 8.0 soon).
>
> David
> PS: please keep gate-user mailing list in copy, it could help other people
> ... and other people could help ;)
>
>
> On Mon, Mar 13, 2017 at 10:28 AM, Consuelo Guardiola <
> guardiola at imnc.in2p3.fr> wrote:
>
>> Hi David (I'm adding Yolanda Prezado in CC, my advisor here, since she
>> told me she has recently discussed some v7.0 vs 7.1 discrepancies with you)
>> :
>>
>> I lately tried with IAEA phsp format since in the Gate forum someone
>> replied me this:
>>
>> ------------------------------------------------------------
>> --------------------------------------
>>
>> Hi,
>>
>> I had the same problem few months ago and i think it was related to the
>> root version. Version 5.34/36 didn't work but 5.34/26 worked. Otherwise,
>> i'm finally using .IAEAphsp format to gather PhaseSpace files and its also
>> working.
>>
>> Hope this would help,
>>
>> Tony
>>
>> when I asked this:
>>
>> Dear Gate users,
>>
>> I gathered a Phase Space file (in .root format) to be used as a source
>> afterwards. When I try to run it as it is explained in the manual:
>>
>> http://wiki.opengatecollaboration.org/index.php/Users_Guide_
>> V7.2:Phase_space_concept
>>
>> it fails and says that I need to define the particle type. Nevertheless,
>> the .root file contains all the information (particle types, etc). I have
>> not found more info neither in forums or around. Please could someone tell
>> me if  I am losing some info or what I may do to figure it out?
>>
>> Thanks in advance,
>> Consuelo.
>> ------------------------------------------------------------
>> -----------------------------------------------------------
>>
>>
>> I have tried both things: first reinstalling everything with 5.34/26 root
>> version, but did not work, later with IAEA phsp format... the point is that
>> neither with Gate 7.0 nor 7.1 I can launch the phase space file WITHOUT
>> specify the particle type (which would be completely wrong...). Do you have
>> any idea how to figure this out? I would appreciate whatever advice.
>>
>> Thanks in advance
>> Consuelo
>>
>>
>>
>> ------------------------------
>> *De: *"David Sarrut" <David.Sarrut at creatis.insa-lyon.fr>
>> *À: *"Consuelo Guardiola" <guardiola at imnc.in2p3.fr>
>> *Envoyé: *Lundi 13 Mars 2017 10:18:36
>> *Objet: *Re: [Gate-users] problem with .IAEAphsp format
>>
>> Hello,
>> to my knowledge, the IAEA phsp form in Gate in buggy: it only works for
>> some type of particles.
>>
>> You may look at the source code:
>> - https://github.com/OpenGATE/Gate/blob/develop/source/gener
>> al/src/GateIAEAHeader.cc
>> - https://github.com/OpenGATE/Gate/blob/develop/source/general
>> /src/GateIAEAPhsp.cc
>> - https://github.com/OpenGATE/Gate/blob/develop/source/gener
>> al/src/GateIAEARecord.cc
>> - https://github.com/OpenGATE/Gate/blob/develop/source/gener
>> al/src/GateIAEAUtilities.cc
>>
>> it could help to find what's wrong ...
>>
>> David
>> PS: sorry I cannot help, I do not use such format
>>
>> On Wed, Mar 8, 2017 at 3:34 PM, Consuelo Guardiola <
>> guardiola at imnc.in2p3.fr> wrote:
>>
>>> Dear Gate users,
>>>
>>> If I try to gather the phase space in .IAEAphsp format in both Gate v7.0
>>> and v7.1, it does not work. Apparently, it does not get any error-file
>>> back, but in the running-file I find this:
>>>
>>> GatePhaseSpaceActor.cc (l.296): Actor phase space: particle not
>>> available in IAEA format.
>>>
>>> (no matter the version of Gate that I use or even running different jobs
>>> to discard a possible particle/material issue)
>>>
>>> But, unexpectedly, I get an empty (0 size)  output.IAEAphsp  file.
>>>
>>> Does anyone know what happens?
>>>
>>> Thanks in advance,
>>> Consuelo.
>>>
>>>
>>>
>>> _______________________________________________
>>> Gate-users mailing list
>>> Gate-users at lists.opengatecollaboration.org
>>> http://lists.opengatecollaboration.org/mailman/listinfo/gate-users
>>>
>>
>>
>>
>> --
>> David Sarrut, Phd
>> Directeur de recherche CNRS
>> CREATIS, UMR CNRS 5220, Inserm U1206
>> Centre de lutte contre le cancer Léon Bérard
>> 28 rue Laënnec, 69373 Lyon cedex 08
>> Tel : 04 78 78 51 51 / 06 74 72 05 42
>> http://www.creatis.insa-lyon.fr/~dsarrut
>> _________________________________
>>  "2 + 2 = 5,  for extremely large values of 2"
>> _________________________________
>>
>>
>
>
> --
> David Sarrut, Phd
> Directeur de recherche CNRS
> CREATIS, UMR CNRS 5220, Inserm U1206
> Centre de lutte contre le cancer Léon Bérard
> 28 rue Laënnec, 69373 Lyon cedex 08
> Tel : 04 78 78 51 51 / 06 74 72 05 42
> http://www.creatis.insa-lyon.fr/~dsarrut
> _________________________________
>  "2 + 2 = 5,  for extremely large values of 2"
> _________________________________
>
> _______________________________________________
> Gate-users mailing list
> Gate-users at lists.opengatecollaboration.org
> http://lists.opengatecollaboration.org/mailman/listinfo/gate-users
>



-- 
___________________

SIMON Luc, Physicien Médical, PhD
Département d'Ingénierie et de Physique Médicale - IUCT-Oncopole -
Toulouse, FRANCE
INSERM UMR 1037 (CRCT) - Equipe 15 - Toulouse, FRANCE
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opengatecollaboration.org/mailman/private/gate-users/attachments/20170314/0cc3bf0f/attachment-0001.html>


More information about the Gate-users mailing list