semvec/pypi-packages huggingface dataset:
topsis-vani-102303064 1.0.3
TOPSIS implementation as a Python package
License: MIT
Requires Python: >=3.8


# Topsis-Vani-102303064

This package implements the **TOPSIS (Technique for Order Preference by Similarity to Ideal Solution)** method.
It is used to rank alternatives based on multiple criteria.

---

## Installation

```bash

pip install topsis-vani-102303064

```

Usage (Command Line)

```bash
topsis <InputDataFile> <Weights> <Impacts> <OutputResultFileName>
```

Example
```bash
topsis data.csv "1,1,1,2" "+,+,-,+" output.csv
```

Input File Format
-CSV file
-Minimum 3 columns
-First column: alternative names (non-numeric)
-Remaining columns: numeric criteria values

Example Input
```bash
Fund Name,P1,P2,P3,P4
M1,0.67,0.45,6.5,42.6
M2,0.60,0.36,3.6,53.3
M3,0.82,0.67,3.8,63.1
```

Weights and Impacts
Weights (comma separated):
-1,1,1,2
Impacts (+ for benefit, - for cost):
-+,+,-,+

Output
-Output file is generated in CSV format
-Two new columns are added:
-Topsis Score
-Rank (Rank 1 = Best alternative)

License
-MIT License

Author
-Vani
-Roll Number: 102303064
spinnmf 0.1.0
SPINNMF: Stable Spatial Pattern Discovery via AutoK Consensus Graph-Regularized Poisson NMF
License: MIT
Requires Python: >=3.9

# SPINNMF

![SPINNMF workflow](docs/method_workflow.png)

## 安装

-（发布到 PyPI 后）`pip install spinnmf`
- 开发模式：在源码根目录运行 `pip install -e .[dev]`

## 快速使用

命令行运行 AutoK：
```bash
spinnmf \
  --h5ad /path/to/spatial.h5ad \
  --outdir /path/to/outdir \
  --k_grid 2,3,4,5 \
  --n_seeds 5 \
  --n_jobs 4
```

Python 调用：
```python
import anndata as ad
from spinnmf import fit_spin_nmf_autok, config

adata = ad.read_h5ad("path/to/spatial.h5ad")
cfg = config.SPINNMFConfig(k_grid=(2, 3, 4), n_seeds=3, n_jobs=1)
res = fit_spin_nmf_autok(adata.X, adata.obsm["spatial"], cfg)
print(res.K_star, res.W.shape, res.H.shape)
```

## 测试与构建

```bash
pytest
python -m build
twine check dist/*
```