lena
代码说明:
说明: SLIC算法是simple linear iterative cluster的简称,该算法用来生成超像素(superpixel) 算法步骤: 已知一副图像大小M*N,可以从RGB空间转换为LAB空间,LAB颜色空间表现的颜色更全面 假如预定义参数K,K为预生成的超像素数量,即预计将M*N大小的图像(像素数目即为M*N)分隔为K个超像素块,每个超像素块范围大小包含[(M*N)/K]个像素 假设每个超像素区域长和宽都均匀分布的话,那么每个超像素块的长和宽均可定义为S,S=sqrt(M*N/K) 遍历操作,将每个像素块的中心点的坐标(x,y)及其lab的值保存起来,加入到事先定义好的集合中(Algorithmic steps: Given the size of an image M*N, it can be converted from RGB space to LAB space, and the color space of LAB is more comprehensive. If the predefined parameter K, K is the number of pre-generated super-pixels, i.e., the image of M*N size (the number of pixels is M*N) is expected to be divided into K super-pixel blocks, each of which contains [(M*N)/K] pixels. Assuming that the length and width of each super-pixel region are evenly distributed, the length and width of each super-pixel block can be defined as S, S = sqrt (M*N/K). The traversal operation saves the coordinates (x, y) and lab values of the central points of each pixel block and adds them to a pre-defined set.)
文件列表:
lena.py, 5593 , 2019-06-10
下载说明:请别用迅雷下载,失败请重下,重下不扣分!