题目有些题目党哈 ,我也不晓得为什么这样看到的人才多一些

Hora 是一个近似最近邻搜索算法 (wiki) 库

Hora 齐全基于 Rust 实现,事实证明,Rust 的确十分十分快,齐全能够媲美 C++ ,且Hora应用 SIMD进行了减速,速度十分快⚡️⚡️⚡️,具体速度能够参考上面的 benchmark.

Hora ,日语为 「ほら」,读法像 [hōl] ,意思是 Wow, You see! , Look at that! 。 这个名字的灵感来自日本驰名歌曲 「小さな恋のうた」

github: https://github.com/hora-searc...

主页: https://horasearch.com/

Python 库: https://github.com/hora-searc...

Javascript 库: https://github.com/hora-searc...

Hora 定位上是Rust实现的 ANN 算法库,心愿能基于 Rust 自身的劣势,可能提供多个平安的语言库,且能部署在任何中央。目前曾经能在Linux, macOSWindows以及WebAssembly部署,将来还会反对AndroidIOS以及 嵌入式设施


Demo

这是 Hora 的在线演示(能够在这里找到它,强烈推荐试试速度!! https://horasearch.com/)

Face-Match [online demo], have a try!

Dream wine comments search [online demo], have a try!

benchmark

Hora 十分快,bench (与 Faiss 和 Annoy 相比)

Usage

装置极为简略:
Rust

[dependencies]hora = "0.1.1"

Python

$ pip install horapy

Javascript (WebAssembly)

$ npm i horajs

Building from source

$ git clone https://github.com/hora-search/hora$ cargo build

应用上 API 也非常简单:

Python example [more info]

import numpy as npfrom horapy import HNSWIndexdimension = 50n = 1000# init index instanceindex = HNSWIndex(dimension, "usize")samples = np.float32(np.random.rand(n, dimension))for i in range(0, len(samples)):    # add node    index.add(np.float32(samples[i]), i)index.build("euclidean")  # build indextarget = np.random.randint(0, n)# 410 in Hora ANNIndex <HNSWIndexUsize> (dimension: 50, dtype: usize, max_item: 1000000, n_neigh: 32, n_neigh0: 64, ef_build: 20, ef_search: 500, has_deletion: False)# has neighbors: [410, 736, 65, 36, 631, 83, 111, 254, 990, 161]print("{} in {} \nhas neighbors: {}".format(    target, index, index.search(samples[target], 10)))  # search

咱们很欢送任何参加,欢送任何奉献,包含文档和测试。 咱们应用 GitHub 问题来跟踪 Issue 和 bug,你能够在 github 上进行 Pull Requests 、Issue

最初如果感觉这个我的项目做的还不错,或者比拟感兴趣,或者你们想用的,欢送在 github 上 star 或者给咱们提 issue

github: https://github.com/hora-searc...

Python 库: https://github.com/hora-searc...

Javascript 库: https://github.com/hora-searc...