RANSAC - Control over sampled data points

8 views (last 30 days)
Carl Stahoviak
Carl Stahoviak on 5 Apr 2019
Answered: Star Strider on 5 Apr 2019
Hi,
I'm running into a problem using the Matlab RANSAC (is it actually MLESAC as cited on the documentation page?) implementation.
For the data that I'm working with, my model is uniquely determined for 2 data points (sampleSize = 2) such that the model parameters are estimated via matrix inversion as (or using Matlab's ). Where and . This looks like:
The problem is that the data I'm working with is the output of a sensor that bins the values into a set of 64 angular bins. And so for some samples, I get and thus A is singular and the matrix inversion cannot be done.
However, this does not indicate that either data point 1 or data point 2 are outliers, just that these two points are not a good sample.
Is there any way in which I can reject a sample generated by RANSAC based on user-determined criteria (in this case if )?
Thank you,
Carl

Answers (1)

Star Strider
Star Strider on 5 Apr 2019
Try using the lsqr (link) function. It’s intended for sparse matrices, however it gave a finite result when I tested it with your model and . Another option is the pinv (link) function. Both gave the same result.

Products


Release

R2018a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!