Lab #1

09/27/04

Home
Lab #1
Lab #2

 

Reconstruction (Points) from Two Calibrated Views

bullet

Goals:
bullet

The goal of this session is to experiment with the 8-point algorithm of reconstruction (points) from two calibrated views.

bullet

Downloadable:

bullet

Download the file lab2.zip (88KB) under a local directory of yours.

bullet

Run unzip to extract all the files.

bullet

List of functions/data included in the file lab1.zip.

bullet

mp2.m  Frame code that you can use to start work with.

bullet

reconstruct_twoview.m An empty function. You need to add contents into this function to finish the reconstruction.

bullet

1.jpg - Image of the first view of the object

bullet

2.jpg - Image of the second view of the object

bullet

cube_data.mat  Data of points and correspondences of the two images and the calibration matrix.

bullet

Problem: Reconstruction (points) from two calibrated views.

bullet

The framework file mp2.m will load the two images and the data into Matlab. The images are not needed for reconstruction (unless you want to render the reconstructed result).

bullet

The feature points on the two images are stored in 3 by 45 matrices x1 and x2. There are 45 feature points on each image. Each column of the two matrices is a point in image coordinate (using homogenous coordinate representation). The corresponding two columns in two matrices are corresponding points.

bullet

The 3x3 calibration matrix is stored in the matrix called Calib.

bullet

You need to finish the function reconstruct_twoview.m to recontruct all the 45 feature points.

bullet

Important Hints:

bullet

Before going into the eight-point algorithm, you first need to transform all the points into calibrated coordinate by multiplying the inverse of the calibration matrix.

bullet

In order to avoid numerical problem, in the eight-point algorithm, you need to normalize the vectors by their mean and variance before doing SVD. For example, your normalization is xtemp1=K1*x1, xtemp2=K2*x2.  After geting the essential matrix Etemp for the normalized vectors, take E=K2'*Etemp*K1 to get the essential matrix E for the original vectors x1, x2.

bullet

In the eight point algorithm, you will get 4 solutions. Only one solution will give you  positive depth for ALL the reconstructed points. So unique reconstruction can be get by checking the sign of the depth.

bullet

The result should be similar like this. Check if the angle is a right angle.

bullet

Your Job.

bullet

Finish the reconstruct_twoview.m to reconstruct the points in 3-D.

bullet

Both your MATLAB codes and results must be turned in. If you insist on coding in C or C++, it is fine too. But you must include clear instructions on how to execute your files.

 

 

Home | Lab #1 | Lab #2

This site was last updated 09/27/04