https://github.com/yuanjie-ai/tql-ann
ANN: Faiss
https://github.com/yuanjie-ai/tql-ann
Last synced: 2 months ago
JSON representation
ANN: Faiss
- Host: GitHub
- URL: https://github.com/yuanjie-ai/tql-ann
- Owner: yuanjie-ai
- License: mit
- Created: 2019-12-04T12:00:29.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2019-12-04T12:42:15.000Z (over 5 years ago)
- Last Synced: 2025-03-08T05:07:59.431Z (3 months ago)
- Language: Python
- Size: 4.88 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
:rocket: ANN :facepunch:
---
# Install
`pip install fast-ann`# Usage
```python
from ann import ANN
import numpy as npdata = np.random.random((1000, 128)).astype('float32')
ann = ANN()
ann.train(data, index_factory='IVF4000, Flat', noramlize=True)dis, idx = ann.search(data[:10])
print(dis)
print(idx)
```