Skip to content
/ hnswgo Public

Go binding of hnswlib(c++) for fast approximate nearest neighbor search

License

Notifications You must be signed in to change notification settings

oligo/hnswgo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

HNSWGO

This is a golang binding of hnswlib. For more information, please follow hnswlib and Efficient and robust approximate nearest neighbor search using Hierarchical Navigable Small World graphs..

Build

CGO is required to be enabled and c, c++ compiler is required to build this package.

go get github.com/oligo/hnswgo

Usage and config

See example/example.go or test codes to see usage. For detailed information, please refer to the project's documentation at pkg.go.dev.

Some important arguments are listed below:

argument type
dim int vector dimension
M int seeALGO_PARAMS.md
efConstruction int seeALGO_PARAMS.md
randomSeed int random seed for hnsw
maxElements int max records in data
spaceType str
spaceType distance
ip inner product
cosine cosine similarity
l2 l2

HNSWGO implements the main hnsw API,Brute force index is not implemented as it is rarely used.

For more information, please consult documents of the hnswlib projects.

References

Malkov, Yu A., and D. A. Yashunin. "Efficient and robust approximate nearest neighbor search using Hierarchical Navigable Small World graphs." TPAMI, preprint: [https://arxiv.org/abs/1603.09320]

About

Go binding of hnswlib(c++) for fast approximate nearest neighbor search

Resources

License

Stars

Watchers

Forks

Packages

No packages published