Pre-processing, Tilt correction, Cont'd
- I developed the simple code for unsupervised tilt correction(perspective correction?) of panoramic image.
- First the "Line segment detector" in vpdetection library has been applied on each panoramic image
- By calculating the slope of line segments, define the subset of line segments that can be considered as vertical line segments.
Vertical line segments are indicated as red line
|
Amount of tilt in original image. Mean : 1.6431 |
- Like described in the previous post, each pixel of the image can be mapped to the point on the unit sphere, so calculate the mapped point of all start and end points.
- Then find lambda(rotation angle along x axis) and phi(rotation angle along y axis) that is argmin for the sum of amount of tilt for vertical line segments.
- Apply rotation to the entire image by given lambda and phi.
Amount of tilt in rotated image. Mean : 1.0062 |
No comments:
Post a Comment