Perception(1.2.1-1.4)

4.1.2.2 Image Coordinate System

4.1.2.2图像坐标系

Based on the camera transformation matrix, another coordinate system is provided which applies to the camera image. The ImageCoordinateSystem is provided by the module CoordinateSystemProvider. The origin of the y-coordinate lies on the horizon within the image (even if it is not visible in the image). The x-axis points right along the horizon whereby the y-axis points downwards orthogonal to the horizon (cf. Fig. 4.4). For more information see also [29]. Using the stored camera transformation matrix of the previous cycle in which the same camera took an image enables the CoordinateSystemProvider to determine the rotation speed of the camera and thereby interpolate its orientation when recording each image row. As a result,the representation ImageCoordinateSystem provides a mechanism to compensate for different recording times of images and joint angles as well as for image distortion caused by the rolling shutter. For a detailed description of this method, applied to the Sony AIBO, see [23]

基于摄像机变换矩阵,提供了另一种坐标系统,其适用于
到相机图像。该ImageCoordinateSystem由模块CoordinateSystemProvider提供。图像内的y轴原点位于视野内(即使它是在图像中不可见)。x轴水平向右,y轴垂直向下。使用前一循环的所存储的相机变换矩阵,在这个循环里拍照片的相机使得 CoordinateSystemProvider确定相机的旋转速度,并且因此记录每个图像行时,从而插值其定位。结果是,representation ImageCoordinateSystem提供了一种机制,以补偿图像和关节角度的不同记录时间以及卷帘快门所造成的图象失真。

4.1.3 Body Contour
If the robot sees parts of its body, it might confuse white areas with field lines or other robots. However, by using forward kinematics, the robot can actually know where its body is visible in the camera image and exclude these areas from image processing. This is achieved by modeling the boundaries of body parts that are potentially visible in 3-D (cf. Fig. 4.5 left) and projecting them back to the camera image (cf. Fig. 4.5 right). The part of the projection that intersects with the camera image or above is provided in the representation BodyContour. It is used by image processing modules as lower clipping boundary. The projection relies on the representation ImageCoordinateSystem, i.e., the linear interpolation of the joint angles to match the time when the image was taken.

4.1.3体轮廓

如果机器人看到它的身体部位,它可能会混淆与现场线或其它机器人的白色区域。但是,通过使用 forward kinematics (这里引出了著名的D-H参数wikiD-H参数zhihu(这个是中文的,说的也更容易理解些)),机器人能够真正知道它的身体是可见
摄像机图像并且排除处理这些区域。这是通过模拟在三维潜在可见的身体部位的界限并且投影它们到相机图像来实现的。在representation BodyContour中,投影的部分和相机的图像以及被提供的以上相交。它是被图像处理模块用作低剪切边界。投影依赖于representation ImageCoordinateSystem,即关节角度的线性内插,以匹配时图像拍摄的时间。

4.1.4 Color Classification
Identifying the color classes of pixels in the image is done by the ECImageProvider when computing the ECImage. In order to be able to clearly distinguish different colors and easily define color classes while still being able to compute the ECImage for every camera image in real time,
the YHS2 color space is used.

4.1.4颜色分类

在计算ECImage时,识别像素的颜色类在图像中被ECImageProvider完成。为了能够清楚地辨别不同的颜色和很容易地定义色类,同时仍能够实时为每摄像机计算ECImage,就使用YHS2色彩空间。(ECImage是什么,忘了,记得前面的翻译里有过解释)

YHS2 Color Space

The YHS2 color space is defined by applying the idea behind the HSV color space, i.e. defining
the chroma components as a vector in the RGB color wheel, to the YUV color space. In YHS2,
the hue component H describes the angle of the vector of the U and V components of the color
in the YUV color space, while the saturation component S describes the length of that vector
divided by the luminance of the corresponding pixel. The luminance component Y is just the
same as it is in YUV. By dividing the saturation by the luminance, the resulting saturation
value describes the actual saturation of the color more accurately, making it more useful for
separating black and white from actual colors. This is because in YUV, the chroma components
are somewhat dependent of the luminance (cf. Fig. 4.6).

YHS2色彩空间

所述YHS2颜色空间是运用HSV颜色空间的理念而定义,即对于YUV颜色空间,定义色度分量作为在RGB颜色轮的载体。在YHS2中,色调分量H描述在YUV颜色空间内的U,V颜色分量矢量的矢量角,而饱和度分量S描述了矢量的被相应的像素的亮度除以的长度。亮度分量Y是刚好它在YUV相同。通过由亮度除以饱和,所得的饱和值更准确的描述了颜色的实际饱和值,使之更有用,对于分离黑色和白色,从实际颜色。这是因为在YUV,色度分量有些依赖于亮度。

Classification Method

Classifying a pixel’s color is done by first applying a threshold to the saturation channel. If it
is below the given threshold, the pixel is considered to describe a non-color, i.e. black or white.
In this case, whether the color is black or white is determined by applying another threshold
to the luminance channel. However, if the saturation of the given pixel is above the saturation
threshold, the pixel is of a certain color, if its hue value lies within the hue range defined for
that color.

分类方法

判断一个像素的颜色是通过首先施加一个针对饱和通道的阈值完成的。如果它低于给定的阈值,则象素被认为描述的是非彩色,即黑色或白色。
在这种情况下,颜色是否是黑色或白色通过施加亮度阈值来确定。然而,如果给定的像素的饱和度是饱和以上阈值时,若其色调值位于那个颜色限定的色调范围内,那像素则是那个特定的颜色。

This approach was used throughout the RoboCup 2016 and provided very good results. It is however possible to use an alternative classification method by setting the simpleClassification parameter of the ECImageProvider to false. In this case, colors are defined not only by a hue
range, but by one range of values for each of H, S and Y. Additionally, white and black are not
separated by a single threshold for the Y channel, but there is a minimum Y threshold for white
and a maximum Y threshold for black to enable non-classified pixels with low saturation.

整个2016机器人世界杯采用这种方法,并提供了非常好的效果。它无论如何都可能通过设置ECImageProvider的simpleClassification参数为false。在这种情况下,颜色由不仅由色调定义,也由每个H,S和Y值的一个范围,白色和黑色不仅通过对Y信道的单个阈值而分开,也有一个对于白色的最小Y阈值和对于黑色的最大Y阈值,以使低饱和度的未分类像素能区分开。

In order to classify the whole camera image in real time, both the color conversion to YHS2 and
the color classification are done using SSE instructions.

Fig. 4.7 shows representations of an image from the upper camera in the YHS2 color space and a classification based on it for the colors white, black, green and “none” (displayed gray).

为了实时对整个摄像机影像分类,无论是颜色转换到YHS2和
颜色分类使用SSE指令完成。
图4.7显示出来自上照相机的图像在YHS2色彩空间的representation和
基于它的对于白,黑,绿和“无”(显示灰度)颜色的分类。

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值