官术网_书友最值得收藏!

How do computers interpret images?

Essentially, every image can be represented as a matrix of pixel values. In other words, images can be thought of as a function (f) that maps from R2 to R.

f(x, y) gives the intensity value at the position (x, y). In practice, the value of the function ranges only from 0 to 255. Similarly, a color image can be represented as a stack of three functions. We can write this as a vector of:

 f( x, y) = [ r(x,y) g(x,y) b(x,y)]

Or we can write this as a mapping:

f: R x R --> R3

So, a color image is also a function, but in this case, a value at each (x,y) position is not a single number. Instead it is a vector that has three different light intensities corresponding to three color channels. The following is the code for seeing the details of an image as input to a computer.

主站蜘蛛池模板: 志丹县| 革吉县| 托克逊县| 南京市| 康平县| 旬邑县| 屏东县| 铜川市| 沂南县| 宣化县| 巫山县| 锦州市| 西昌市| 宁波市| 梁河县| 宁都县| 隆德县| 汉川市| 新平| 贵溪市| 方正县| 蒲江县| 巴楚县| 永修县| 绵竹市| 桑植县| 九龙坡区| 徐州市| 定兴县| 政和县| 奉新县| 冷水江市| 大余县| 银川市| 勐海县| 凤阳县| 山阴县| 合水县| 龙山县| 吕梁市| 犍为县|