2

0

1

3

May**29**

## Optimal-RANSAC

My main pages

Acknowledgement:Our Optimal-RANSAC was developed from the code by Peter Kovesi and is made publicly available with his consent.

The usage is explained in each file.

One major advantage with the code is that it is able to cope with very low inlier ratios, even below 5%! It will be much faster than the theoretical speed fur such sets. Nonetheless, it will be a bit slower for high inlier ratio sets, but it will still yield the optimal set in every run.

Acknowledgement:Our Optimal-RANSAC was developed from the code by Peter Kovesi and is made publicly available with his consent.

The usage is explained in each file.

## Description

Optimal-RANSAC finds the optimal set in almost every run and will therefore be repeatable as it yelds the same result.*However*it has some limitations. It works robustly for images with one plane only (hence only one model), e.g. for aerial images. It will yield the same result at least 99.95% of the times calledfor set with more than about 30 inliers. This number can be increased even further by demanding more equal results. Please see the last parameter*ner*(Number of Equal iteRations). If there are fewer inliers the parameter*ner*must be increased. When dealing with images taken on the ground of houses and similar it will sometimes yield different sets, all optimal with regard to the model it happens to find. Generally we have found that acc=1/(2 min(size(image)), and t=acc*8, produced reliable results.One major advantage with the code is that it is able to cope with very low inlier ratios, even below 5%! It will be much faster than the theoretical speed fur such sets. Nonetheless, it will be a bit slower for high inlier ratio sets, but it will still yield the optimal set in every run.

## Matlab Code

- optimalRansacfithomography.m Main code.
- optimalRansac.m Our implementation of RANSAC.
- homography2d.m We changed this function so that it will return an empty matrix instead of an error when the set is degenerate.
- sampleSet.m Sample the set until a non degenerate set is found. This was separated from optimalRansac.m to make the code more readable.
- resample.m Resamples the set. This code does both resampling and rescoring
- rescore.m Update the model and rescore the set until the set does not change anymore.
- pruneset.m Prunes the set using a lower threshold

is used instead of ransacfithomography.m

is used instead of ransac.m

is used instead of homography2d.m

*acc*.