CSCI 497P/597P - Homework 3

Fall 2020

You may collaborate freely on this homework; the one rule is that you have to write up your own solutions.

Complete the following problems and submit your solutions to the HW3 assignment on Canvas. For all questions, justify your answers either or showing your work or giving a brief explanation. Please typeset your solutions using latex or similar; you may include neatly hand-drawn figures so long as the scan quality is good. You may work with your classmates on these problems, but you must write up your own solutions individually.

    1. (6 points) The following two arrays contain the descriptors of feature extracted from two images. The descriptors are 2-dimensional (much lower than we would usually use in pracice); each column of the matrix is the descriptor for a feature. In all of the following, use matrix-style (i, j) indexing with indices starting at 1. For example, feature 4 in image 1 has descriptor \(\begin{bmatrix}3 & 1\end{bmatrix}^T\). \[ F_1 = \begin{bmatrix} 0 & 1 & 4 & 3 \\ 1 & 0 & 4 & 1 \end{bmatrix}\\ \] \[ F_2 = \begin{bmatrix} 2 & 5 & 1\\ 1 & 5 & 2 \end{bmatrix} \]

      1. (2 points) Create a table with 4 rows and 3 columns in which the \((i,j)\)th cell contains the SSD distance between feature \(i\) in image 1 and image \(j\) in image 2.

      2. (2 points) For each feature in image 1, give the index of the closest feature match in image 2 using to the SSD metric.

      3. (2 points) For each feature in image 2, give the index of the closest feature match in image 1 and the ratio distance between each feature and its closest match.

  1. (9 points) In this problem, we’ll analyze the RANSAC algorithm to help us understand how to decide how many iterations to run (\(K\)). Suppose we are fitting some model that requires a minimal set of \(s\) points to fully determine (e.g., \(s=4\) matches for a homography, \(s=2\) points for a line). We also know (or have assumed) that the data has an inlier ratio of \(r = \frac{\text{# inliers}}{\text{# data points}}\); in other words, the probability that a randomly sampled point from the dataset as a probability of \(r\) of being an inlier.
    1. What is the probability that in a single iteration (i.e., one model hypothesis), at least one of the points chosen is an outier? (Hint: It may be helpful to start with the probability that no point is an outlier.)

    ​ P(chose at least one outlier in one iteration) =

    1. What is the probability that the above event - at least one outlier is chosen - happens in every one of \(K\) iterations of RANSAC?

    ​ P(never chose only inliers in any of K iterations) =

    1. What is the probability that the above event doesn’t happen? In other words, what is the probability that in at least one of the \(K\) trials, all \(s\) points were inliers?

    ​ P(at least one iteration chose all inliers) =

    1. Suppose that you want to be reasonably sure that RANSAC will succeed: you’d like the probability of success (i.e., the probability computed in the prior part) to be at least \(\mathbf{P}\). What \(K\) should you choose?