Computational Models(Math!)
Algorithm
Real Images
matlab
https://jp.mathworks.com/
GNU Octave
https://www.gnu.org/software/octave/
An image can be thought of as:
– a 2-dimensional array of numbers ranging from some minimum to some maximu
– a function I of x and y: I(x, y)
– something generated by a camera
Images as functions
we think of an image as a function, f or i, from R^2 to R
f(x, y) gives the intensity or value at position (x, y)
Piratically define the image over a rectangle, with a finite range:
f:[a, b]x[c, d] -> [min, max]
f(x,y) = [r(x,y) g(x,y) b(x,y)]
f:[10, 210]*[15.155] -> [0, 10]
(r,g,b) channels or planes
In computer vision we typically operate on digital images:
sample the 2d space on a regular grid
quantize each sample
Image thus represented as a matrix of integer values.
width 320, height 258, area 82560
3 color -> 82560*3 total color values
>> im = imread(‘peppers.png’); % semicolon or many numbers
>> imgreen = im(:,:,2);
>> imshow(imgreen)
>> line([1 512],[256 256],’color’,’r’)