semvec/pypi-packages huggingface dataset:
ryzenai-lite 0.0.1
Lightweight inference library (ONNX) with pluggable backends (CPU / DirectML).
License: MIT
Requires Python: >=3.9
Keywords: onnx, inference, deep-learning, machine-learning, directml

ryzenai-lite
==============

ryzenai-lite is a small, minimal ONNX-based inference helper library that
provides a clean public API to load ONNX models and run inference on CPU or
GPU (DirectML/CUDA/ROCm when available). The library is intentionally
minimal to make it easy to plug into small projects and demos.

Quick start
-----------

1. Inspect model inputs:

```powershell
python example/inspect_model.py
```

2. Run a small SLM generation (greedy) with GPU (DirectML) preferred and CPU fallback:

```powershell
python example/slm_run.py --model example/models/bert-tiny.onnx --prompt "Once upon a time" --max-new-tokens 16 --device dml
```

3. GPU test (verify DirectML usage):

```powershell
python example/gpu_simple_test.py
```

Public API
----------

- `load_model(model_path: str, device_preference: Optional[List[str]] = None) -> Model`
- `Model` class with methods: `warmup`, `run`, `run_once`, `dispose`
- `device_info()` -> dict of available providers and platform
- `benchmark_model(...)` helper

See `DOCUMENTATION.md` for full details, examples and troubleshooting tips.

License
-------
MIT

Generated on: 2025-11-01
cwcwidth 0.1.12
Python bindings for wc(s)width
License: MIT
Requires Python: >=3.11

# Python bindings for wc(s)width

`cwcwidth` provides Python bindings for `wcwidth` and `wcswidth` functions defined in POSIX.1-2001
and POSIX.1-2008 based on [Cython](https://cython.org/). These functions compute the printable
length of a unicode character/string on a terminal. The module provides the same functions as
[wcwidth](https://pypi.org/project/wcwidth/) and its behavior is compatible.

On systems not conforming to POSIX.1-2001 and POSIX.1-2008, Markus Kuhn's
[implementation](https://www.cl.cam.ac.uk/~mgk25/ucs/wcwidth.c) is used to provide the
functionality.

## Dependencies

* `Cython >= 3.1` (optional, only for building). If Cython is not available, the C files are not
  regenerated from their source.

## Quick installation guide

`cwcwidth` can be installed via `pip`:
```sh
pip install cwcwidth
```
or by running:
```sh
python3 setup.py install
```

In case the extension should be built with the limited Python API, set the environment variable
`USE_LIMITED_API` to any value.

## Usage

```python3
>>> import cwcwidth
>>> cwcwidth.wcwidth("a")
1
>>> cwcwidth.wcswidth("コ")
2
>>> cwcwidth.wcswidth("コンニチハ, セカイ!")
19
>>> cwcwidth.wcswidth("コンニチハ, セカイ!", 5)
10
```

## Comparison with `wcwidth`

```python3
>>> import wcwidth, cwcwidth, timeit
>>> timeit.timeit(lambda: wcwidth.wcswidth("コンニチハ, セカイ!"))
19.14463168097427
>>> timeit.timeit(lambda: cwcwidth.wcswidth("コンニチハ, セカイ!"))
0.16294104099506512
```

## License

The code is licensed under the MIT license.