<HTML><BODY style="word-wrap: break-word; -khtml-nbsp-mode: space; -khtml-line-break: after-white-space; "><BR><DIV><BLOCKQUOTE type="cite"><DIV>Hi Markus,</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>The registration scenario you describe seems reasonably straightforward. However, there are a couple of items I noticed from the images that you might want to change. Generally, you want to keep alpha = 0.5 (as opposed to 1.0) so that the solution is stable for the time step that you choose. The chosen material governs the regularization of your registration results. The default values that I have are Elasticity = 1.0e4 and Rho = 1.0e4 which give me reasonable registration results. You should be able to achieve reasonable results using the specified elastic material. Unfortunately, without running the registration myself, it is difficult to know exactly what the problem is. </DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>On a related note, it is interesting that you chose to forgo the .config file. I actually rewrote the itkFEMRegistrationFilter and plan to include it in an upcoming release along with additional modifications and extensions to the library (including B-spline elements). The first thing I got rid of was the .config file along with some parameters that weren't being used.</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>Nick Tustison </DIV><BR></BLOCKQUOTE><DIV><BR class="khtml-block-placeholder"></DIV><BR><BLOCKQUOTE type="cite"><DIV><DIV>On Apr 6, 2006, at 7:36 AM, Markus Weigert wrote:</DIV><BR class="Apple-interchange-newline"><BLOCKQUOTE type="cite"> 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 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> m_registrationFilter->SetFixedImage(m_fixedImage);<BR> m_registrationFilter->SetMovingImage(m_floatingImage);<BR> <BR> m_registrationFilter->DoMultiRes(true); <BR> <BR> m_registrationFilter->SetMeshPixelsPerElementAtEachResolution(this->m_meshPixPerElement);<BR> <BR> m_registrationFilter->SetNumberOfIntegrationPoints(this->m_numberOfIntegrationPoints);<BR> <BR> m_registrationFilter->SetRho(this->m_rho);<BR> <BR> m_registrationFilter->SetElasticity(this->m_elasticity);<BR> <BR> m_registrationFilter->SetGamma(this->m_gamma);<BR> <BR> m_registrationFilter->SetWidthOfMetricRegion(this->m_widthOfMetricRegion);<BR> m_registrationFilter->ChooseMetric((int) this->m_metric);<BR> m_registrationFilter->SetMaximumIterations(this->m_maxNumberOfIterations,0);<BR> <BR> m_registrationFilter->SetTimeStep(this->m_timestep);<BR> m_registrationFilter->SetLineSearchMaximumIterations(this->m_maxLineSearchIterations);<BR> m_registrationFilter->SetEnergyReductionFactor(this->m_energyReductionFactor);<BR> <BR> if(m_metric==3) m_registrationFilter->SetDescentDirectionMaximize();<BR> else{ m_registrationFilter->SetDescentDirectionMinimize();}<BR> <BR> m_registrationFilter->SetAlpha(this->m_alpha);<BR> m_registrationFilter->DoLineSearch(2);<BR> m_registrationFilter->EmployRegridding(1);<BR> m_registrationFilter->UseLandmarks(false);<BR> m_registrationFilter->SetWriteDisplacements(false);</FONT><BR> <BR> Also what is about the material properties:<BR> Does it make sense to change something here??? <BR> <BR> <FONT color="#ff0000">itk::fem::MaterialLinearElasticity::Pointer m;<BR> m = itk::fem::MaterialLinearElasticity::New();<BR> m->GN = 0; // Global number of the material<BR> m->E = m_registrationFilter->GetElasticity(); // Young's modulus -- used in the membrane<BR> m->A = 1.0; // Cross-sectional area<BR> m->h = 1.0; // Thickness<BR> m->I = 1.0; // Moment of inertia<BR> m->nu = 0.; // Poisson's ratio -- DONT CHOOSE 1.0!!<BR> m->RhoC = this->m_density; // Density<BR> <BR> // Create the element type <BR> Element3DType::Pointer e1=Element3DType::New();<BR> e1->m_mat=dynamic_cast<itk::fem::MaterialLinearElasticity*>( m );<BR> m_registrationFilter->SetElement(e1);<BR> m_registrationFilter->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><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">_______________________________________________</DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">Insight-users mailing list</DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><A href="mailto:Insight-users@itk.org">Insight-users@itk.org</A></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><A href="http://www.itk.org/mailman/listinfo/insight-users">http://www.itk.org/mailman/listinfo/insight-users</A></DIV> </BLOCKQUOTE></DIV><BR></BLOCKQUOTE></DIV><BR></BODY></HTML>