cell-neighbors
Neighbor graphs for single-cell data (AnnData)
This repository provides a Python package for building k-nearest neighbor (kNN) graphs from AnnData objects.
The package is built on the Voyager library from Spotify.
Features
- Efficient kNN Graph Construction from
Voyager. - Direct
AnnDataintegration - Flexible querying of neighbors in the constructed
kNNgraph index.
Installation
Install the latest release from PyPI:
pip install cell-neighbors
or, if you use uv:
uv pip install cell-neighbors
# or, to add it to your pyproject.toml
uv add cell-neighbors
Example
import cell_neighbors
# Initialize kNN graph builder
knn_graph = cell_neighbors.kNN(adata), use_key="X_pca")
# Query neighbors
X_query = [...] # Your query points as numpy array
neighbors = knn_graph.query(X_query)
Documentation
For real examples, detailed usage instructions, and API reference, please refer to the documentation [coming soon].
Metadata
Release files for cell-neighbors 0.2.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| cell_neighbors-0.2.0.tar.gz | 7.7 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| cell_neighbors-0.2.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 12.9 kB
Release files / cell_neighbors-0.2.0.tar.gz
| Download URL | cell_neighbors-0.2.0.tar.gz |
|---|---|
| Size | 7.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
8501ed41f4d7e1e423624f1bcfdcea87110ac24e705ea0613c7d186cf4bd77c6
|
|
BLAKE2b-256 checksum How to use checksums |
a3ff68258a4cbfe0c85f2ef330c026a2ca54262d3b47662c259e8b627baa2e7b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
uv/0.9.26 {"installer":{"name":"uv","version":"0.9.26","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|
Release files / cell_neighbors-0.2.0-py3-none-any.whl
| Download URL | cell_neighbors-0.2.0-py3-none-any.whl |
|---|---|
| Size | 5.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
ced55f071dd97ee53c6367052f03fcb627b88319272414de8f7bd759ea1bc3ed
|
|
BLAKE2b-256 checksum How to use checksums |
47aad45817d3ef7c6e2781d685217836e2aa2db07b8b4b75c54e0a16d67e735c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
uv/0.9.26 {"installer":{"name":"uv","version":"0.9.26","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|