I'm trying to obtain the deformation field between a fixed image and a moving image using ITK and I'm having trouble trying to read/view the output field.<br><br>The moving image is of a deformed object where different regions have different transformations (like in an inhomogeneous material).<br>
<br>I tried using the example code - DeformableRegistration5.cxx and the given data files (RatLungSlice1 & 2)<br>It let me save the deformation field only in vtk or mhd/mha format. <br>How do I obtain the vector of displacements over the region?<br>
<br>Paraview crashes when I try to open the mha file. <br>When I try the mhd file it fails and gives the following message.<br><font size="2"><i>ERROR: In c:\berk\releasebuilds\paraview3\vtk\common\vtkDataArrayTemplate.txx, line 133<br>
vtkFloatArray (05B871A8): Unable to allocate 1858633728 elements of size 4 bytes. </i><br>It also displays that the zrange is from -nan to nan<br><br>I also tried reading the *.raw files using what was mentioned in <a href="http://www.itk.org/pipermail/insight-users/2003-December/005865.html">http://www.itk.org/pipermail/insight-users/2003-December/005865.html</a> but that didn't help much.<br>
<br>I'm not sure about the following things-<br>Am I using the right example code to do what I am looking for?<br>Does ITK give the vector displacement field for registration between two images (with different transformation matrices at different regions)?<br>
Can the displacement field be output directly as a text file instead of a visual format?<br><br>I'd appreciate it if someone could point me in the right direction.<br><br>Thanks,<br>Ramesh<br></font><br><br>