8000 GitHub - azr/phash: A simple perceptual hash library in pure Go.
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

azr/phash

Repository files navigation

phash Coverage ci.yml

A simple perceptual hashing library in Go.

Usage :

f, err := os.Open("image.jpg")
if err != nil {
    panic(err)
}
defer f.Close()
img, _, err := image.Decode(f)
if err != nil {
    panic(err)
}
hash1 := phash.DTC(img)
hash2 := phash.DTC(img)

if phash.Distance(hash1, hash2) == 0 {
    fmt.Println("these images sure do look alike.")
}

About

A simple perceptual hash library in pure Go.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 3

  •  
  •  
  •  

Languages

0