ROS Answers: Open Source Q&A Forum - RSS feedhttps://answers.ros.org/questions/Open source question and answer forum written in Python and DjangoenROS Answers is licensed under Creative Commons Attribution 3.0Mon, 25 Feb 2013 15:31:28 -0600What does setOptimizeCoefficients do in SACSegmentationhttps://answers.ros.org/question/55223/what-does-setoptimizecoefficients-do-in-sacsegmentation/I followed the tutorial about Segmentation in PCL and wondered what setOptimizeCoefficients does. In the tutorial the only comment is that it is optional and in the documentation I am told to set this parameter if a coefficient refinement is required. I am still not really what that is supposed to mean. Can anybody explain that to me?
Thanks in advance
KaiThu, 14 Feb 2013 05:58:01 -0600https://answers.ros.org/question/55223/what-does-setoptimizecoefficients-do-in-sacsegmentation/Answer by astaranowicz for <p>I followed the tutorial about Segmentation in PCL and wondered what setOptimizeCoefficients does. In the tutorial the only comment is that it is optional and in the documentation I am told to set this parameter if a coefficient refinement is required. I am still not really what that is supposed to mean. Can anybody explain that to me?</p>
<p>Thanks in advance</p>
<p>Kai</p>
https://answers.ros.org/question/55223/what-does-setoptimizecoefficients-do-in-sacsegmentation/?answer=56273#post-id-56273I'll try to explain using an example from my experience.
The plane's parameters is the normal and the distance to the plane from a fixed reference frame. The model's (plane) coefficients, in this case, are the normal vector (x,y,z) and the offset.
The model's coefficients are estimated using a least-squares method inside RANSAC to find the best-fit model. Once those coefficients are found; an optimization is performed over the estimated coefficients to minimize or reduce the mean-squared-error with respect the all of the 3D points.
The optimization a bit longer and can fail if you have a large percentage of outliers.
This method is optional due to the fact that if you know you have no outliers and no noise, then the least-squares solution will be the same as the optimized (refined) solution. (Saves computational time)
However, if you know that your points are affected by noise and you had to remove outliers, then optimizing the model's coefficients will give a better solution with respect to the least-squares solution. (More time, but better solution)
Its a trade-off between time and quality of the solution.Mon, 25 Feb 2013 13:42:55 -0600https://answers.ros.org/question/55223/what-does-setoptimizecoefficients-do-in-sacsegmentation/?answer=56273#post-id-56273Comment by kalectro for <p>I'll try to explain using an example from my experience.</p>
<p>The plane's parameters is the normal and the distance to the plane from a fixed reference frame. The model's (plane) coefficients, in this case, are the normal vector (x,y,z) and the offset.</p>
<p>The model's coefficients are estimated using a least-squares method inside RANSAC to find the best-fit model. Once those coefficients are found; an optimization is performed over the estimated coefficients to minimize or reduce the mean-squared-error with respect the all of the 3D points.</p>
<p>The optimization a bit longer and can fail if you have a large percentage of outliers.</p>
<p>This method is optional due to the fact that if you know you have no outliers and no noise, then the least-squares solution will be the same as the optimized (refined) solution. (Saves computational time) </p>
<p>However, if you know that your points are affected by noise and you had to remove outliers, then optimizing the model's coefficients will give a better solution with respect to the least-squares solution. (More time, but better solution)</p>
<p>Its a trade-off between time and quality of the solution.</p>
https://answers.ros.org/question/55223/what-does-setoptimizecoefficients-do-in-sacsegmentation/?comment=56278#post-id-56278thank you for this great explanation. I was hoping that this option would perform something like that.Mon, 25 Feb 2013 15:31:28 -0600https://answers.ros.org/question/55223/what-does-setoptimizecoefficients-do-in-sacsegmentation/?comment=56278#post-id-56278