You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
RMSE Calculation in EvaluateRANSACBasedOnDistance MethodΒ #6291
First of all, thank you for your contributions to this great library!
This question might or might not turn into a minor bug. I was reading the code for EvaluateRANSACBasedOnDistance and I found the following formula: result.inlier_rmse_ = error / std::sqrt((double)inlier_num);
However, error is collected by adding absolute values (as opposed to squared):
Given how the error is accumulated I was expecting to find a mean absolute error. Is there any reason for the denominator to be the square root of the sample size rather than just the sample size? I might be missing something (or maybe it is indeed a minor bug) so any ideas are welcome.
Glad to be helpful! I'd be happy to do a PR with some guidance. Specifically, do you think the error should be squared during accumulation or averaged later by the number of samples? Also, is there a reference paper based on which this routine was implemented?
Activity
theNded commentedon Aug 10, 2023
This is a good catch! I think it is a bug. I will mark it on my TODO list and fix it.
pherrusa7 commentedon Aug 10, 2023
Glad to be helpful! I'd be happy to do a PR with some guidance. Specifically, do you think the error should be squared during accumulation or averaged later by the number of samples? Also, is there a reference paper based on which this routine was implemented?
theNded commentedon Aug 11, 2023
They should be squared. I think it is relatively a trivial problem now and can be traced back to 2000s. MATLAB has a reference list: https://www.mathworks.com/help/vision/ref/pcfitplane.html
pherrusa7 commentedon Aug 11, 2023
Yes, that makes sense. I see that you already made the changes so it is done. Thank you!
Fixes #6291 and #6236 (#6305)