<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<!--[if !mso]><style>v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style><![endif]--><style><!--
/* Font Definitions */
@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;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;
        mso-fareast-language:EN-US;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:#0563C1;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:#954F72;
        text-decoration:underline;}
p.MsoPlainText, li.MsoPlainText, div.MsoPlainText
        {mso-style-priority:99;
        mso-style-link:"Plain Text Char";
        margin:0cm;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;
        mso-fareast-language:EN-US;}
span.EmailStyle17
        {mso-style-type:personal-compose;
        font-family:"Calibri",sans-serif;
        color:windowtext;}
span.PlainTextChar
        {mso-style-name:"Plain Text Char";
        mso-style-priority:99;
        mso-style-link:"Plain Text";
        font-family:"Calibri",sans-serif;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-family:"Calibri",sans-serif;
        mso-fareast-language:EN-US;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:72.0pt 72.0pt 72.0pt 72.0pt;}
div.WordSection1
        {page:WordSection1;}
--></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]-->
</head>
<body lang="EN-GB" link="#0563C1" vlink="#954F72">
<div class="WordSection1">
<p class="MsoNormal">Hi everyone. <o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Hopefully this is a really easy fix and I’m just being dumb, but I can’t seem to solve me issue. I’m trying to import a DICOM image of a typical NEMA phantom to play with in Gate, and when I run my macro, I get the following error (at the
 bottom of the page for space reasons). I’ve based most of my macro off the examples in the readthedocs. My initial thoughts were maybe that some of the locations of the files was incorrect, but moving them around file structure hasn’t helped.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">I think the relevant part of my main.mac is: <o:p></o:p></p>
<p class="MsoPlainText">#patient image from voxel CT phantom (import image and convert HU to materials)
<o:p></o:p></p>
<p class="MsoPlainText">/gate/world/daughters/name patientCT <o:p></o:p></p>
<p class="MsoPlainText">/gate/world/daughters/insert ImageNestedParametrisedVolume
<o:p></o:p></p>
<p class="MsoPlainText">/gate/patientCT/geometry/setImage data/dcm/CTDataset/Series_3_CT_WB_3.0_B30f_Inst1.dcm<o:p></o:p></p>
<p class="MsoPlainText">/gate/patientCT/geometry/setRangeToMaterialFile data/patient_HU2Mat.dat
<o:p></o:p></p>
<p class="MsoPlainText">/gate/patientCT/geometry/setHUToMaterialFile data/patient_HU2Mat.dat<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Patient_HU2Mat.dat is only a couple of lines and is very similar to the example in the readthedocs, just adjusted for my CT of the NEMA phantom. I’ve tried different values for CT numbers, and it adjusts the error message accordingly (so
 I’m pretty confident that it is this file or part of the mac that is the issue). Air, Water and PMMA are definitely in GateMaterials.db file.<o:p></o:p></p>
<p class="MsoNormal">3<o:p></o:p></p>
<p class="MsoNormal">-1024 -51 Air<o:p></o:p></p>
<p class="MsoNormal">-50 50 Water<o:p></o:p></p>
<p class="MsoNormal">51 1338 PMMA <o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Error message:<o:p></o:p></p>
<p class="MsoNormal"><span style="color:black">[Core-0] *************************************************
</span><span style="font-size:12.0pt;color:black;mso-fareast-language:EN-GB"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">[Core-0] <o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">[Core-0] You are using Geant4 version 10.6.1<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">[Core-0] Starting macro mac/main.mac<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">I/O warning : failed to load external entity "./Materials.xml"<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">I/O warning: Discard the previous warning if your simulation doesn't transport OPTICAL PHOTONS.
<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">Otherwise, please copy the ./Materials.xml file from the gate-source directory in the directory where you run your main macro.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">[Physic-0] The following Geant4's physic-list is enabled :emStandard_opt4<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">[Core-0] Initialization of geometry<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">[Image-1]  Matrix Size= (500,500,348)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">[Image-1]  HalfSize= (250,250,174)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">[Image-1]  Resol= (512,512,174)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">[Image-1]  VoxelSize= (0.976563,0.976563,2)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">[Image-1]  Origin= (-250,-464,-981.5)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">[Image-1]  planeSize= 262144<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">[Image-1]  lineSize= 512<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">[Image-1]  nbOfValues= 45613056<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">[Image-1]  PixelSize= 4<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">[Image-1]  dataSize = 45613056<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">GateMaterialDatabase.cc (l.174): GateMaterialDatabase: could not find the definition for material '-51' in material files<o:p></o:p></span></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Thank you very any light you can shed on this.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><b><span style="color:#006871;mso-fareast-language:EN-GB">Mark Baker<o:p></o:p></span></b></p>
<p class="MsoNormal"><span style="color:#006871;mso-fareast-language:EN-GB">Clinical Scientist<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#006871;mso-fareast-language:EN-GB">Imaging Physics (Ionising)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#006871;mso-fareast-language:EN-GB">The Clatterbridge Cancer Centre NHS Foundation Trust<o:p></o:p></span></p>
<p class="MsoNormal"><b><span style="color:#006871;mso-fareast-language:EN-GB"><o:p> </o:p></span></b></p>
<p class="MsoNormal"><span style="color:#006871;mso-fareast-language:EN-GB">CCCW Tel:  0151 556 5030
<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#006871;mso-fareast-language:EN-GB">CCCL Tel: 0151 318 8438<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#006871;mso-fareast-language:EN-GB">Email:
</span><span style="color:#4472C4;mso-fareast-language:EN-GB"><a href="mailto:mark.baker23@nhs.net"><span style="color:#4472C4">mark.baker23@nhs.net</span></a></span><span style="color:#006871;mso-fareast-language:EN-GB">
<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#4472C4;mso-fareast-language:EN-GB"><a href="https://teams.microsoft.com/l/chat/0/0?users=mark.baker23@nhs.net"><span style="color:#4472C4">Microsoft Teams (click here)</span></a><o:p></o:p></span></p>
<p class="MsoNormal"><span style="mso-fareast-language:EN-GB"> <span style="color:#006871"><o:p></o:p></span></span></p>
<p class="MsoNormal"><i><span style="color:#006871;mso-fareast-language:EN-GB">Honorary Lecturer, Dept. of Physics<o:p></o:p></span></i></p>
<p class="MsoNormal"><i><span style="color:#006871;mso-fareast-language:EN-GB">University of Liverpool<o:p></o:p></span></i></p>
<p class="MsoNormal"><span style="color:#006871;mso-fareast-language:EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="mso-fareast-language:EN-GB"><img border="0" width="624" height="163" style="width:6.5in;height:1.6979in" id="Picture_x0020_3" src="cid:image003.jpg@01D7D6EF.E62E70D0" alt="CCC email footer April 2021"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="mso-fareast-language:EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<br>
<font face="Courier New" color="Black" size="2"><br>
************************************************************************************** ******************************<br>
<br>
This message may contain confidential information. If you are not the intended recipient please:<br>
i) inform the sender that you have received the message in error before deleting it; and
<br>
ii) do not disclose, copy or distribute information in this e-mail or take any action in relation to its content (to do so is strictly prohibited and may be unlawful).
<br>
Thank you for your co-operation.<br>
<br>
NHSmail is the secure email, collaboration and directory service available for all NHS staff in England. NHSmail is approved for exchanging patient data and other sensitive information with NHSmail and other accredited email services.<br>
<br>
For more information and to find out how you can switch visit <a href="https://support.nhs.net/article-categories/joining-nhsmail/">
Joining NHSmail – NHSmail Support</a><br>
<br>
</font>
</body>
</html>