【自动驾驶传感器——摄像头】

目录

自动驾驶汽车中的摄像头应用

摄像头的局限性 Limitations

畸变 Distortion

畸变类型 Types of Distortion

畸变系数和校正 Distortion Coefficients and Correction

径向畸变校正 Radial distortion correction

切向畸变校正 Tangential distortion correction


自动驾驶汽车中的摄像头应用

1、高分辨率传感器 High resolution sensor

2、颜色光线特征识别 Color/Optical character recognition

3、双目摄像头深度重建 Depth reconstruction with stereo camera

4、时间空间效率 Cost/Space efficient


摄像头的局限性 Limitations

1、对天气敏感 Sensitive to weather

2、信息需要算法提取 Information needs to be extracted with an algorithm

3、深度估计不好 Not great for depth estimation


畸变 Distortion

图像畸变发生在相机捕捉现实世界中的3D物体并将它们转换2D图像;

Image distortion occurs when a camera looks at 3D objects in the real world and transforms them into a 2D image;

这个转换并不完美

this transformation isn’t perfect.

畸变会改变3D物体实际形状大小

Distortion actually changes what the shape and size of these 3D objects appear to be.

所以,分析摄像头图像的第一步消除畸变,这样就可以从图像中获取正确有用信息

So, the first step in analyzing camera images, is to undo this distortion so that you can get correct and useful information out of them.

畸变类型 Types of Distortion

实际相机使用镜头形成图像,光线会在镜头边缘出现或多或少的扭曲。这就导致了图像的畸变,所以线或物体就会出现或多或少的弯曲。这是径向畸变,一种最常见的畸变类型。

Real cameras use curved lenses to form an image, and light rays often bend a little too much or too little at the edges of these lenses. This creates an effect that distorts the edges of images, so that lines or objects appear more or less curved than they actually are. This is called radial distortion, and it’s the most common type of distortion.

另一种畸变是切向畸变。这发生在相机镜头与图像平面,相机胶卷或传感器所在之处,没有完美地平行对齐时。这就导致图像看起来倾斜了,有些物体就会比实际大或小。

Another type of distortion, is tangential distortion. This occurs when a camera’s lens is not aligned perfectly parallel to the imaging plane, where the camera film or sensor is. This makes an image look tilted so that some objects appear farther away or closer than they actually are.

畸变系数校正 Distortion Coefficients and Correction

径向畸变的校正需要三个系数k_1,k_2,k_3。去校正图像中出现的径向畸变的点,可以使用校正公式

There are three coefficients needed to correct for radial distortionk1k2, and k3. To correct the appearance of radially distorted points in an image, one can use a correction formula.

在下述公式中,(x, y)是畸变图像中的点。为了给这些点去畸变,OpenCV计算r,是校正后图像中的点 和图像畸变中心的已知距离,畸变中心通常为图像的中心(x_c,y_c)。如下图所示:

In the following equations, (x, y) is a point in a distorted image. To undistort these points, OpenCV calculates r, which is the known distance between a point in an undistorted (corrected) image  and the center of the image distortion, which is often the center of that image (x_c,y_c). This center point (x_c,y_c) is sometimes referred to as the distortion center. These points are pictured below. 

注意:畸变系数k_3需要准确反映主要径向畸变(比如广角相机)。然而,对于次要径向畸变,大多数摄像头镜头都有的,k_3的值非常接近或等于0,是可以忽略的。所以,在OpenCV中,你可以选择忽略这个系数;这就是为什么在畸变值矩阵最后出现的是。

Note: The distortion coefficient k3 is required to accurately reflect major radial distortion (like in wide angle lenses). However, for minor radial distortion, which most regular camera lenses have, k3 has a value close to or equal to zero and is negligible. So, in OpenCV, you can choose to ignore this coefficient; this is why it appears at the end of the distortion values array: [k1, k2, p1, p2, k3]. In this course, we will use it in all calibration calculations so that our calculations apply to a wider variety of lenses (wider, like wide angle, haha) and can correct for both minor and major radial distortion.

【自动驾驶传感器——摄像头】_第1张图片

径向畸变校正 Radial distortion correction

切向畸变校正 Tangential distortion correction

有额外的两个系数负责切向畸变:p_1,p_2。切向畸变可以使用不同的校正公式来校正。 

There are two more coefficients that account for tangential distortionp1 and p2, and this distortion can be corrected using a different correction formula.

你可能感兴趣的:(人工智能,计算机视觉,自动驾驶)