带缓存的图像哈希库
ImageHashCache的Python项目详细描述
ImageHashCache
==
一个用Python编写的图像哈希库ImageHashCache支持:
*平均散列(`aHash``)
*感知散列(`pHash```)
*差异散列(`dHash``)
*缓存调整大小的图像
要求
----
基于PIL/枕头图像Numpy和scipy.fftpack.fftpack(用于phash)
>通过“pypi”轻松安装。
>基本用法
>
:从pil导入图像
>>;导入image hash
>;
>
>
>
>>>>;hash=imagehash.average的hash(image.open('test.png')
>;打印(散列)
>d879ff89b1bbf
>>>;
>>>>>>>
>>
>
>gt;gt;其他哈希=Image hash.average廑u hash(Image.open('other.bmp'))
>;>print(otherhash)
ffffff3720200ffff
>;>print(hash==otherhash)
False
>;>print(hash-otherhash)
36
演示脚本**find廑similar廑images**演示了如何在目录中查找相似图像。
https://github.com/jzbjyb/imagehash
…_阿哈什:http://www.hackerfactor.com/blog/index.php?/archives/432看起来像它。html
…_ PHASH:http://www.hackerfactor.com/blog/index.php?/archives/432看起来像它。html
_达什:http://www.hackerfactor.com/blog/index.php?/archives/529差不多。html
_ pypi:https://pypi.python.org/pypi/imagehash
==
一个用Python编写的图像哈希库ImageHashCache支持:
*平均散列(`aHash``)
*感知散列(`pHash```)
*差异散列(`dHash``)
*缓存调整大小的图像
要求
----
基于PIL/枕头图像Numpy和scipy.fftpack.fftpack(用于phash)
>通过“pypi”轻松安装。
>基本用法
>
:从pil导入图像
>>;导入image hash
>;
>
>
>
>>>>;hash=imagehash.average的hash(image.open('test.png')
>;打印(散列)
>d879ff89b1bbf
>>>;
>>>>>>>
>>
>
>gt;gt;其他哈希=Image hash.average廑u hash(Image.open('other.bmp'))
>;>print(otherhash)
ffffff3720200ffff
>;>print(hash==otherhash)
False
>;>print(hash-otherhash)
36
演示脚本**find廑similar廑images**演示了如何在目录中查找相似图像。
https://github.com/jzbjyb/imagehash
…_阿哈什:http://www.hackerfactor.com/blog/index.php?/archives/432看起来像它。html
…_ PHASH:http://www.hackerfactor.com/blog/index.php?/archives/432看起来像它。html
_达什:http://www.hackerfactor.com/blog/index.php?/archives/529差不多。html
_ pypi:https://pypi.python.org/pypi/imagehash