<div dir="ltr"><div>Dear Users,</div><div>Anyone who wants to reproduce my problem can directly go to google drive. Here is the link to the problem. <br></div><div><a href="https://drive.google.com/drive/folders/1r2LPzE7KLZX0-kfVTNaQyWADLgelVdR9?usp=sharing">https://drive.google.com/drive/folders/1r2LPzE7KLZX0-kfVTNaQyWADLgelVdR9?usp=sharing</a></div><div>Regards</div><div>Atiq<br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Jul 8, 2021 at 4:05 AM Atiq Ur Rahman <<a href="mailto:atiqchep@gmail.com">atiqchep@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div><font size="4">Dear Gate users,</font></div><div><font size="4">I am trying to calculate the dose for the CT based Phantom (512x512x361 matrix) using a proton beam. I read dicom images directly and define the HU to material conversion file. I am using the vGate.8 virtual machine.<br></font></div><div><font size="4"><b><span style="color:rgb(255,0,0)">Problem:</span></b> If I define only three materials (vacuum, Air and TissueEquivalent ) the simulation gives output for 1000 primaries very fast in a couple of seconds and I can get the output. But if I define one extra material (any material, I have tried different materials) , let say (Vacuum, Air, TissueEquvalent, Liver) the simulation runs for a very very long time even for 1 primary particle (Actually does not finish even in 10 hours). Can you give me some suggestions to fix the problem. What is the possible cause of the problem? There seems to be something wrong with my approach. I have shared my code below. I have 306 Dicom images put in a single directory. <br></font></div><div><font size="4"><span style="color:rgb(0,0,255)">Definition of the HUToMat.txt </span><br></font></div><br><div><font size="4">-2000 -800 Vacuum<br>-800 -40 Air<br>-40 200 Blood<br>200 19000 TissueEquivalent</font></div><div><font size="4"><br></font></div><div><font size="4"><span style="color:rgb(0,0,255)">#CODE</span><br></font></div><div><span style="color:rgb(255,0,0)">/<b><font size="4">control/execute mac/verbose.mac<br>/gate/geometry/setMaterialDatabase data/GateMaterials.db<br></font></b></span></div><div><span style="color:rgb(255,0,0)"><b><font size="4"><span style="color:rgb(0,0,255)">#WorldVolume</span><br></font></b></span></div><div><span style="color:rgb(255,0,0)"><b><font size="4">/gate/world/setMaterial Vacuum<br>/gate/world/geometry/setXLength 100 cm<br>/gate/world/geometry/setYLength 100 cm<br>/gate/world/geometry/setZLength 100 cm<br><br>/gate/world/daughters/name Pat<br>/gate/world/daughters/insert box<br>/gate/Pat/geometry/setXLength 32 cm<br>/gate/Pat/geometry/setYLength 32 cm<br>/gate/Pat/geometry/setZLength 32 cm</font></b></span></div><div><span style="color:rgb(255,0,0)"><b><font size="4"><span style="color:rgb(0,0,255)">#Daughter for DICOM</span><br></font></b></span></div><div><span style="color:rgb(255,0,0)"><b><font size="4">/gate/Pat/daughters/name Volume<br>/gate/Pat/daughters/insert ImageRegularParametrisedVolume # ImageNestedParametrisedVolume <br></font></b></span></div><div><span style="color:rgb(255,0,0)"><b><font size="4">#CoversionFile<br></font></b></span></div><div><span style="color:rgb(255,0,0)"><b><font size="4">/gate/Volume/geometry/setHUToMaterialFile data/HUToMat.txt </font></b></span></div><div><b><font size="4"><span style="color:rgb(255,0,0)">/gate/Volume/geometry/setImage New_CODE/data/dcm/1.dcm #<br>/gate/Volume/placement/setRotationAxis 0 -1 0<br>/gate/Volume/placement/setRotationAngle 90 deg<br>/gate/Volume/setSkipEqualMaterials 1<br></span></font></b></div><div><b><font size="4"><span style="color:rgb(255,0,0)"><br></span></font></b></div><div><b><font size="4"><span style="color:rgb(255,0,0)"><span style="color:rgb(0,0,255)">#SIMPLEDOSEActor</span><br></span></font></b></div><div><b><font size="4"><span style="color:rgb(255,0,0)">/gate/actor/addActor DoseActor doseDistribution_text<br>/gate/actor/doseDistribution_text/save output/Dose_Map_Energy_MeV_1D_5material.root<br>/gate/actor/doseDistribution_text/attachTo Volume #PMMA_Block<br>/gate/actor/doseDistribution_text/stepHitType random<br>/gate/actor/doseDistribution_text/setSize 300 300 300 mm<br>/gate/actor/doseDistribution_text/setResolution 1280 1 1<br>/gate/actor/doseDistribution_text/enableEdep true<br>/gate/actor/doseDistribution_text/enableUncertaintyEdep true<br>/gate/actor/doseDistribution_text/enableDose true<br>/gate/actor/doseDistribution_text/enableUncertaintyDose true<br>/gate/actor/doseDistribution_text/enableNumberOfHits true</span></font></b></div><div><b><font size="4"><span style="color:rgb(255,0,0)"><br></span></font></b></div><div><b><font size="4"><span style="color:rgb(255,0,0)"><span style="color:rgb(0,0,255)">#PhysicsList</span><br>/gate/physics/addPhysicsList QGSP_BIC_HP_EMZ<br><span style="color:rgb(0,0,255)">#Cuts</span><br>/gate/physics/Gamma/SetCutInRegion world 10 mm<br>/gate/physics/Electron/SetCutInRegion world 10 mm<br>/gate/physics/Positron/SetCutInRegion world 10 mm<br>/gate/physics/Proton/SetCutInRegion world 10 mm<br>/gate/physics/Gamma/SetCutInRegion Pat 1 mm<br>/gate/physics/Electron/SetCutInRegion Pat 1 mm<br>/gate/physics/Positron/SetCutInRegion Pat 1 mm<br>/gate/physics/Proton/SetCutInRegion Pat 1 mm<br>/gate/physics/SetMaxStepSizeInRegion Pat 1 mm<br>/gate/physics/ActivateStepLimiter proton<br>/gate/physics/displayCuts</span></font></b></div><div><b><font size="4"><span style="color:rgb(255,0,0)"><br></span></font></b></div><div><b><font size="4"><span style="color:rgb(255,0,0)">/gate/run/initialize<br>/gate/random/setEngineName MersenneTwister<br>/gate/random/setEngineSeed auto<br><span style="color:rgb(0,0,255)">#Source</span><br>/gate/source/addSource PBS PencilBeam<br>/gate/source/PBS/setParticleType proton<br>/gate/source/PBS/setEnergy 90 MeV<br>/gate/source/PBS/setSigmaEnergy .88 MeV<br>/gate/source/PBS/setPosition 0 0 -36.5 cm <br>/gate/source/PBS/setSigmaX 3.0 mm <br>/gate/source/PBS/setSigmaY 3.0 mm <br>#/gate/source/PBS/setRotationAxis 0 1 0<br>#/gate/source/PBS/setRotationAngle 90 deg<br>/gate/source/PBS/setSigmaTheta 20 mrad<br>/gate/source/PBS/setSigmaPhi 20 mrad <br>/gate/source/PBS/setEllipseXThetaEmittance 40 mm*mrad #40 mm*mrad, 2mm*mrad<br>/gate/source/PBS/setEllipseYPhiEmittance 40 mm*mrad #40 mm*mrad, 2mm*mrad<br>#positive-> converging beam; negative diverging beam<br>/gate/source/PBS/setEllipseXThetaRotationNorm positive<br>/gate/source/PBS/setEllipseYPhiRotationNorm positive<br>/gate/application/setTotalNumberOfPrimaries 1000 <br>/gate/application/start</span></font></b></div><div><b><font size="4"><span style="color:rgb(255,0,0)"><br></span></font></b></div><div><span style="color:rgb(0,0,0)"><b><font size="4">I have dumped this file into single density (.mhd +.raw) format and tried to read it from a single density file but it has no difference in performance. Below is the information in the header file.</font></b></span></div><div><b><font size="4"><span style="color:rgb(255,0,0)"><br></span></font></b></div><div><b><font size="4"><span style="color:rgb(255,0,0)">ObjectType = Image<br>NDims = 3<br>BinaryData = True<br>BinaryDataByteOrderMSB = False<br>CompressedData = False<br>TransformMatrix = 1 0 0 0 1 0 0 0 1<br>Offset = -151.494 -36.6564 1115<br>CenterOfRotation = 0 0 0<br>ElementSpacing = 0.589844 0.589844 0.5<br>DimSize = 512 512 361<br>AnatomicalOrientation = ???<br>ElementType = MET_FLOAT<br>ElementDataFile = density-ffs-dcm_5mat.raw<br></span></font></b></div><div><span style="color:rgb(68,68,68)"><b><font size="4">Please ask me any further details if you feel anything ambiguous. Your suggestions and solutions are needed. Thank you in advance!<br></font></b></span></div><div><span style="color:rgb(68,68,68)"><b><font size="4">Regards</font></b></span></div><div><b><font size="4"><span style="color:rgb(255,0,0)"><span style="color:rgb(68,68,68)">Atiq</span><br></span></font></b></div><div><b><font size="4"><span style="color:rgb(255,0,0)"><br> </span></font></b></div></div>
</blockquote></div></div>