semvec/pypi-packages huggingface dataset:
anypytools 1.20.5
Python tools and utilities for working with the AnyBody Modeling System
Requires Python: >=3.10
Keywords: AnyBody Modeling System, AnyScript

# AnyPyTools

[![MIT License](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
[![test](https://github.com/AnyBody-Research-Group/AnyPyTools/actions/workflows/test.yml/badge.svg)](https://github.com/AnyBody-Research-Group/AnyPyTools/actions/workflows/test.yml)
[![](https://anaconda.org/conda-forge/anypytools/badges/downloads.svg)](https://anaconda.org/conda-forge/anypytools)
[![](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/ambv/black)
[![JOSS paper](http://joss.theoj.org/papers/10.21105/joss.01108/status.svg)](https://doi.org/10.21105/joss.01108)

AnyPyTools is a toolkit for working with the [AnyBody Modeling System (AMS)]
from Python. It enables reproduceable research with the AnyBody Modeling System, and bridges the gap to whole ecosystem of open source scientific Python.

The AnyPyTools Python package enables batch processing, parallization of model
simulations, model sensitivity studies, and parameter studies, using either
Monte-Carlo (random sampling) or Latin hypercube sampling. It makes reproducible
research much easier and replaces the tedious process of manually automating the
musculoskeletal simulations and aggregating the results.

If you use the library for publications please **cite as:**

> Lund et al., (2019). AnyPyTools: A Python package for reproducible research with the AnyBody Modeling System. Journal of Open Source Software, 4(33), 1108, <https://doi.org/10.21105/joss.01108>

## Installation

- Download and install the [pixi](https://pixi.sh) package manager
- After installation open a command prompt in you project directory and type:

```bash
pixi init
pixi add anypytools
```

This will install a virtual environment with python, anypytools and all
dependencies. You can then run you scripts in the virtual environment by typing
by prefixing the command with `pixi run`: e.g. `pixi run python myscript.py`

The library is also available on [PyPi](https://pypi.python.org/pypi/AnyPyTools) for installing using `pip`.


## Usage

The simplest case:

```python
from anypytools import AnyPyProcess
app = AnyPyProcess()
macro = [
    'load "Model.main.any"',
    'operation Main.Study.InverseDynamics',
    'run',
]
app.start_macro(macro)
```

Please see the [Jupyter Notebook based tutorial], or check the the following for more information:

- [AnyPyTools's Documentation](https://anybody-research-group.github.io/anypytools-docs)


<img src="docs/_static/relax.png" alt="Don't panic" height="100px">


[anybody modeling system (ams)]: http://www.anybodytech.com
Topsis-Akash-102317024 1.0.0
A Python package to implement TOPSIS (Technique for Order of Preference by Similarity to Ideal Solution)
Requires Python: >=3.6
Keywords: topsis mcdm decision-making multi-criteria

# Topsis-Akash-102317024

**By: Akash, 102317024**

TOPSIS (Technique for Order of Preference by Similarity to Ideal Solution) is a multi-criteria decision analysis method. It is based on the principle that the best solution has the **shortest distance** from the positive-ideal solution and the **longest distance** from the negative-ideal solution.

---

## Installation

```bash
pip install Topsis-Akash-102317024
```

---

## Usage

### Command Line

```bash
topsis <InputDataFile> <Weights> <Impacts> <ResultFileName>
```

**Example:**

```bash
topsis data.csv "1,1,2,1" "+,+,-,+" result.csv
```

### Python API

```python
from Topsis_Akash_102317024 import topsis

topsis("data.csv", "1,1,2,1", "+,+,-,+", "result.csv")
```

---

## Input File Format

The input CSV file must have:
- **First column**: Alternative names (e.g., M1, M2, …)
- **Remaining columns**: Numeric criteria values

Example `data.csv`:

```
Fund Name,P1,P2,P3,P4,P5
M1,0.84,0.71,6.7,42.1,12.97
M2,0.91,0.83,7.0,31.7,10.52
M3,0.79,0.62,4.8,46.7,13.23
M4,0.78,0.61,6.4,42.4,12.59
M5,0.94,0.88,3.6,62.2,10.11
```

---

## Parameters

| Parameter   | Description                                              |
|-------------|----------------------------------------------------------|
| InputDataFile | Path to input CSV file                                |
| Weights     | Comma-separated numeric weights, e.g. `"1,1,2,1"`       |
| Impacts     | Comma-separated impacts (`+` or `-`), e.g. `"+,+,-,+"`  |
| ResultFileName | Path to output CSV file                             |

---

## Output

The result CSV will contain all original columns plus two new columns:

- **Topsis Score** – Performance score (0 to 1, higher is better)
- **Rank** – Rank of each alternative (1 = best)

---

## Algorithm Steps

1. Normalise the decision matrix
2. Calculate weighted normalised matrix
3. Determine ideal best and ideal worst solutions
4. Compute Euclidean distances from ideal solutions
5. Calculate performance score (closeness coefficient)
6. Rank alternatives

---

## Dependencies

- `numpy`
- `pandas`

---

## License

MIT License — © 2024 Akash