![Intelligent Projects Using Python](https://wfqqreader-1252317822.image.myqcloud.com/cover/975/36698975/b_36698975.jpg)
上QQ阅读APP看书,第一时间看更新
Translation
For translation, the affine transformation matrix is the identity matrix, and the translation vector, b, has a nonzero value:
![](https://epubservercos.yuewen.com/759B01/19470382808830006/epubprivate/OEBPS/Images/73d49d1a-f974-40f0-9638-6ee27f574016.png?sign=1739639611-BW2N3AbXelH2Kkaxkkoa5050Dm6dZX90-0-b1350d8b42c5afb3d0eb175a9b7b0701)
For instance, for a translation of five pixel positions along the vertical direction and three pixel positions along the horizontal direction, we can use b= [5 3]T, with M as the identity matrix.
The following is an image translation of a retina by 24 pixel locations, along both the width and height of the image:
![](https://epubservercos.yuewen.com/759B01/19470382808830006/epubprivate/OEBPS/Images/d8fe4d81-04d8-481f-afdd-3a8295ab2a1c.png?sign=1739639611-ikRX2nwDxYxXvcYJ5RlxSiZfY9G1II0L-0-cb56a58c1dedb199b4b6f47d0af8b406)
Figure 2.5: Image translation of the retina