spinnmf 0.1.0__py3-none-any.whl
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.
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: spinnmf
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: SPINNMF: Stable Spatial Pattern Discovery via AutoK Consensus Graph-Regularized Poisson NMF
|
|
5
|
+
Project-URL: Homepage, https://github.com/ZHANGCaicai581/SPINNMF
|
|
6
|
+
Project-URL: Repository, https://github.com/ZHANGCaicai581/SPINNMF
|
|
7
|
+
Project-URL: Issues, https://github.com/ZHANGCaicai581/SPINNMF/issues
|
|
8
|
+
Author: Caicai Zhang, Frank Qingyun Wang
|
|
9
|
+
License: MIT
|
|
10
|
+
License-File: LICENSE
|
|
11
|
+
Classifier: Development Status :: 3 - Alpha
|
|
12
|
+
Classifier: Intended Audience :: Science/Research
|
|
13
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
14
|
+
Classifier: Programming Language :: Python :: 3
|
|
15
|
+
Classifier: Programming Language :: Python :: 3.9
|
|
16
|
+
Classifier: Programming Language :: Python :: 3.10
|
|
17
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
18
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
19
|
+
Classifier: Topic :: Scientific/Engineering :: Bio-Informatics
|
|
20
|
+
Classifier: Topic :: Scientific/Engineering :: Information Analysis
|
|
21
|
+
Requires-Python: >=3.9
|
|
22
|
+
Requires-Dist: anndata>=0.9
|
|
23
|
+
Requires-Dist: joblib>=1.3
|
|
24
|
+
Requires-Dist: matplotlib>=3.7
|
|
25
|
+
Requires-Dist: numpy>=1.22
|
|
26
|
+
Requires-Dist: pandas>=1.5
|
|
27
|
+
Requires-Dist: scanpy>=1.9
|
|
28
|
+
Requires-Dist: scikit-learn>=1.2
|
|
29
|
+
Requires-Dist: scipy>=1.9
|
|
30
|
+
Requires-Dist: tqdm>=4.66
|
|
31
|
+
Provides-Extra: dev
|
|
32
|
+
Requires-Dist: build>=1.0; extra == 'dev'
|
|
33
|
+
Requires-Dist: pytest>=7.4; extra == 'dev'
|
|
34
|
+
Requires-Dist: ruff>=0.3; extra == 'dev'
|
|
35
|
+
Requires-Dist: twine>=4.0; extra == 'dev'
|
|
36
|
+
Description-Content-Type: text/markdown
|
|
37
|
+
|
|
38
|
+
# SPINNMF
|
|
39
|
+
|
|
40
|
+

|
|
41
|
+
|
|
42
|
+
## 安装
|
|
43
|
+
|
|
44
|
+
-(发布到 PyPI 后)`pip install spinnmf`
|
|
45
|
+
- 开发模式:在源码根目录运行 `pip install -e .[dev]`
|
|
46
|
+
|
|
47
|
+
## 快速使用
|
|
48
|
+
|
|
49
|
+
命令行运行 AutoK:
|
|
50
|
+
```bash
|
|
51
|
+
spinnmf \
|
|
52
|
+
--h5ad /path/to/spatial.h5ad \
|
|
53
|
+
--outdir /path/to/outdir \
|
|
54
|
+
--k_grid 2,3,4,5 \
|
|
55
|
+
--n_seeds 5 \
|
|
56
|
+
--n_jobs 4
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
Python 调用:
|
|
60
|
+
```python
|
|
61
|
+
import anndata as ad
|
|
62
|
+
from spinnmf import fit_spin_nmf_autok, config
|
|
63
|
+
|
|
64
|
+
adata = ad.read_h5ad("path/to/spatial.h5ad")
|
|
65
|
+
cfg = config.SPINNMFConfig(k_grid=(2, 3, 4), n_seeds=3, n_jobs=1)
|
|
66
|
+
res = fit_spin_nmf_autok(adata.X, adata.obsm["spatial"], cfg)
|
|
67
|
+
print(res.K_star, res.W.shape, res.H.shape)
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
## 测试与构建
|
|
71
|
+
|
|
72
|
+
```bash
|
|
73
|
+
pytest
|
|
74
|
+
python -m build
|
|
75
|
+
twine check dist/*
|
|
76
|
+
```
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
spinnmf-0.1.0.dist-info/METADATA,sha256=oH9M-lC3pZ-4_EIvxMajBxy7gxxhClKcF3al-EUYEbQ,2212
|
|
2
|
+
spinnmf-0.1.0.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
|
|
3
|
+
spinnmf-0.1.0.dist-info/entry_points.txt,sha256=oGZSUiDgSYM9VDg0k5SqZjSgNLOS3Ve2cYEMv-5Crko,45
|
|
4
|
+
spinnmf-0.1.0.dist-info/licenses/LICENSE,sha256=e-2VxKbDOHmng_JylSnfOUwW--Zj_zw3RcrtY_SHH4k,1092
|
|
5
|
+
spinnmf-0.1.0.dist-info/RECORD,,
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2025 Caicai Zhang and Frank Qingyun Wang
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|