All 2D registration example work perfectly fine. Problems seem to arise in 3D. <br><br>1. Am I using the prohibited file type (hdr)? I google that a little. hdr seems to be acceptable for ITK. <br>2. What about the data type? float, byte, etc. ? I think I'd tried several different data types but none of them worked well. <br>
3. Should I restrict the intensity level images to a certain range (e.g. 1 to 225)? I did try but I still got the same error. <br><br>I can't think of any other possibilities. Could anyone give me some help?<br><br>Thank you,<br>
stephen <br><br>P.S. In case you found my previous message confusing. I've modified that below. <br><div class="gmail_quote"><div><br> </div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
I am using DeformableRegsitration11.cxx to compute 3D image registration. Does anyone know how I may fix the problem? <br><br>I keep getting the error message: <br><span style="color: rgb(255, 0, 0);">Reading config file...A3.txt </span><br style="color: rgb(255, 0, 0);">
<span style="color: rgb(255, 0, 0);">Example configured. E 3 rho 3 </span><br style="color: rgb(255, 0, 0);"><span style="color: rgb(255, 0, 0);"> reading moving </span><br style="color: rgb(255, 0, 0);"><span style="color: rgb(255, 0, 0);"> reading fixed </span><br style="color: rgb(255, 0, 0);">
<span style="color: rgb(255, 0, 0);">Exception caught during reference file reading </span><br style="color: rgb(255, 0, 0);"><br><br style="color: rgb(255, 0, 0);"><span style="color: rgb(255, 0, 0);">itk::ImageFileReaderException (015BF9CC) </span><br style="color: rgb(255, 0, 0);">
<span style="color: rgb(255, 0, 0);">Location: "void __thiscall itk::ImageFileReader<class itk::Image<unsigned char,3>,class itk::DefaultConvertPixelTraits<unsigned char> >::GenerateOutputInformation(void)" </span><br style="color: rgb(255, 0, 0);">
<span style="color: rgb(255, 0, 0);">File: c:\itk\src\code\io\itkImageFileReader.txx </span><br style="color: rgb(255, 0, 0);"><span style="color: rgb(255, 0, 0);">Line: 100 </span><br style="color: rgb(255, 0, 0);"><span style="color: rgb(255, 0, 0);">Description: FileName must be specified </span><br style="color: rgb(0, 0, 153);">
<br style="color: rgb(0, 0, 153);">Below is what I have in my parameter file. <br style="color: rgb(0, 0, 153);"><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);">% Parameters for the single- or multi-resolution techniques</span><br style="color: rgb(0, 0, 153);">
<span style="color: rgb(0, 0, 153);">% ---------------------------------------------------------</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);">1 % Number of levels in the multi-res pyramid (1 = single-res)</span><br style="color: rgb(0, 0, 153);">
<span style="color: rgb(0, 0, 153);">1 % Highest level to use in the pyramid</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);">1 1 1 % Scaling at lowest level of pyramid</span><br style="color: rgb(0, 0, 153);">
<span style="color: rgb(0, 0, 153);">3 3 3 % Number of pixels per element</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);">1.e4 1.e4 1.e4 % Elasticity (E)</span><br style="color: rgb(0, 0, 153);">
<span style="color: rgb(0, 0, 153);">1.e5 1.e5 1.e5 % Density x capacity (RhoC)</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);">1 % Image energy scaling (gamma) - sets gradient step size 3 3 3 % NumberOfIntegrationPoints</span><br style="color: rgb(0, 0, 153);">
<span style="color: rgb(0, 0, 153);">3 % WidthOfMetricRegion</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);">30 % MaximumIterations</span><br style="color: rgb(0, 0, 153);"><br style="color: rgb(0, 0, 153);">
<span style="color: rgb(0, 0, 153);">% -------------------------------</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);">% Parameters for the registration</span><br style="color: rgb(0, 0, 153);">
<span style="color: rgb(0, 0, 153);">% -------------------------------</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);">0 0.99 % Similarity metric (0=mean sq, 1 = ncc, 2=pattern int, 3=MI, 5=demons)</span><br style="color: rgb(0, 0, 153);">
<span style="color: rgb(0, 0, 153);">1.0 % Alpha</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);">0 % DescentDirection (1 = max, 0 = min)</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);">0 % DoLineSearch (0=never, 1=always, 2=if needed)</span><br style="color: rgb(0, 0, 153);">
<span style="color: rgb(0, 0, 153);">1.e1 % TimeStep</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);">0.5 % Landmark variance</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);">0 % Employ regridding / enforce diffeomorphism ( >= 1 -> true)</span><br style="color: rgb(0, 0, 153);">
<span style="color: rgb(0, 0, 153);">% ----------------------------------</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);">% Information about the image inputs</span><br style="color: rgb(0, 0, 153);">
<span style="color: rgb(0, 0, 153);">% ----------------------------------</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);">101 % Nx (image x dimension)</span><br style="color: rgb(0, 0, 153);">
<span style="color: rgb(0, 0, 153);">101 % Ny (image y dimension)</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);">30 % Nz (image z dimension - not used if 2D)</span><br style="color: rgb(0, 0, 153);">
<span style="color: rgb(0, 0, 153);">G:\ITK_test\deform11\deform11\Debug\A.hdr % ReferenceFileName </span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);">G:\ITK_test\deform11\deform11\Debug\B.hdr % TargetFileName</span><br style="color: rgb(0, 0, 153);">
<span style="color: rgb(0, 0, 153);">% -------------------------------------------------------------------</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);">% The actions below depend on the values of the flags preceding them.</span><br style="color: rgb(0, 0, 153);">
<span style="color: rgb(0, 0, 153);">% For example, to write out the displacement fields, you have to set</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);">% the value of WriteDisplacementField to 1.</span><br style="color: rgb(0, 0, 153);">
<span style="color: rgb(0, 0, 153);">% -------------------------------------------------------------------</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);">0 % UseLandmarks? - read the file name below if this is true</span><br style="color: rgb(0, 0, 153);">
<span style="color: rgb(0, 0, 153);">- % LandmarkFileName</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);">G:\ITK_test\deform11\deform11\Debug\D % ResultsFileName (prefix only)</span><br style="color: rgb(0, 0, 153);">
<span style="color: rgb(0, 0, 153);">1 % WriteDisplacementField?</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);">G:\ITK_test\deform11\deform11\Debug\D % DisplacementsFileName (prefix only)</span><br style="color: rgb(0, 0, 153);">
<span style="color: rgb(0, 0, 153);">0 % ReadMeshFile?</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);">- % MeshFileName</span><br style="color: rgb(0, 0, 153);">
<span style="color: rgb(0, 0, 153);">END</span><br style="color: rgb(0, 0, 153);"><br style="color: rgb(0, 0, 153);"><br>
</blockquote></div><br>