<html>
<head>
<meta http-equiv="Content-Type" content="text/html;
charset=windows-1252">
</head>
<body>
<p>Hi Josh,</p>
<p>VolumeID array represents the ID of the volume in which the hit
occurred.<br>
</p>
<p>Each position in the array gives you the volume ID at a specific
hierarchy level.</p>
<p>Let's say that you have an scanner made of two heads and each
head is composed of 64 pixelated crystals.</p>
<p>The ID of the detector head goes from 0 to 1, whereas the ID at
pixel level goes from 0 to 63.</p>
<p>In this case, in order to identify the volume where the hit
occurred you will need this two values of the array.</p>
<p>If you have a single detector head, the ID at pixel level will
be enough to identify the volume.<br>
</p>
<p>I hope it helps.</p>
<p>Regards,</p>
<p>Ane</p>
<div class="moz-cite-prefix">On 01/09/2021 23:19, Josh Knowland
wrote:<br>
</div>
<blockquote type="cite"
cite="mid:MN2PR15MB329634577F84211563A61FD8AFCD9@MN2PR15MB3296.namprd15.prod.outlook.com">
<meta http-equiv="Content-Type" content="text/html;
charset=windows-1252">
<meta name="Generator" content="Microsoft Word 15 (filtered
medium)">
<style>@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0in;
font-size:11.0pt;
font-family:"Calibri",sans-serif;}p.MsoListParagraph, li.MsoListParagraph, div.MsoListParagraph
{mso-style-priority:34;
margin-top:0in;
margin-right:0in;
margin-bottom:0in;
margin-left:.5in;
font-size:11.0pt;
font-family:"Calibri",sans-serif;}span.EmailStyle17
{mso-style-type:personal-compose;
font-family:"Calibri",sans-serif;
color:windowtext;}.MsoChpDefault
{mso-style-type:export-only;
font-family:"Calibri",sans-serif;}div.WordSection1
{page:WordSection1;}ol
{margin-bottom:0in;}ul
{margin-bottom:0in;}</style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
<div class="WordSection1">
<p class="MsoNormal">Hello GATE experts,<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Can you help me get the volume ID where
hits occurred from the root file?<o:p></o:p></p>
<p class="MsoNormal">I have been able to export the hits tree to
a text file using scan(“*”). I’ve attached a sample of the
first 10 events in the text file.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">I can tell that the VolumeID branch holds
an array for each event. The arrays are 10 elements and must
indicate somehow the detector volume in which the hit
occurred.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Really, the only information I need for
each hit is:<o:p></o:p></p>
<ol style="margin-top:0in" type="1" start="1">
<li class="MsoListParagraph"
style="margin-left:0in;mso-list:l0 level1 lfo1">ProcessName<o:p></o:p></li>
<li class="MsoListParagraph"
style="margin-left:0in;mso-list:l0 level1 lfo1">PDGEncoding<o:p></o:p></li>
<li class="MsoListParagraph"
style="margin-left:0in;mso-list:l0 level1 lfo1">edep<o:p></o:p></li>
<li class="MsoListParagraph"
style="margin-left:0in;mso-list:l0 level1 lfo1">posX, posY,
posZ<o:p></o:p></li>
<li class="MsoListParagraph"
style="margin-left:0in;mso-list:l0 level1 lfo1">sourceID<o:p></o:p></li>
<li class="MsoListParagraph"
style="margin-left:0in;mso-list:l0 level1 lfo1">sourcePosX,
sourcePosY, sourcePosZ<o:p></o:p></li>
<li class="MsoListParagraph"
style="margin-left:0in;mso-list:l0 level1 lfo1">[the ID of
the volume in which the hit occurred]<o:p></o:p></li>
</ol>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Ideally, I need to output the tree as a
text file like the attached one. To reduce file size, I’d like
to have only one line per event instead of the 10 lines it’s
writing now.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Can you help me understand this?<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Thanks,<o:p></o:p></p>
<p class="MsoNormal">Josh<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<pre class="moz-quote-pre" wrap="">_______________________________________________
Gate-users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Gate-users@lists.opengatecollaboration.org">Gate-users@lists.opengatecollaboration.org</a>
<a class="moz-txt-link-freetext" href="http://lists.opengatecollaboration.org/mailman/listinfo/gate-users">http://lists.opengatecollaboration.org/mailman/listinfo/gate-users</a></pre>
</blockquote>
</body>
</html>