$29
This assignment contains several problems in which you have to use MATLAB. Your deliverable should be in the form of a document in which you describe what you did in each problem and why. Include all your relevant code segments as well as your explanations and results figures.
Zip all the scripts for each problem, named by the problem number, and upload them along with your report.
There is a bonus problem in the assignment that can earn you up to 20% additional points. This is a bonus both for graduate and undergraduate students and is not required to earn full credit.
Problem 1. [100 points] In this problem, you are required to calibrate your phone camera.
a) [30 points] Take image of a calibration object with your camera phone. Choose an appropriate calibration object so that the world points on that object span a 3-dimensional space, and the image points are easy to mark. Place the calibration object on a horizontal plane, such as a tabletop, or floor, to take the image. Mark at least 25 image points as carefully as possible and establish their world coordinates in millimeters.
From this data, compute the camera matrix P. Show the original points and the back-projected camera points on a single image and compute the average re-projection error.
b) [10 points] Experiment with ways to improve the accuracy of your calibration, and assess the accuracy of your calibration. Repeat the experiment if necessary so that the re-projection error is as small as possible.
c) [9 points] Compute camera center C, intrinsic matrix K and Rotation matrix R. Generate a 3D figure which shows the calibration points, the camera center and the orientation of the camera in 3D. [You can use the RQ decomposition code by Bruno Luong available at this link: https://www.mathworks.com/matlabcentral/newsreader/view_thread/237007. A useful MATLAB function to generate 3D plot is plot3]
d) [6 points] Search for the sensor information of your camera on the web. From this information, compute the focal length in mm. Also compute the angle between the image axes.
The following link may be useful to look up sensor information: https://www.ephotozine.com/article/complete-guide-to-image-sensor-pixel-size-29652
e) [5 points] Plot the principal point of the camera on the image, to see how far away it is from the image center.
f) [8 points] Establish the horizon line of the world ground plane in your image. Also mark the world origin computed from the matrix P.
g) [12 points] Compute the tilt angle of your camera with respect to the ground plane. Consider that your camera was in the canonical view. Find the equation of the ground plane in this camera frame.
h) [10 points] Find the coordinates of the principal point in 3D.
i) [10 points] Find the pixel coordinates of the left most and the right most point of your calibration object. Compute the rays that these points cast in the world. Find the angle between those rays to determine the angle that the width of the calibration object subtends on the camera center.
[Challenge Problem: BONUS 20 points] The image below shows an artist’s sketch of Sultan Ahmet Mosque, also known as the Blue Mosque, in Istanbul.
Assuming that the artist has created a geometrically correct rendering, your task is to find the latitude / longitude coordinates on a map, as accurately as possible, of where the artist was standing when the drawing was created. Show your result on a map by drawing a triangle on the map that represents the viewpoint of this sketch.