piu-mosso 0.1.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- piu_mosso-0.1.0/CHANGELOG.md +46 -0
- piu_mosso-0.1.0/CITATION.cff +20 -0
- piu_mosso-0.1.0/LICENSE +841 -0
- piu_mosso-0.1.0/MANIFEST.in +2 -0
- piu_mosso-0.1.0/PKG-INFO +128 -0
- piu_mosso-0.1.0/README.md +93 -0
- piu_mosso-0.1.0/pyproject.toml +53 -0
- piu_mosso-0.1.0/setup.cfg +4 -0
- piu_mosso-0.1.0/src/piu_mosso/__init__.py +29 -0
- piu_mosso-0.1.0/src/piu_mosso/faiss_knn.py +293 -0
- piu_mosso-0.1.0/src/piu_mosso/graph.py +112 -0
- piu_mosso-0.1.0/src/piu_mosso/hvg.py +362 -0
- piu_mosso-0.1.0/src/piu_mosso/layout.py +237 -0
- piu_mosso-0.1.0/src/piu_mosso/pp.py +109 -0
- piu_mosso-0.1.0/src/piu_mosso/spectral.py +427 -0
- piu_mosso-0.1.0/src/piu_mosso/tl.py +176 -0
- piu_mosso-0.1.0/src/piu_mosso.egg-info/PKG-INFO +128 -0
- piu_mosso-0.1.0/src/piu_mosso.egg-info/SOURCES.txt +28 -0
- piu_mosso-0.1.0/src/piu_mosso.egg-info/dependency_links.txt +1 -0
- piu_mosso-0.1.0/src/piu_mosso.egg-info/requires.txt +12 -0
- piu_mosso-0.1.0/src/piu_mosso.egg-info/top_level.txt +1 -0
- piu_mosso-0.1.0/tests/run_tests.sh +23 -0
- piu_mosso-0.1.0/tests/test_graph.py +89 -0
- piu_mosso-0.1.0/tests/test_hvg.py +184 -0
- piu_mosso-0.1.0/tests/test_knn.py +231 -0
- piu_mosso-0.1.0/tests/test_layout.py +145 -0
- piu_mosso-0.1.0/tests/test_package.py +53 -0
- piu_mosso-0.1.0/tests/test_pp_neighbors.py +100 -0
- piu_mosso-0.1.0/tests/test_spectral.py +100 -0
- piu_mosso-0.1.0/tests/test_tl_umap.py +144 -0
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
All notable changes to piu_mosso are listed here. The format follows [Keep a Changelog](https://keepachangelog.com/),
|
|
4
|
+
and versions follow [Semantic Versioning](https://semver.org/).
|
|
5
|
+
|
|
6
|
+
## [Unreleased]
|
|
7
|
+
|
|
8
|
+
## [0.1.0] - 2026-11-26
|
|
9
|
+
|
|
10
|
+
First release.
|
|
11
|
+
|
|
12
|
+
### Added
|
|
13
|
+
|
|
14
|
+
- `piu_mosso.knn`: the k nearest neighbours of every cell with FAISS. The search is exact up to a size that depends
|
|
15
|
+
on the device (2\*\*16 cells on the CPU, 2\*\*21 on a GPU) and approximate above it (an IVF index whose number of
|
|
16
|
+
probed lists is raised until a random sample of cells finds 99% of its exact neighbours). Distances are recomputed
|
|
17
|
+
exactly. GPU search is opt-in (`use_gpu=True`, with `faiss-gpu-cu12` installed instead of `faiss-cpu`).
|
|
18
|
+
- `piu_mosso.umap_connectivities` and `piu_mosso.knn_distance_matrix`: scanpy's UMAP neighbour graph and distance
|
|
19
|
+
matrix from k nearest neighbours.
|
|
20
|
+
- `piu_mosso.pp.neighbors`: FAISS neighbours and the UMAP graph, written where `sc.pp.neighbors` writes them, so
|
|
21
|
+
scanpy's tools use them unchanged.
|
|
22
|
+
- The spectral start of the UMAP layout (`piu_mosso.spectral`): umap-learn's, but it uses lobpcg wherever ARPACK
|
|
23
|
+
would overflow and crash on large graphs, and a failed eigensolver raises an error instead of falling back to a
|
|
24
|
+
random start.
|
|
25
|
+
- `piu_mosso.umap_embedding`: the UMAP layout of a neighbour graph with scanpy's defaults, parallel by default, moving
|
|
26
|
+
both cells of each sampled edge (`move_other=True`), from a spectral, PCA or given start.
|
|
27
|
+
- `piu_mosso.tl.umap`: the UMAP of the neighbour graph, written where `sc.tl.umap` writes it, so `sc.pl.umap` shows
|
|
28
|
+
it.
|
|
29
|
+
- `piu_mosso.highly_variable_genes`: Seurat v3 highly variable genes over one or several AnnDatas, backed or in
|
|
30
|
+
memory, equal to scanpy's for their concatenation up to floating-point rounding, without concatenating them or
|
|
31
|
+
loading them into memory. Non-integer or negative counts raise an error where scanpy warns.
|
|
32
|
+
|
|
33
|
+
### Known issues
|
|
34
|
+
|
|
35
|
+
- With scanpy 1.13 and pandas 3 (the current releases; seen on Python 3.13), seven tests that compare piu_mosso with
|
|
36
|
+
scanpy fail ([#7](https://github.com/NingWang1729/piu_mosso/issues/7)). scanpy is only a test dependency of
|
|
37
|
+
piu_mosso; the failures are differences from scanpy's output:
|
|
38
|
+
- `highly_variable_genes` with `batch_key` can rank tied genes half a rank differently from scanpy's `seurat_v3`
|
|
39
|
+
(`highly_variable_rank`).
|
|
40
|
+
- scanpy 1.13's `sc.tl.umap` records extra entries in `uns['umap']['params']` (`compatibility_layout`, and
|
|
41
|
+
`random_state` even when 0) that `piu_mosso.tl.umap` does not write.
|
|
42
|
+
|
|
43
|
+
With scanpy 1.11 and pandas 2, all tests pass. To be resolved in a later release.
|
|
44
|
+
|
|
45
|
+
[Unreleased]: https://github.com/NingWang1729/piu_mosso/compare/v0.1.0...HEAD
|
|
46
|
+
[0.1.0]: https://github.com/NingWang1729/piu_mosso/releases/tag/v0.1.0
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
cff-version: 1.2.0
|
|
2
|
+
message: "If you use piu_mosso, please cite it as below."
|
|
3
|
+
type: software
|
|
4
|
+
title: piu_mosso
|
|
5
|
+
abstract: "Fast single-cell utilities: FAISS nearest neighbours, a fast UMAP and Seurat v3 highly variable genes."
|
|
6
|
+
authors:
|
|
7
|
+
- family-names: Wang
|
|
8
|
+
given-names: Ning
|
|
9
|
+
orcid: "https://orcid.org/0000-0003-3073-7911"
|
|
10
|
+
license: LGPL-3.0-or-later
|
|
11
|
+
repository-code: "https://github.com/NingWang1729/piu_mosso"
|
|
12
|
+
version: 0.1.0
|
|
13
|
+
date-released: "2026-11-26"
|
|
14
|
+
keywords:
|
|
15
|
+
- single-cell
|
|
16
|
+
- nearest neighbours
|
|
17
|
+
- UMAP
|
|
18
|
+
- FAISS
|
|
19
|
+
- highly variable genes
|
|
20
|
+
- scanpy
|