Skip to main content

spheni

A tiny CPU-first, in-memory vector search library in C++ with Python bindings.

Install

pip install spheni

Quick Example

import numpy as np
import spheni

spec = spheni.IndexSpec(4, spheni.Metric.L2, spheni.IndexKind.Flat)
engine = spheni.Engine(spec)

base = np.random.rand(10, 4).astype(np.float32)
engine.add(base)

query = np.random.rand(4).astype(np.float32)
hits = engine.search(query, 3)

for h in hits:
    print(h.id, h.score)

Features

  • Indexes: Flat, IVF
  • Metrics: Cosine, L2
  • Storage: F32, INT8
  • Operations: add, search, search_batch, train, save, load

Build From Source

python -m pip wheel . --no-deps -w dist

Then install the wheel from dist/.

Links

Metadata

Release files for spheni 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for spheni 0.1.1
File Size Uploaded
spheni-0.1.1.tar.gz 16.4 MB Details

Built distributions (wheels)

Table of built distributions (wheels) for spheni 0.1.1
File
spheni-0.1.1-cp312-cp312-win_amd64.whl CPython 3.12 CPython 3.12 Windows x86-64 Details
spheni-0.1.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.12 CPython 3.12 Linux glibc 2.17+ x86-64 Details
spheni-0.1.1-cp311-cp311-win_amd64.whl CPython 3.11 CPython 3.11 Windows x86-64 Details
spheni-0.1.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.11 CPython 3.11 Linux glibc 2.17+ x86-64 Details
spheni-0.1.1-cp310-cp310-win_amd64.whl CPython 3.10 CPython 3.10 Windows x86-64 Details
spheni-0.1.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.10 CPython 3.10 Linux glibc 2.17+ x86-64 Details
spheni-0.1.1-cp39-cp39-win_amd64.whl CPython 3.9 CPython 3.9 Windows x86-64 Details
spheni-0.1.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.9 CPython 3.9 Linux glibc 2.17+ x86-64 Details

Total release size: 18.7 MB

Release files / spheni-0.1.1.tar.gz

Download URL spheni-0.1.1.tar.gz
Size 16.4 MB
Tags Source
SHA-256 checksum
How to use checksums
5cf097f9f0569161239ba39260a5ded4359fa9969df522808ece57a30fc11772
BLAKE2b-256 checksum
How to use checksums
a80d9ec5c54b6b96e9ec500a4ac70efabc2f5d75d72d779ba26db5dbe7492317
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.7

Release files / spheni-0.1.1-cp312-cp312-win_amd64.whl

Download URL spheni-0.1.1-cp312-cp312-win_amd64.whl
Size 272.9 kB
Tags CPython 3.12 Windows x86-64
SHA-256 checksum
How to use checksums
d0643857a26ee48abb92c3749cd6ad4c617215fd3be22ef797243f03d0b250a5
BLAKE2b-256 checksum
How to use checksums
cba50d02945e3244cd9ac53f2a8e95b0ce6a7fe518bbc3ca5ae5a667b5b85bd9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.7

Release files / spheni-0.1.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL spheni-0.1.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 308.7 kB
Tags CPython 3.12 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
d3443c788617858f649f142b302be69fb705258371123b436717dfd0244230d1
BLAKE2b-256 checksum
How to use checksums
369cc17383a27662751a08432655f1ae806c7b266f096a8fdb8899083b322ba5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.7

Release files / spheni-0.1.1-cp311-cp311-win_amd64.whl

Download URL spheni-0.1.1-cp311-cp311-win_amd64.whl
Size 271.7 kB
Tags CPython 3.11 Windows x86-64
SHA-256 checksum
How to use checksums
45bbcc59ec1ce225f6601265c086174d42558d8a9f7fe0402eab7c732c280972
BLAKE2b-256 checksum
How to use checksums
f18f6e8c2add732b45d386ce2ea6aa813db4df1e7ce717b702f5ef8ca730fafb
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.7

Release files / spheni-0.1.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL spheni-0.1.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 309.7 kB
Tags CPython 3.11 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
b75c1e44fefd40d506f6257671d7aee9fb90eebbdba12565b57dfc550d785780
BLAKE2b-256 checksum
How to use checksums
b02af2182df6af40bf51d6f004ed8f6971fed98673c7415a02ad3500f5fc07b0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.7

Release files / spheni-0.1.1-cp310-cp310-win_amd64.whl

Download URL spheni-0.1.1-cp310-cp310-win_amd64.whl
Size 270.6 kB
Tags CPython 3.10 Windows x86-64
SHA-256 checksum
How to use checksums
e6513c02096224fcf83b3bc5cf570b174e8976a5f81c0c78365a3bbaeb26708c
BLAKE2b-256 checksum
How to use checksums
62d7a7ad588310921070714f82aaaa9f054ac9d9cb9db12aecaa48ab96cf8faf
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.7

Release files / spheni-0.1.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL spheni-0.1.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 308.6 kB
Tags CPython 3.10 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
27fca3ef59cb29219db442e27ed32e995ef669be7f5509af79021a6b5eb1f520
BLAKE2b-256 checksum
How to use checksums
8825b670115cb3c36194c213ab930e5e2b1b83f6784dc70803dd3dbfa9265ff2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.7

Release files / spheni-0.1.1-cp39-cp39-win_amd64.whl

Download URL spheni-0.1.1-cp39-cp39-win_amd64.whl
Size 276.9 kB
Tags CPython 3.9 Windows x86-64
SHA-256 checksum
How to use checksums
4ec2e0d4d8bdd32acb7e2fb32388fabbf2d5e0fa33f5bd037deb0f2dedbc3a66
BLAKE2b-256 checksum
How to use checksums
b411ed56d85c83b3b7ff08ce83e79a9be641583e6f4464b7283cce46420a3288
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.7

Release files / spheni-0.1.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL spheni-0.1.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 308.9 kB
Tags CPython 3.9 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
d7f48ae7b75275f70e933c80ec1381d078346e7896454e2def30e6a723b05ac5
BLAKE2b-256 checksum
How to use checksums
506d41fed293504a1bb609e50e2ad38d1a3b84c812e80beaf18dc2b64bd90152
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.7

Release history Release notifications | RSS feed

This release

0.1.1 This release

9 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page