<div dir="ltr">Hi, <br><br>We are currently trying to convert files in .xim-format to .mha-format by using RTK in Python. Our code is as follows:<br><pre style="color:rgb(0,0,0);background-image:initial;background-position:initial;background-size:initial;background-repeat:initial;background-origin:initial;background-clip:initial"><span style="color:rgb(128,0,0);font-weight:bold">import</span> sys
<span style="color:rgb(128,0,0);font-weight:bold">import</span> itk
<span style="color:rgb(128,0,0);font-weight:bold">from</span> itk <span style="color:rgb(128,0,0);font-weight:bold">import</span> RTK <span style="color:rgb(128,0,0);font-weight:bold">as</span> rtk
<span style="color:rgb(128,0,0);font-weight:bold">import</span> inspect
CPUImageType <span style="color:rgb(128,128,48)">=</span> rtk<span style="color:rgb(128,128,48)">.</span>Image<span style="color:rgb(128,128,48)">[</span>itk<span style="color:rgb(128,128,48)">.</span>F<span style="color:rgb(128,128,48)">,</span><span style="color:rgb(0,140,0)">2</span><span style="color:rgb(128,128,48)">]</span>
reader <span style="color:rgb(128,128,48)">=</span> itk<span style="color:rgb(128,128,48)">.</span>ProjectionsReader<span style="color:rgb(128,128,48)">[</span>CPUImageType<span style="color:rgb(128,128,48)">]</span><span style="color:rgb(128,128,48)">.</span>New<span style="color:rgb(128,128,48)">(</span><span style="color:rgb(128,128,48)">)</span>
reader<span style="color:rgb(128,128,48)">.</span>SetFileNames<span style="color:rgb(128,128,48)">(</span><span style="color:rgb(0,0,230)">"C:/xxx/Proj_0001.xim"</span><span style="color:rgb(128,128,48)">)</span>
reader<span style="color:rgb(128,128,48)">.</span>SetDebug<span style="color:rgb(128,128,48)">(</span><span style="color:rgb(7,71,38)">True</span><span style="color:rgb(128,128,48)">)</span>
<span style="color:rgb(128,0,0);font-weight:bold">print</span><span style="color:rgb(128,128,48)">(</span><span style="color:rgb(0,0,230)">"Updating..."</span><span style="color:rgb(128,128,48)">)</span>
reader<span style="color:rgb(128,128,48)">.</span>Update<span style="color:rgb(128,128,48)">(</span><span style="color:rgb(128,128,48)">)</span>
<span style="color:rgb(128,0,0);font-weight:bold">print</span><span style="color:rgb(128,128,48)">(</span><span style="color:rgb(0,0,230)">"Update done"</span><span style="color:rgb(128,128,48)">)</span>
img <span style="color:rgb(128,128,48)">=</span> reader<span style="color:rgb(128,128,48)">.</span>GetOutput<span style="color:rgb(128,128,48)">(</span><span style="color:rgb(128,128,48)">)<br></span></pre><pre style="color:rgb(0,0,0);background-image:initial;background-position:initial;background-size:initial;background-repeat:initial;background-origin:initial;background-clip:initial"><span style="font-family:Arial,Helvetica,sans-serif">For some reason Update() crashes without any stacktrace. Does anyone have any idea why this is happening?
Best regards, </span></pre><pre style="color:rgb(0,0,0);background-image:initial;background-position:initial;background-size:initial;background-repeat:initial;background-origin:initial;background-clip:initial"><span style="font-family:Arial,Helvetica,sans-serif">Christian Mørup</span></pre></div>