semvec/pypi-packages huggingface dataset:
tyo-mq-client 0.0.7
A tyo-mq client library
License: MIT
Keywords: tyo-mq socket.io node.js pub/sub publisher/subscriber

# tyo-mq-client-python
A TYO-MQ python client for TYO-MQ server.

## TYO-MQ server 
please refer to [TYO-MQ Server]{https://github.com/tyolab/tyo-mq}/server.js

In short, TYO-MQ is an implementation of pub/sub message distribution service using socket.io(webscoket).

### Creating a messaging server

```javascript
var MessageServer = require("tyo-mq").server;

var mq = new MessageServer();
mq.start();
```

### Creating a message producer and consumer

```python
from tyo_mq_client.message_queue import MessageQueue
from tyo_mq_client.socket import Socket
from tyo_mq_client.logger import Logger
from tyo_mq_client.constants import Constants

subscriber = None
producer = None
ready = [False, False]

mq = MessageQueue()

producer = mq.createPublisher("TYO Lab")

# A producer can be also a consumer
subscriber = producer

def on_message_published(message):
    print ("received message" + json.dumps(message))
    os._exit(1)

def check ():
    if (ready[0] and ready[1]):
        producer.produce({"message": "Hello World"})

def subscriber_on_connect () :
    Logger.log("Subscriber is connected")
    ready[0] = True
    subscriber.subscribe(producer.name, Constants.EVENT_DEFAULT, on_message_published, False)
    
def on_subscription (data) :
    print ("received subscription")
    producer.produce({"message1": "Hello World"})
    producer.on('test', on_message_published)
    producer.socket.emit('test')
    producer.produce({"message2": "Hello World"}, producer.eventDefault, Constants.METHOD_BROADCAST)

def producer_on_connect () :
    subscriber_on_connect() 

    Logger.log("Producer is connected")
    ready[1] = True
    producer.on_subscription_listener = on_subscription
    producer.on_subscriber_lost(on_subscriber_lost)

def on_subscriber_lost (data):
    message = json.dumps(data)
    Logger.log('Informed that connection with a subscriber (' + message["consumer"] + ') was lost')

producer.add_on_connect_listener(producer_on_connect)
producer.connect(-1)


```

## Publish tyo-mq-client-python to pypi

```bash
python setup.py sdist
twine upload dist/*
```

## Maintainer

[Eric Tang](https://twitter.com/_e_tang) @ [TYO LAB](http://tyo.com.au)
daml 0.56.0
DAML provides a simple interface to characterize image data and its impact on model performance across classification and object-detection tasks
License: MIT
Requires Python: <3.12,>=3.9

# Data-Analysis Metrics Library (DAML)

## About DAML

The Data-Analysis Metrics Library, or DAML, focuses on characterizing image data and its impact on model performance across classification and object-detection tasks.

<!-- start about -->

**Model-agnostic metrics that bound real-world performance**
- relevance/completeness/coverage
- metafeatures (data complexity)

**Model-specific metrics that guide model selection and training**
- dataset sufficiency
- data/model complexity mismatch

**Metrics for post-deployment monitoring of data with bounds on model performance to guide retraining**
- dataset-shift metrics
- model performance bounds under covariate shift
- guidance on sampling to assess model error and model retraining

<!-- end about -->

## Getting Started

### Requirements
- Python 3.9-3.11

### Installing DAML

You can install DAML directly from pypi.org using the following command.  The optional dependencies of DAML are `torch`, `tensorflow` and `all`.  Using `torch` enables Sufficiency metrics, and `tensorflow` enables OOD Detection.

```
pip install daml[all]
```

### Installing DAML from GitHub

To install DAML from source locally on Ubuntu, you will need `git-lfs` to download larger, binary source files and `poetry` for project dependency management.

```
sudo apt-get install git-lfs
pip install poetry
```

Pull the source down and change to the DAML project directory.
```
git clone https://github.com/aria-ml/daml.git
cd daml
```



Install DAML with optional dependencies for development.
```
poetry install --all-extras --with dev
```

Now that DAML is installed, you can run commands in the poetry virtual environment by prefixing shell commands with `poetry run`, or activate the virtual environment directly in the shell.
```
poetry shell
```

### Documentation and Tutorials
For more ideas on getting started using DAML in your workflow, additional information and tutorials are in our Sphinx documentation hosted on [Read the Docs](https://daml.readthedocs.io/).

## Attribution
This project uses code from the [Alibi-Detect](https://github.com/SeldonIO/alibi-detect) python library developed by SeldonIO.  Additional documentation from the developers are also available [here](https://docs.seldon.io/projects/alibi-detect/en/stable/).

## POCs
- **POC**: Scott Swan @scott.swan
- **DPOC**: Andrew Weng @aweng