<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta http-equiv="Content-Type" content="text/html;charset=ISO-8859-1">
  <title></title>
</head>
<body text="#000000" bgcolor="#ffffff">
Hi,<br>
<br>
after scanning the list on FEM - registration, I still have huge
problems <br>
to configure the paramters for my specific registration problem with
the FEM - method.<br>
<br>
I want to register two 3D MR 256^3 Thorax images with only small
deformation.<br>
The problem is, that however I set the parameters <b>elasticity</b>
and <b>rho / rhoc</b>,<br>
it doesn't deliver any useful results.<br>
<br>
I started with elasticity 100000 (even higher than in the examples),
but the image became completely<br>
deformed. Also, it spends only 2 iterations in the process (has this
something to do with<br>
the energyreductionfactor???) and after the registration, the metric (I
use SSD) is much bader then before.<br>
I think this should not be the case, after what I understood about the
theory behind this method.<br>
Also with elasticity 1000.000, it still gets completely deformed.<br>
With even higher the deformation decreases of course, but the
missregistration of the lungs is never<br>
caught (see middle of the images at the bottom of this message).<br>
<br>
Please note, that I don't use a config file but set all the parameters
manually.<br>
Also I wonder what's the meaning of the parameters alpha and gamma
(changing&nbsp; these doesn't<br>
seem to have a great effect on the result).<br>
<br>
Indeed, I call the following methods to setup the FEMRegistrationFilter
(public functions),<br>
while I didn't find a function to set the scaling, which is also used
in the config file (is this intended???): <br>
<font color="#ff0000"><br>
&nbsp; m_registrationFilter-&gt;SetFixedImage(m_fixedImage);<br>
&nbsp; m_registrationFilter-&gt;SetMovingImage(m_floatingImage);<br>
<br>
&nbsp; m_registrationFilter-&gt;DoMultiRes(true);&nbsp;&nbsp;&nbsp; <br>
<br>
&nbsp;
m_registrationFilter-&gt;SetMeshPixelsPerElementAtEachResolution(this-&gt;m_meshPixPerElement);<br>
<br>
&nbsp;
m_registrationFilter-&gt;SetNumberOfIntegrationPoints(this-&gt;m_numberOfIntegrationPoints);<br>
<br>
&nbsp; m_registrationFilter-&gt;SetRho(this-&gt;m_rho);<br>
<br>
&nbsp; m_registrationFilter-&gt;SetElasticity(this-&gt;m_elasticity);<br>
&nbsp; <br>
&nbsp; m_registrationFilter-&gt;SetGamma(this-&gt;m_gamma);<br>
&nbsp; <br>
&nbsp;
m_registrationFilter-&gt;SetWidthOfMetricRegion(this-&gt;m_widthOfMetricRegion);<br>
&nbsp; m_registrationFilter-&gt;ChooseMetric((int) this-&gt;m_metric);<br>
&nbsp;
m_registrationFilter-&gt;SetMaximumIterations(this-&gt;m_maxNumberOfIterations,0);<br>
<br>
&nbsp; m_registrationFilter-&gt;SetTimeStep(this-&gt;m_timestep);<br>
&nbsp;
m_registrationFilter-&gt;SetLineSearchMaximumIterations(this-&gt;m_maxLineSearchIterations);<br>
&nbsp;
m_registrationFilter-&gt;SetEnergyReductionFactor(this-&gt;m_energyReductionFactor);<br>
&nbsp; <br>
&nbsp; if(m_metric==3)
m_registrationFilter-&gt;SetDescentDirectionMaximize();<br>
&nbsp; else{ m_registrationFilter-&gt;SetDescentDirectionMinimize();}<br>
&nbsp; <br>
&nbsp; m_registrationFilter-&gt;SetAlpha(this-&gt;m_alpha);<br>
&nbsp; m_registrationFilter-&gt;DoLineSearch(2);<br>
&nbsp; m_registrationFilter-&gt;EmployRegridding(1);<br>
&nbsp; m_registrationFilter-&gt;UseLandmarks(false);<br>
&nbsp; m_registrationFilter-&gt;SetWriteDisplacements(false);</font><br>
<br>
Also what is about the material properties:<br>
Does it make sense to change something here??? <br>
<br>
&nbsp;<font color="#ff0000">itk::fem::MaterialLinearElasticity::Pointer m;<br>
&nbsp; m = itk::fem::MaterialLinearElasticity::New();<br>
&nbsp; m-&gt;GN = 0;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; // Global number of the material<br>
&nbsp; m-&gt;E = m_registrationFilter-&gt;GetElasticity();&nbsp; // Young's
modulus -- used in the membrane<br>
&nbsp; m-&gt;A = 1.0;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; // Cross-sectional area<br>
&nbsp; m-&gt;h = 1.0;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; // Thickness<br>
&nbsp; m-&gt;I = 1.0;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; // Moment of inertia<br>
&nbsp; m-&gt;nu = 0.;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; // Poisson's ratio -- DONT CHOOSE 1.0!!<br>
&nbsp; m-&gt;RhoC = this-&gt;m_density;&nbsp; // Density<br>
&nbsp; <br>
&nbsp; // Create the element type <br>
&nbsp; Element3DType::Pointer e1=Element3DType::New();<br>
&nbsp; e1-&gt;m_mat=dynamic_cast&lt;itk::fem::MaterialLinearElasticity*&gt;(
m );<br>
&nbsp; m_registrationFilter-&gt;SetElement(e1);<br>
&nbsp; m_registrationFilter-&gt;SetMaterial(m);</font><br>
<br>
<br>
Additionally, you can find some screenshots which show the problem and
the RegistrationFilter<br>
outputs here:<br>
<br>
<a class="moz-txt-link-freetext" href="http://www.markusweigert.de/images/E10%5E8_FEMRegOutput_iter2.jpg">http://www.markusweigert.de/images/E10%5E8_FEMRegOutput_iter2.jpg</a><br>
<a class="moz-txt-link-freetext" href="http://www.markusweigert.de/images/E10%5E8_FEMRegOutput_iter1.jpg">http://www.markusweigert.de/images/E10%5E8_FEMRegOutput_iter1.jpg</a><br>
<a class="moz-txt-link-freetext" href="http://www.markusweigert.de/images/before_registration.jpg">http://www.markusweigert.de/images/before_registration.jpg</a><br>
<a class="moz-txt-link-freetext" href="http://www.markusweigert.de/images/E10%5E8_FEMRegOutput_iter2.jpg">http://www.markusweigert.de/images/E10%5E8_FEMRegOutput_iter2.jpg</a><br>
<a class="moz-txt-link-freetext" href="http://www.markusweigert.de/images/result_E100000.jpg">http://www.markusweigert.de/images/result_E100000.jpg</a><br>
<a class="moz-txt-link-freetext" href="http://www.markusweigert.de/images/result_E1000000.jpg">http://www.markusweigert.de/images/result_E1000000.jpg</a><br>
<a class="moz-txt-link-freetext" href="http://www.markusweigert.de/images/result_E10000000.jpg">http://www.markusweigert.de/images/result_E10000000.jpg</a><br>
<br>
<br>
I hope somebody will have the time to answer at least some of my
questions.<br>
<br>
<br>
Best regards,<br>
Markus<br>
<br>
<br>
<br>
<br>
<br>
<br>
</body>
</html>