Skip to main content

description

Project description

:rocket: ANN :facepunch:


Install

pip install fast-ann

Usage

from ann import ANN
import numpy as np

data = 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)

milvus镜像

yum -y install python3
# ln -sf /usr/bin/python3 /usr/bin/python
# ln -sf /usr/bin/pip3 /usr/bin/pip
pip3 install -U --no-cache-dir -i https://mirror.baidu.com/pypi/simple pip meutils pymilvus

rm -rf /tmp/*
rm -rf /root/.cache/pip*


  • faiss不同量级对应的训练时间及内存测试

  • 压缩方式测试

  • 四种组合:默认是查向量返回 distance与index

    • id => id/vector
    • vector => id/vector
    • push场景需要 docid => title_vector => docid
  • 线上服务

    • id2word
    • id2vector

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

tql-ANN-2021.2.5.19.19.33.tar.gz (8.6 kB view details)

Uploaded Source

Built Distribution

tql_ANN-2021.2.5.19.19.33-py3-none-any.whl (9.1 kB view details)

Uploaded Python 3

File details

Details for the file tql-ANN-2021.2.5.19.19.33.tar.gz.

File metadata

  • Download URL: tql-ANN-2021.2.5.19.19.33.tar.gz
  • Upload date:
  • Size: 8.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.25.1 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.56.0 CPython/3.6.8

File hashes

Hashes for tql-ANN-2021.2.5.19.19.33.tar.gz
Algorithm Hash digest
SHA256 1a94fac26aa3e5f4595be6ebac4583d1375762d197f03874687c3f08dae41d0c
MD5 176a11c5bac3403ac20cbcb6e72c9849
BLAKE2b-256 22a9f78b68fff23e72854ae4edda49a0f478be56a763f62de8905868e8e233d0

See more details on using hashes here.

File details

Details for the file tql_ANN-2021.2.5.19.19.33-py3-none-any.whl.

File metadata

  • Download URL: tql_ANN-2021.2.5.19.19.33-py3-none-any.whl
  • Upload date:
  • Size: 9.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.25.1 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.56.0 CPython/3.6.8

File hashes

Hashes for tql_ANN-2021.2.5.19.19.33-py3-none-any.whl
Algorithm Hash digest
SHA256 446217930fb8b4f0e3a754972d2107006916d5eda29ec966a3e8c622928e7a43
MD5 cff0b23c29407048b23d94c35f685689
BLAKE2b-256 25f8ec20debf15d2c48e2650b4b972622e763452b5f0048bd9f64f7e68d95819

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page