semvec/pypi-packages huggingface dataset:
kubicle 0.1.29
Background jobs on Kubernetes
License: MIT
Requires Python: <4.0,>=3.10

# Kubicle

Python background jobs on Kubernetes

-> No runtime dependencies, simply run Python functions on Kubernetes and get the results back.

## Installation

```
pip install kubicle
```

## Usage

Define a python function with inputs and an output that use [pydantic](https://docs.pydantic.dev/latest/) `BaseModel`

```py
from pydantic import BaseModel

class Foo(BaseModel):
    a: int
    b: str

class Bar(BaseModel):
    c: float
    d: bool


def call_me_remote(foo: Foo) -> Bar:
    ...

```

Run as a Kubernetes job

```py
from kubicle import Runner

os.environ["JOB_IMG"] = "foo/bar:latest"

runner = Runner()

job = runner.run(call_me_remote, Foo(a=1, b="hello"))

```

Wait for the job to finish

```py
from kubicle import JobStatus

while True:
    job.refresh()
    if job.status == JobStatus.FINISHED:
        break
```

Get the result

```py
bar = Bar.model_validate_json(job.result)
```

### Local

When in development it can be handy to run the job locally.

Do this by setting env var `JOB_LOCAL=true` or passing the parameter on object creation `Runner(local=true)` and the job will execute using multiprocessing.

## Backends

Job storage can be backed by:

- Sqlite
- Postgresql

Sqlite will be used by default. To use postgres simply configure the env vars:

```sh
DB_TYPE=postgres
DB_NAME=jobs
DB_HOST=localhost
DB_USER=postgres
DB_PASS=abc123
```
machinerry 0.2.6
CherryPy-based framework for running tasks repeatedly.
License: MIT
Requires Python: >=2.7

.. _repository: https://github.com/the-allanc/machinerry/
.. _documentation: https://machinerry.readthedocs.io/en/stable/
.. _pypi: https://pypi.python.org/pypi/machinerry
.. _coveralls: https://coveralls.io/github/the-allanc/machinerry
.. _license: https://github.com/the-allanc/machinerry/master/LICENSE.txt
.. _travis: https://travis-ci.org/the-allanc/machinerry
.. _codeclimate: https://codeclimate.com/github/the-allanc/machinerry

.. |Build Status| image:: https://img.shields.io/travis/the-allanc/machinerry.svg
    :target: travis_
    :alt: Build Status
.. |Coverage| image:: https://img.shields.io/coveralls/the-allanc/machinerry.svg
    :target: coveralls_
    :alt: Coverage
.. |Docs| image:: https://readthedocs.org/projects/machinerry/badge/?version=stable&style=flat
    :target: documentation_
    :alt: Docs
.. |Release Version| image:: https://img.shields.io/pypi/pyversions/machinerry.svg
    :target: pypi_
    :alt: Release Version
.. |Python Version| image:: https://img.shields.io/pypi/v/machinerry.svg
    :target: pypi_
    :alt: Python Version
.. |License| image:: https://img.shields.io/pypi/l/machinerry.svg
    :target: license_
    :alt: License
.. |Code Climate| image:: https://img.shields.io/codeclimate/issues/github/the-allanc/machinerry.svg
    :target: codeclimate_
    :alt: Code Climate

|Docs| |Release Version| |Python Version| |License| |Build Status| |Coverage| |Code Climate|

.. all-content-above-will-be-included-in-sphinx-docs

You can browse the source code and file bug reports at the project repository_. Full documentation can be found `here`__.

__ documentation_
ovos-voice-embeddings-plugin 0.0.0a0
A voice recognition plugin for OVOS
License: MIT
Keywords: OVOS openvoiceos plugin voice recognition

# VoiceEmbeddingsRecognitionPlugin

The `VoiceEmbeddingsRecognitionPlugin` is a plugin for recognizing and managing voice embeddings.

It uses [Resemblyzer](https://github.com/resemble-ai/Resemblyzer) to extract speaker embeddings and integrates with  [ovos-chromadb-embeddings-plugin](https://github.com/TigreGotico/ovos-chromadb-embeddings-plugin) for storing and retrieving voice embeddings. 

## Features

- **Voice Embeddings Extraction**: Converts audio data into voice embeddings using the `VoiceEncoder` from `resemblyzer`.
- **Voice Data Storage**: Stores and retrieves voice embeddings using `ChromaEmbeddingsDB`.
- **Voice Data Management**: Allows for adding, querying, and predicting voice embeddings associated with user IDs.
- **Supports Multiple Audio Formats**: Can handle audio data in various formats, including `wav` and `flac`.

## Usage

Here is a quick example of how to use the `VoiceEmbeddingsRecognitionPlugin`:

```python
from ovos_voice_embeddings import VoiceEmbeddingsRecognitionPlugin
from resemblyzer import preprocess_wav
from speech_recognition import Recognizer, AudioFile
from ovos_chromadb_embeddings import ChromaEmbeddingsDB

db = ChromaEmbeddingsDB("./voice_db")
v = VoiceEmbeddingsRecognitionPlugin(db)

a = "/home/miro/PycharmProjects/ovos-user-id/2609-156975-0001.flac"
b = "/home/miro/PycharmProjects/ovos-user-id/qCCWXoCURKY.mp3"
b2 = "/home/miro/PycharmProjects/ovos-user-id/4glfwiMXgwQ.mp3"

with AudioFile(a) as source:
    audio = Recognizer().record(source)
v.add_voice("user", audio)

wav = preprocess_wav(b)
v.add_voice("donald", wav)

wav = preprocess_wav(b2)
print(v.predict(wav))
print(v.prompt(wav))

```
ovos-face-embeddings-plugin 0.0.0a0
A face recognition plugin for OVOS
License: MIT
Keywords: OVOS openvoiceos plugin face recognition

# FaceEmbeddingsRecognitionPlugin

The `FaceEmbeddingsRecognitionPlugin` is a plugin designed for recognizing and managing face embeddings. 

It uses [face_recognition](https://github.com/ageitgey/face_recognition) to extract face embeddings and integrates with  [ovos-chromadb-embeddings-plugin](https://github.com/TigreGotico/ovos-chromadb-embeddings-plugin) for storing and retrieving voice embeddings. 

## Features

- **Face Embeddings Extraction**: Converts images into face embeddings using the `face_recognition` library.
- **Face Data Storage**: Stores and retrieves face embeddings using `ChromaEmbeddingsDB`.
- **Face Data Management**: Provides methods to add, query, and delete face embeddings associated with user IDs.

**Note:** `face_recognition` also requires `dlib`, which may require additional setup. Please refer to the [face_recognition installation instructions](https://github.com/ageitgey/face_recognition#installation) for detailed steps.

## Usage

Here is a quick example of how to use the `FaceEmbeddingsRecognitionPlugin`:

```python
from ovos_face_embeddings import FaceEmbeddingsRecognitionPlugin
from ovos_chromadb_embeddings import ChromaEmbeddingsDB

db = ChromaEmbeddingsDB("./face_db")
f = FaceEmbeddingsRecognitionPlugin(db)

a = "/home/miro/PycharmProjects/ovos-user-id/a1.jpg"
a2 = "/home/miro/PycharmProjects/ovos-user-id/a2.jpg"
b = "/home/miro/PycharmProjects/ovos-user-id/b.jpg"

import face_recognition # helper to load from file easily
e1 = face_recognition.load_image_file(a)
e2 = face_recognition.load_image_file(a2)
b = face_recognition.load_image_file(b)

f.add_face("arnold", e1)
f.add_face("silvester", b)
print(f.query(e1))
print(f.query(e2))
print(f.query(b))
```