mosec


Namemosec JSON
Version 0.8.9 PyPI version JSON
download
home_pagehttps://github.com/mosecorg/mosec
SummaryModel Serving made Efficient in the Cloud
upload_time2024-11-13 15:07:05
maintainerNone
docs_urlNone
authorKeming Yang
requires_python>=3.8
licenseApache-2.0
keywords machine learning deep learning model serving
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            <p align="center">
  <img src="https://user-images.githubusercontent.com/38581401/240117836-f06199ba-c80d-413a-9cb4-5adc76316bda.png" width=90% alt="MOSEC" />
</p>

<p align="center">
  <a href="https://discord.gg/Jq5vxuH69W">
    <img alt="discord invitation link" src="https://dcbadge.vercel.app/api/server/Jq5vxuH69W?style=flat">
  </a>
  <a href="https://pypi.org/project/mosec/">
    <img src="https://badge.fury.io/py/mosec.svg" alt="PyPI version" height="20">
  </a>
  <a href="https://anaconda.org/conda-forge/mosec">
    <img src="https://anaconda.org/conda-forge/mosec/badges/version.svg" alt="conda-forge">
  </a>
  <a href="https://pypi.org/project/mosec">
    <img src="https://img.shields.io/pypi/pyversions/mosec" alt="Python Version" />
  </a>
  <a href="https://pepy.tech/project/mosec">
    <img src="https://static.pepy.tech/badge/mosec/month" alt="PyPi monthly Downloads" height="20">
  </a>
  <a href="https://tldrlegal.com/license/apache-license-2.0-(apache-2.0)">
    <img src="https://img.shields.io/github/license/mosecorg/mosec" alt="License" height="20">
  </a>
  <a href="https://github.com/mosecorg/mosec/actions/workflows/check.yml?query=workflow%3A%22lint+and+test%22+branch%3Amain">
    <img src="https://github.com/mosecorg/mosec/actions/workflows/check.yml/badge.svg?branch=main" alt="Check status" height="20">
  </a>
</p>

<p align="center">
  <i>Model Serving made Efficient in the Cloud.</i>
</p>

## Introduction

<p align="center">
  <img src="https://user-images.githubusercontent.com/38581401/234162688-efd74e46-4063-4624-ac32-b197e4d8e56b.png" width=70% alt="MOSEC" />
</p>

Mosec is a high-performance and flexible model serving framework for building ML model-enabled backend and microservices. It bridges the gap between any machine learning models you just trained and the efficient online service API.

- **Highly performant**: web layer and task coordination built with Rust 🦀, which offers blazing speed in addition to efficient CPU utilization powered by async I/O
- **Ease of use**: user interface purely in Python 🐍, by which users can serve their models in an ML framework-agnostic manner using the same code as they do for offline testing
- **Dynamic batching**: aggregate requests from different users for batched inference and distribute results back
- **Pipelined stages**: spawn multiple processes for pipelined stages to handle CPU/GPU/IO mixed workloads
- **Cloud friendly**: designed to run in the cloud, with the model warmup, graceful shutdown, and Prometheus monitoring metrics, easily managed by Kubernetes or any container orchestration systems
- **Do one thing well**: focus on the online serving part, users can pay attention to the model optimization and business logic

## Installation

Mosec requires Python 3.7 or above. Install the latest [PyPI package](https://pypi.org/project/mosec/) for Linux x86_64 or macOS x86_64/ARM64 with:

```shell
pip install -U mosec
# or install with conda
conda install conda-forge::mosec
```

To build from the source code, install [Rust](https://www.rust-lang.org/) and run the following command:

```shell
make package
```

You will get a mosec wheel file in the `dist` folder.

## Usage

We demonstrate how Mosec can help you easily host a pre-trained stable diffusion model as a service. You need to install [diffusers](https://github.com/huggingface/diffusers) and [transformers](https://github.com/huggingface/transformers) as prerequisites:

```shell
pip install --upgrade diffusers[torch] transformers
```

### Write the server

<details>
<summary>Click me for server codes with explanations.</summary>

Firstly, we import the libraries and set up a basic logger to better observe what happens.

```python
from io import BytesIO
from typing import List

import torch  # type: ignore
from diffusers import StableDiffusionPipeline  # type: ignore

from mosec import Server, Worker, get_logger
from mosec.mixin import MsgpackMixin

logger = get_logger()
```

Then, we **build an API** for clients to query a text prompt and obtain an image based on the [stable-diffusion-v1-5 model](https://huggingface.co/stable-diffusion-v1-5/stable-diffusion-v1-5) in just 3 steps.

1) Define your service as a class which inherits `mosec.Worker`. Here we also inherit `MsgpackMixin` to employ the [msgpack](https://msgpack.org/index.html) serialization format<sup>(a)</sup></a>.

2) Inside the `__init__` method, initialize your model and put it onto the corresponding device. Optionally you can assign `self.example` with some data to warm up<sup>(b)</sup></a> the model. Note that the data should be compatible with your handler's input format, which we detail next.

3) Override the `forward` method to write your service handler<sup>(c)</sup></a>, with the signature `forward(self, data: Any | List[Any]) -> Any | List[Any]`. Receiving/returning a single item or a tuple depends on whether [dynamic batching](#configuration)<sup>(d)</sup></a> is configured.


```python
class StableDiffusion(MsgpackMixin, Worker):
    def __init__(self):
        self.pipe = StableDiffusionPipeline.from_pretrained(
            "sd-legacy/stable-diffusion-v1-5", torch_dtype=torch.float16
        )
        self.pipe.enable_model_cpu_offload()
        self.example = ["useless example prompt"] * 4  # warmup (batch_size=4)

    def forward(self, data: List[str]) -> List[memoryview]:
        logger.debug("generate images for %s", data)
        res = self.pipe(data)
        logger.debug("NSFW: %s", res[1])
        images = []
        for img in res[0]:
            dummy_file = BytesIO()
            img.save(dummy_file, format="JPEG")
            images.append(dummy_file.getbuffer())
        return images
```

> [!NOTE]
>
> (a) In this example we return an image in the binary format, which JSON does not support (unless encoded with base64 that makes the payload larger). Hence, msgpack suits our need better. If we do not inherit `MsgpackMixin`, JSON will be used by default. In other words, the protocol of the service request/response can be either msgpack, JSON, or any other format (check our [mixins](https://mosecorg.github.io/mosec/reference/interface.html#module-mosec.mixin)).
>
> (b) Warm-up usually helps to allocate GPU memory in advance. If the warm-up example is specified, the service will only be ready after the example is forwarded through the handler. However, if no example is given, the first request's latency is expected to be longer. The `example` should be set as a single item or a tuple depending on what `forward` expects to receive. Moreover, in the case where you want to warm up with multiple different examples, you may set `multi_examples` (demo [here](https://mosecorg.github.io/mosec/examples/jax.html)).
>
> (c) This example shows a single-stage service, where the `StableDiffusion` worker directly takes in client's prompt request and responds the image. Thus the `forward` can be considered as a complete service handler. However, we can also design a multi-stage service with workers doing different jobs (e.g., downloading images, model inference, post-processing) in a pipeline. In this case, the whole pipeline is considered as the service handler, with the first worker taking in the request and the last worker sending out the response. The data flow between workers is done by inter-process communication.
>
> (d) Since dynamic batching is enabled in this example, the `forward` method will wishfully receive a _list_ of string, e.g., `['a cute cat playing with a red ball', 'a man sitting in front of a computer', ...]`, aggregated from different clients for _batch inference_, improving the system throughput.

Finally, we append the worker to the server to construct a *single-stage* workflow (multiple stages can be [pipelined](https://en.wikipedia.org/wiki/Pipeline_(computing)) to further boost the throughput, see [this example](https://mosecorg.github.io/mosec/examples/pytorch.html#computer-vision)), and specify the number of processes we want it to run in parallel (`num=1`), and the maximum batch size (`max_batch_size=4`, the maximum number of requests dynamic batching will accumulate before timeout; timeout is defined with the `max_wait_time=10` in milliseconds, meaning the longest time Mosec waits until sending the batch to the Worker).

```python
if __name__ == "__main__":
    server = Server()
    # 1) `num` specifies the number of processes that will be spawned to run in parallel.
    # 2) By configuring the `max_batch_size` with the value > 1, the input data in your
    # `forward` function will be a list (batch); otherwise, it's a single item.
    server.append_worker(StableDiffusion, num=1, max_batch_size=4, max_wait_time=10)
    server.run()
```
</details>

### Run the server

<details>
<summary>Click me to see how to run and query the server.</summary>

The above snippets are merged in our example file. You may directly run at the project root level. We first have a look at the _command line arguments_ (explanations [here](https://mosecorg.github.io/mosec/reference/arguments.html)):

```shell
python examples/stable_diffusion/server.py --help
```

Then let's start the server with debug logs:

```shell
python examples/stable_diffusion/server.py --log-level debug --timeout 30000
```

Open `http://127.0.0.1:8000/openapi/swagger/` in your browser to get the OpenAPI doc.

And in another terminal, test it:

```shell
python examples/stable_diffusion/client.py --prompt "a cute cat playing with a red ball" --output cat.jpg --port 8000
```

You will get an image named "cat.jpg" in the current directory.

You can check the metrics:

```shell
curl http://127.0.0.1:8000/metrics
```

That's it! You have just hosted your **_stable-diffusion model_** as a service! 😉
</details>

## Examples

More ready-to-use examples can be found in the [Example](https://mosecorg.github.io/mosec/examples/index.html) section. It includes:

- [Pipeline](https://mosecorg.github.io/mosec/examples/echo.html): a simple echo demo even without any ML model.
- [Request validation](https://mosecorg.github.io/mosec/examples/validate.html): validate the request with type annotation.
- [Multiple route](https://mosecorg.github.io/mosec/examples/multi_route.html): serve multiple models in one service
- [Embedding service](https://mosecorg.github.io/mosec/examples/embedding.html): OpenAI compatible embedding service
- [Reranking service](https://mosecorg.github.io/mosec/examples/rerank.html): rerank a list of passages based on a query
- [Shared memory IPC](https://mosecorg.github.io/mosec/examples/ipc.html): inter-process communication with shared memory.
- [Customized GPU allocation](https://mosecorg.github.io/mosec/examples/env.html): deploy multiple replicas, each using different GPUs.
- [Customized metrics](https://mosecorg.github.io/mosec/examples/metric.html): record your own metrics for monitoring.
- [Jax jitted inference](https://mosecorg.github.io/mosec/examples/jax.html): just-in-time compilation speeds up the inference.
- PyTorch deep learning models:
  - [sentiment analysis](https://mosecorg.github.io/mosec/examples/pytorch.html#natural-language-processing): infer the sentiment of a sentence.
  - [image recognition](https://mosecorg.github.io/mosec/examples/pytorch.html#computer-vision): categorize a given image.
  - [stable diffusion](https://mosecorg.github.io/mosec/examples/stable_diffusion.html): generate images based on texts, with msgpack serialization.

## Configuration

- Dynamic batching
  - `max_batch_size` and `max_wait_time (millisecond)` are configured when you call `append_worker`.
  - Make sure inference with the `max_batch_size` value won't cause the out-of-memory in GPU.
  - Normally, `max_wait_time` should be less than the batch inference time.
  - If enabled, it will collect a batch either when the number of accumulated requests reaches `max_batch_size` or when `max_wait_time` has elapsed. The service will benefit from this feature when the traffic is high.
- Check the [arguments doc](https://mosecorg.github.io/mosec/reference/arguments.html) for other configurations.

## Deployment

- If you're looking for a GPU base image with `mosec` installed, you can check the official image [`mosecorg/mosec`](https://hub.docker.com/r/mosecorg/mosec). For the complex use case, check out [envd](https://github.com/tensorchord/envd).
- This service doesn't need Gunicorn or NGINX, but you can certainly use the ingress controller when necessary.
- This service should be the PID 1 process in the container since it controls multiple processes. If you need to run multiple processes in one container, you will need a supervisor. You may choose [Supervisor](https://github.com/Supervisor/supervisor) or [Horust](https://github.com/FedericoPonzi/Horust).
- Remember to collect the **metrics**.
  - `mosec_service_batch_size_bucket` shows the batch size distribution.
  - `mosec_service_batch_duration_second_bucket` shows the duration of dynamic batching for each connection in each stage (starts from receiving the first task).
  - `mosec_service_process_duration_second_bucket` shows the duration of processing for each connection in each stage (including the IPC time but excluding the `mosec_service_batch_duration_second_bucket`).
  - `mosec_service_remaining_task` shows the number of currently processing tasks.
  - `mosec_service_throughput` shows the service throughput.
- Stop the service with `SIGINT` (`CTRL+C`) or `SIGTERM` (`kill {PID}`) since it has the graceful shutdown logic.

## Performance tuning

- Find out the best `max_batch_size` and `max_wait_time` for your inference service. The metrics will show the histograms of the real batch size and batch duration. Those are the key information to adjust these two parameters.
- Try to split the whole inference process into separate CPU and GPU stages (ref [DistilBERT](https://mosecorg.github.io/mosec/examples/pytorch.html#natural-language-processing)). Different stages will be run in a [data pipeline](https://en.wikipedia.org/wiki/Pipeline_(software)), which will keep the GPU busy.
- You can also adjust the number of workers in each stage. For example, if your pipeline consists of a CPU stage for preprocessing and a GPU stage for model inference, increasing the number of CPU-stage workers can help to produce more data to be batched for model inference at the GPU stage; increasing the GPU-stage workers can fully utilize the GPU memory and computation power. Both ways may contribute to higher GPU utilization, which consequently results in higher service throughput.
- For multi-stage services, note that the data passing through different stages will be serialized/deserialized by the `serialize_ipc/deserialize_ipc` methods, so extremely large data might make the whole pipeline slow. The serialized data is passed to the next stage through rust by default, you could enable shared memory to potentially reduce the latency (ref [RedisShmIPCMixin](https://mosecorg.github.io/mosec/examples/ipc.html#redis-shm-ipc-py)).
- You should choose appropriate `serialize/deserialize` methods, which are used to decode the user request and encode the response. By default, both are using JSON. However, images and embeddings are not well supported by JSON. You can choose msgpack which is faster and binary compatible (ref [Stable Diffusion](https://mosecorg.github.io/mosec/examples/stable_diffusion.html)).
- Configure the threads for OpenBLAS or MKL. It might not be able to choose the most suitable CPUs used by the current Python process. You can configure it for each worker by using the [env](https://mosecorg.github.io/mosec/reference/interface.html#mosec.server.Server.append_worker) (ref [custom GPU allocation](https://mosecorg.github.io/mosec/examples/env.html)).
- Enable HTTP/2 from client side. `mosec` automatically adapts to user's protocol (e.g., HTTP/2) since v0.8.8.

## Adopters

Here are some of the companies and individual users that are using Mosec:

- [Modelz](https://modelz.ai): Serverless platform for ML inference.
- [MOSS](https://github.com/OpenLMLab/MOSS/blob/main/README_en.md): An open sourced conversational language model like ChatGPT.
- [TencentCloud](https://www.tencentcloud.com/document/product/1141/45261): Tencent Cloud Machine Learning Platform, using Mosec as the [core inference server framework](https://cloud.tencent.com/document/product/851/74148).
- [TensorChord](https://github.com/tensorchord): Cloud native AI infrastructure company.
- [OAT](https://github.com/sail-sg/oat): Serving reward models for online LLM alignment.

## Citation

If you find this software useful for your research, please consider citing

```
@software{yang2021mosec,
  title = {{MOSEC: Model Serving made Efficient in the Cloud}},
  author = {Yang, Keming and Liu, Zichen and Cheng, Philip},
  url = {https://github.com/mosecorg/mosec},
  year = {2021}
}
```

## Contributing

We welcome any kind of contribution. Please give us feedback by [raising issues](https://github.com/mosecorg/mosec/issues/new/choose) or discussing on [Discord](https://discord.gg/Jq5vxuH69W). You could also directly [contribute](https://mosecorg.github.io/mosec/development/contributing.html) your code and pull request!

To start develop, you can use [envd](https://github.com/tensorchord/envd) to create an isolated and clean Python & Rust environment. Check the [envd-docs](https://envd.tensorchord.ai/) or [build.envd](https://github.com/mosecorg/mosec/blob/main/build.envd) for more information.

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/mosecorg/mosec",
    "name": "mosec",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": null,
    "keywords": "machine learning, deep learning, model serving",
    "author": "Keming Yang",
    "author_email": "Keming <kemingy94@gmail.com>, Zichen <lkevinzc@gmail.com>",
    "download_url": "https://files.pythonhosted.org/packages/8e/26/650b6f5c5a7c83fdbdcf5ea1b0821a4774dafb2e680f3efd0fc9b87da093/mosec-0.8.9.tar.gz",
    "platform": null,
    "description": "<p align=\"center\">\n  <img src=\"https://user-images.githubusercontent.com/38581401/240117836-f06199ba-c80d-413a-9cb4-5adc76316bda.png\" width=90% alt=\"MOSEC\" />\n</p>\n\n<p align=\"center\">\n  <a href=\"https://discord.gg/Jq5vxuH69W\">\n    <img alt=\"discord invitation link\" src=\"https://dcbadge.vercel.app/api/server/Jq5vxuH69W?style=flat\">\n  </a>\n  <a href=\"https://pypi.org/project/mosec/\">\n    <img src=\"https://badge.fury.io/py/mosec.svg\" alt=\"PyPI version\" height=\"20\">\n  </a>\n  <a href=\"https://anaconda.org/conda-forge/mosec\">\n    <img src=\"https://anaconda.org/conda-forge/mosec/badges/version.svg\" alt=\"conda-forge\">\n  </a>\n  <a href=\"https://pypi.org/project/mosec\">\n    <img src=\"https://img.shields.io/pypi/pyversions/mosec\" alt=\"Python Version\" />\n  </a>\n  <a href=\"https://pepy.tech/project/mosec\">\n    <img src=\"https://static.pepy.tech/badge/mosec/month\" alt=\"PyPi monthly Downloads\" height=\"20\">\n  </a>\n  <a href=\"https://tldrlegal.com/license/apache-license-2.0-(apache-2.0)\">\n    <img src=\"https://img.shields.io/github/license/mosecorg/mosec\" alt=\"License\" height=\"20\">\n  </a>\n  <a href=\"https://github.com/mosecorg/mosec/actions/workflows/check.yml?query=workflow%3A%22lint+and+test%22+branch%3Amain\">\n    <img src=\"https://github.com/mosecorg/mosec/actions/workflows/check.yml/badge.svg?branch=main\" alt=\"Check status\" height=\"20\">\n  </a>\n</p>\n\n<p align=\"center\">\n  <i>Model Serving made Efficient in the Cloud.</i>\n</p>\n\n## Introduction\n\n<p align=\"center\">\n  <img src=\"https://user-images.githubusercontent.com/38581401/234162688-efd74e46-4063-4624-ac32-b197e4d8e56b.png\" width=70% alt=\"MOSEC\" />\n</p>\n\nMosec is a high-performance and flexible model serving framework for building ML model-enabled backend and microservices. It bridges the gap between any machine learning models you just trained and the efficient online service API.\n\n- **Highly performant**: web layer and task coordination built with Rust \ud83e\udd80, which offers blazing speed in addition to efficient CPU utilization powered by async I/O\n- **Ease of use**: user interface purely in Python \ud83d\udc0d, by which users can serve their models in an ML framework-agnostic manner using the same code as they do for offline testing\n- **Dynamic batching**: aggregate requests from different users for batched inference and distribute results back\n- **Pipelined stages**: spawn multiple processes for pipelined stages to handle CPU/GPU/IO mixed workloads\n- **Cloud friendly**: designed to run in the cloud, with the model warmup, graceful shutdown, and Prometheus monitoring metrics, easily managed by Kubernetes or any container orchestration systems\n- **Do one thing well**: focus on the online serving part, users can pay attention to the model optimization and business logic\n\n## Installation\n\nMosec requires Python 3.7 or above. Install the latest [PyPI package](https://pypi.org/project/mosec/) for Linux x86_64 or macOS x86_64/ARM64 with:\n\n```shell\npip install -U mosec\n# or install with conda\nconda install conda-forge::mosec\n```\n\nTo build from the source code, install [Rust](https://www.rust-lang.org/) and run the following command:\n\n```shell\nmake package\n```\n\nYou will get a mosec wheel file in the `dist` folder.\n\n## Usage\n\nWe demonstrate how Mosec can help you easily host a pre-trained stable diffusion model as a service. You need to install [diffusers](https://github.com/huggingface/diffusers) and [transformers](https://github.com/huggingface/transformers) as prerequisites:\n\n```shell\npip install --upgrade diffusers[torch] transformers\n```\n\n### Write the server\n\n<details>\n<summary>Click me for server codes with explanations.</summary>\n\nFirstly, we import the libraries and set up a basic logger to better observe what happens.\n\n```python\nfrom io import BytesIO\nfrom typing import List\n\nimport torch  # type: ignore\nfrom diffusers import StableDiffusionPipeline  # type: ignore\n\nfrom mosec import Server, Worker, get_logger\nfrom mosec.mixin import MsgpackMixin\n\nlogger = get_logger()\n```\n\nThen, we **build an API** for clients to query a text prompt and obtain an image based on the [stable-diffusion-v1-5 model](https://huggingface.co/stable-diffusion-v1-5/stable-diffusion-v1-5) in just 3 steps.\n\n1) Define your service as a class which inherits `mosec.Worker`. Here we also inherit `MsgpackMixin` to employ the [msgpack](https://msgpack.org/index.html) serialization format<sup>(a)</sup></a>.\n\n2) Inside the `__init__` method, initialize your model and put it onto the corresponding device. Optionally you can assign `self.example` with some data to warm up<sup>(b)</sup></a> the model. Note that the data should be compatible with your handler's input format, which we detail next.\n\n3) Override the `forward` method to write your service handler<sup>(c)</sup></a>, with the signature `forward(self, data: Any | List[Any]) -> Any | List[Any]`. Receiving/returning a single item or a tuple depends on whether [dynamic batching](#configuration)<sup>(d)</sup></a> is configured.\n\n\n```python\nclass StableDiffusion(MsgpackMixin, Worker):\n    def __init__(self):\n        self.pipe = StableDiffusionPipeline.from_pretrained(\n            \"sd-legacy/stable-diffusion-v1-5\", torch_dtype=torch.float16\n        )\n        self.pipe.enable_model_cpu_offload()\n        self.example = [\"useless example prompt\"] * 4  # warmup (batch_size=4)\n\n    def forward(self, data: List[str]) -> List[memoryview]:\n        logger.debug(\"generate images for %s\", data)\n        res = self.pipe(data)\n        logger.debug(\"NSFW: %s\", res[1])\n        images = []\n        for img in res[0]:\n            dummy_file = BytesIO()\n            img.save(dummy_file, format=\"JPEG\")\n            images.append(dummy_file.getbuffer())\n        return images\n```\n\n> [!NOTE]\n>\n> (a) In this example we return an image in the binary format, which JSON does not support (unless encoded with base64 that makes the payload larger). Hence, msgpack suits our need better. If we do not inherit `MsgpackMixin`, JSON will be used by default. In other words, the protocol of the service request/response can be either msgpack, JSON, or any other format (check our [mixins](https://mosecorg.github.io/mosec/reference/interface.html#module-mosec.mixin)).\n>\n> (b) Warm-up usually helps to allocate GPU memory in advance. If the warm-up example is specified, the service will only be ready after the example is forwarded through the handler. However, if no example is given, the first request's latency is expected to be longer. The `example` should be set as a single item or a tuple depending on what `forward` expects to receive. Moreover, in the case where you want to warm up with multiple different examples, you may set `multi_examples` (demo [here](https://mosecorg.github.io/mosec/examples/jax.html)).\n>\n> (c) This example shows a single-stage service, where the `StableDiffusion` worker directly takes in client's prompt request and responds the image. Thus the `forward` can be considered as a complete service handler. However, we can also design a multi-stage service with workers doing different jobs (e.g., downloading images, model inference, post-processing) in a pipeline. In this case, the whole pipeline is considered as the service handler, with the first worker taking in the request and the last worker sending out the response. The data flow between workers is done by inter-process communication.\n>\n> (d) Since dynamic batching is enabled in this example, the `forward` method will wishfully receive a _list_ of string, e.g., `['a cute cat playing with a red ball', 'a man sitting in front of a computer', ...]`, aggregated from different clients for _batch inference_, improving the system throughput.\n\nFinally, we append the worker to the server to construct a *single-stage* workflow (multiple stages can be [pipelined](https://en.wikipedia.org/wiki/Pipeline_(computing)) to further boost the throughput, see [this example](https://mosecorg.github.io/mosec/examples/pytorch.html#computer-vision)), and specify the number of processes we want it to run in parallel (`num=1`), and the maximum batch size (`max_batch_size=4`, the maximum number of requests dynamic batching will accumulate before timeout; timeout is defined with the `max_wait_time=10` in milliseconds, meaning the longest time Mosec waits until sending the batch to the Worker).\n\n```python\nif __name__ == \"__main__\":\n    server = Server()\n    # 1) `num` specifies the number of processes that will be spawned to run in parallel.\n    # 2) By configuring the `max_batch_size` with the value > 1, the input data in your\n    # `forward` function will be a list (batch); otherwise, it's a single item.\n    server.append_worker(StableDiffusion, num=1, max_batch_size=4, max_wait_time=10)\n    server.run()\n```\n</details>\n\n### Run the server\n\n<details>\n<summary>Click me to see how to run and query the server.</summary>\n\nThe above snippets are merged in our example file. You may directly run at the project root level. We first have a look at the _command line arguments_ (explanations [here](https://mosecorg.github.io/mosec/reference/arguments.html)):\n\n```shell\npython examples/stable_diffusion/server.py --help\n```\n\nThen let's start the server with debug logs:\n\n```shell\npython examples/stable_diffusion/server.py --log-level debug --timeout 30000\n```\n\nOpen `http://127.0.0.1:8000/openapi/swagger/` in your browser to get the OpenAPI doc.\n\nAnd in another terminal, test it:\n\n```shell\npython examples/stable_diffusion/client.py --prompt \"a cute cat playing with a red ball\" --output cat.jpg --port 8000\n```\n\nYou will get an image named \"cat.jpg\" in the current directory.\n\nYou can check the metrics:\n\n```shell\ncurl http://127.0.0.1:8000/metrics\n```\n\nThat's it! You have just hosted your **_stable-diffusion model_** as a service! \ud83d\ude09\n</details>\n\n## Examples\n\nMore ready-to-use examples can be found in the [Example](https://mosecorg.github.io/mosec/examples/index.html) section. It includes:\n\n- [Pipeline](https://mosecorg.github.io/mosec/examples/echo.html): a simple echo demo even without any ML model.\n- [Request validation](https://mosecorg.github.io/mosec/examples/validate.html): validate the request with type annotation.\n- [Multiple route](https://mosecorg.github.io/mosec/examples/multi_route.html): serve multiple models in one service\n- [Embedding service](https://mosecorg.github.io/mosec/examples/embedding.html): OpenAI compatible embedding service\n- [Reranking service](https://mosecorg.github.io/mosec/examples/rerank.html): rerank a list of passages based on a query\n- [Shared memory IPC](https://mosecorg.github.io/mosec/examples/ipc.html): inter-process communication with shared memory.\n- [Customized GPU allocation](https://mosecorg.github.io/mosec/examples/env.html): deploy multiple replicas, each using different GPUs.\n- [Customized metrics](https://mosecorg.github.io/mosec/examples/metric.html): record your own metrics for monitoring.\n- [Jax jitted inference](https://mosecorg.github.io/mosec/examples/jax.html): just-in-time compilation speeds up the inference.\n- PyTorch deep learning models:\n  - [sentiment analysis](https://mosecorg.github.io/mosec/examples/pytorch.html#natural-language-processing): infer the sentiment of a sentence.\n  - [image recognition](https://mosecorg.github.io/mosec/examples/pytorch.html#computer-vision): categorize a given image.\n  - [stable diffusion](https://mosecorg.github.io/mosec/examples/stable_diffusion.html): generate images based on texts, with msgpack serialization.\n\n## Configuration\n\n- Dynamic batching\n  - `max_batch_size` and `max_wait_time (millisecond)` are configured when you call `append_worker`.\n  - Make sure inference with the `max_batch_size` value won't cause the out-of-memory in GPU.\n  - Normally, `max_wait_time` should be less than the batch inference time.\n  - If enabled, it will collect a batch either when the number of accumulated requests reaches `max_batch_size` or when `max_wait_time` has elapsed. The service will benefit from this feature when the traffic is high.\n- Check the [arguments doc](https://mosecorg.github.io/mosec/reference/arguments.html) for other configurations.\n\n## Deployment\n\n- If you're looking for a GPU base image with `mosec` installed, you can check the official image [`mosecorg/mosec`](https://hub.docker.com/r/mosecorg/mosec). For the complex use case, check out [envd](https://github.com/tensorchord/envd).\n- This service doesn't need Gunicorn or NGINX, but you can certainly use the ingress controller when necessary.\n- This service should be the PID 1 process in the container since it controls multiple processes. If you need to run multiple processes in one container, you will need a supervisor. You may choose [Supervisor](https://github.com/Supervisor/supervisor) or [Horust](https://github.com/FedericoPonzi/Horust).\n- Remember to collect the **metrics**.\n  - `mosec_service_batch_size_bucket` shows the batch size distribution.\n  - `mosec_service_batch_duration_second_bucket` shows the duration of dynamic batching for each connection in each stage (starts from receiving the first task).\n  - `mosec_service_process_duration_second_bucket` shows the duration of processing for each connection in each stage (including the IPC time but excluding the `mosec_service_batch_duration_second_bucket`).\n  - `mosec_service_remaining_task` shows the number of currently processing tasks.\n  - `mosec_service_throughput` shows the service throughput.\n- Stop the service with `SIGINT` (`CTRL+C`) or `SIGTERM` (`kill {PID}`) since it has the graceful shutdown logic.\n\n## Performance tuning\n\n- Find out the best `max_batch_size` and `max_wait_time` for your inference service. The metrics will show the histograms of the real batch size and batch duration. Those are the key information to adjust these two parameters.\n- Try to split the whole inference process into separate CPU and GPU stages (ref [DistilBERT](https://mosecorg.github.io/mosec/examples/pytorch.html#natural-language-processing)). Different stages will be run in a [data pipeline](https://en.wikipedia.org/wiki/Pipeline_(software)), which will keep the GPU busy.\n- You can also adjust the number of workers in each stage. For example, if your pipeline consists of a CPU stage for preprocessing and a GPU stage for model inference, increasing the number of CPU-stage workers can help to produce more data to be batched for model inference at the GPU stage; increasing the GPU-stage workers can fully utilize the GPU memory and computation power. Both ways may contribute to higher GPU utilization, which consequently results in higher service throughput.\n- For multi-stage services, note that the data passing through different stages will be serialized/deserialized by the `serialize_ipc/deserialize_ipc` methods, so extremely large data might make the whole pipeline slow. The serialized data is passed to the next stage through rust by default, you could enable shared memory to potentially reduce the latency (ref [RedisShmIPCMixin](https://mosecorg.github.io/mosec/examples/ipc.html#redis-shm-ipc-py)).\n- You should choose appropriate `serialize/deserialize` methods, which are used to decode the user request and encode the response. By default, both are using JSON. However, images and embeddings are not well supported by JSON. You can choose msgpack which is faster and binary compatible (ref [Stable Diffusion](https://mosecorg.github.io/mosec/examples/stable_diffusion.html)).\n- Configure the threads for OpenBLAS or MKL. It might not be able to choose the most suitable CPUs used by the current Python process. You can configure it for each worker by using the [env](https://mosecorg.github.io/mosec/reference/interface.html#mosec.server.Server.append_worker) (ref [custom GPU allocation](https://mosecorg.github.io/mosec/examples/env.html)).\n- Enable HTTP/2 from client side. `mosec` automatically adapts to user's protocol (e.g., HTTP/2) since v0.8.8.\n\n## Adopters\n\nHere are some of the companies and individual users that are using Mosec:\n\n- [Modelz](https://modelz.ai): Serverless platform for ML inference.\n- [MOSS](https://github.com/OpenLMLab/MOSS/blob/main/README_en.md): An open sourced conversational language model like ChatGPT.\n- [TencentCloud](https://www.tencentcloud.com/document/product/1141/45261): Tencent Cloud Machine Learning Platform, using Mosec as the [core inference server framework](https://cloud.tencent.com/document/product/851/74148).\n- [TensorChord](https://github.com/tensorchord): Cloud native AI infrastructure company.\n- [OAT](https://github.com/sail-sg/oat): Serving reward models for online LLM alignment.\n\n## Citation\n\nIf you find this software useful for your research, please consider citing\n\n```\n@software{yang2021mosec,\n  title = {{MOSEC: Model Serving made Efficient in the Cloud}},\n  author = {Yang, Keming and Liu, Zichen and Cheng, Philip},\n  url = {https://github.com/mosecorg/mosec},\n  year = {2021}\n}\n```\n\n## Contributing\n\nWe welcome any kind of contribution. Please give us feedback by [raising issues](https://github.com/mosecorg/mosec/issues/new/choose) or discussing on [Discord](https://discord.gg/Jq5vxuH69W). You could also directly [contribute](https://mosecorg.github.io/mosec/development/contributing.html) your code and pull request!\n\nTo start develop, you can use [envd](https://github.com/tensorchord/envd) to create an isolated and clean Python & Rust environment. Check the [envd-docs](https://envd.tensorchord.ai/) or [build.envd](https://github.com/mosecorg/mosec/blob/main/build.envd) for more information.\n",
    "bugtrack_url": null,
    "license": "Apache-2.0",
    "summary": "Model Serving made Efficient in the Cloud",
    "version": "0.8.9",
    "project_urls": {
        "Homepage": "https://github.com/mosecorg/mosec",
        "changelog": "https://github.com/mosecorg/mosec/releases",
        "documentation": "https://mosecorg.github.io/mosec/",
        "homepage": "https://mosecorg.github.io/",
        "repository": "https://github.com/mosecorg/mosec"
    },
    "split_keywords": [
        "machine learning",
        " deep learning",
        " model serving"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "0af904db56467f5e26b56d447e865601723f594a77977d8f48ea993f3def66c8",
                "md5": "8171f400dd2c5df9c57f4c7abc82934c",
                "sha256": "944dda9cd0a383846cd10df8949cae4c098c1491f52b48250891bc0f0844d7be"
            },
            "downloads": -1,
            "filename": "mosec-0.8.9-cp310-cp310-macosx_10_9_x86_64.whl",
            "has_sig": false,
            "md5_digest": "8171f400dd2c5df9c57f4c7abc82934c",
            "packagetype": "bdist_wheel",
            "python_version": "cp310",
            "requires_python": ">=3.8",
            "size": 4909723,
            "upload_time": "2024-11-13T15:06:26",
            "upload_time_iso_8601": "2024-11-13T15:06:26.826028Z",
            "url": "https://files.pythonhosted.org/packages/0a/f9/04db56467f5e26b56d447e865601723f594a77977d8f48ea993f3def66c8/mosec-0.8.9-cp310-cp310-macosx_10_9_x86_64.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "b12cd738adf856ac3ea1c99ed979edc75002fd85bbc9539b364b9b5e8f9ed19f",
                "md5": "25dee18270a01ea413e671ab676a6917",
                "sha256": "112c7305cf2d236f844f462b0e8bfb9726fd07e026cf9e66085ddf1f67a286c2"
            },
            "downloads": -1,
            "filename": "mosec-0.8.9-cp310-cp310-macosx_11_0_arm64.whl",
            "has_sig": false,
            "md5_digest": "25dee18270a01ea413e671ab676a6917",
            "packagetype": "bdist_wheel",
            "python_version": "cp310",
            "requires_python": ">=3.8",
            "size": 4947700,
            "upload_time": "2024-11-13T15:06:29",
            "upload_time_iso_8601": "2024-11-13T15:06:29.263278Z",
            "url": "https://files.pythonhosted.org/packages/b1/2c/d738adf856ac3ea1c99ed979edc75002fd85bbc9539b364b9b5e8f9ed19f/mosec-0.8.9-cp310-cp310-macosx_11_0_arm64.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "6518a9216538de2543563e4990109407c0e68529467af1f664c616251a4fab65",
                "md5": "cc78efeaf5dc268aae67dddf4a438356",
                "sha256": "195e1d1847eff5776b14388290861657efdd469152ccfc49e73ddafda405b074"
            },
            "downloads": -1,
            "filename": "mosec-0.8.9-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
            "has_sig": false,
            "md5_digest": "cc78efeaf5dc268aae67dddf4a438356",
            "packagetype": "bdist_wheel",
            "python_version": "cp310",
            "requires_python": ">=3.8",
            "size": 5020779,
            "upload_time": "2024-11-13T15:06:31",
            "upload_time_iso_8601": "2024-11-13T15:06:31.394505Z",
            "url": "https://files.pythonhosted.org/packages/65/18/a9216538de2543563e4990109407c0e68529467af1f664c616251a4fab65/mosec-0.8.9-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "76d44a82ed9356c1de47178be9b2cd6aaf67b58621a428d2cf2d62b0e7ccb962",
                "md5": "41c6c0b2ec7e2ab3dc3f29e5a87c4219",
                "sha256": "a88a6b29e19fa8a75eccb768f74dad82bb20af1e35bdc61cdaebb01db4d5bd7f"
            },
            "downloads": -1,
            "filename": "mosec-0.8.9-cp311-cp311-macosx_10_9_x86_64.whl",
            "has_sig": false,
            "md5_digest": "41c6c0b2ec7e2ab3dc3f29e5a87c4219",
            "packagetype": "bdist_wheel",
            "python_version": "cp311",
            "requires_python": ">=3.8",
            "size": 4909723,
            "upload_time": "2024-11-13T15:06:33",
            "upload_time_iso_8601": "2024-11-13T15:06:33.203887Z",
            "url": "https://files.pythonhosted.org/packages/76/d4/4a82ed9356c1de47178be9b2cd6aaf67b58621a428d2cf2d62b0e7ccb962/mosec-0.8.9-cp311-cp311-macosx_10_9_x86_64.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "9282b9fb47d165bf3272bfecab04f1b3da736657295a66806e101a81627e261a",
                "md5": "ee9a965bcffdee92ce90634ea486d941",
                "sha256": "60fc69c32125d1189b27c16bf534d618228f25a827335c25d4dc29d78871cd8c"
            },
            "downloads": -1,
            "filename": "mosec-0.8.9-cp311-cp311-macosx_11_0_arm64.whl",
            "has_sig": false,
            "md5_digest": "ee9a965bcffdee92ce90634ea486d941",
            "packagetype": "bdist_wheel",
            "python_version": "cp311",
            "requires_python": ">=3.8",
            "size": 4947699,
            "upload_time": "2024-11-13T15:06:34",
            "upload_time_iso_8601": "2024-11-13T15:06:34.927067Z",
            "url": "https://files.pythonhosted.org/packages/92/82/b9fb47d165bf3272bfecab04f1b3da736657295a66806e101a81627e261a/mosec-0.8.9-cp311-cp311-macosx_11_0_arm64.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "ec4799793a2666005e752380fc3ad76a0b19e51de1156b748999c04b2391fada",
                "md5": "22f517e49a3c43081b51a9fa11851826",
                "sha256": "a5257c6b4f647a69e40949d7ea66fbe52452c123490e21cd807467f65238e95d"
            },
            "downloads": -1,
            "filename": "mosec-0.8.9-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
            "has_sig": false,
            "md5_digest": "22f517e49a3c43081b51a9fa11851826",
            "packagetype": "bdist_wheel",
            "python_version": "cp311",
            "requires_python": ">=3.8",
            "size": 5020780,
            "upload_time": "2024-11-13T15:06:37",
            "upload_time_iso_8601": "2024-11-13T15:06:37.133457Z",
            "url": "https://files.pythonhosted.org/packages/ec/47/99793a2666005e752380fc3ad76a0b19e51de1156b748999c04b2391fada/mosec-0.8.9-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "e3bfe10475e9186958fe3ff97eccbdb0d12b82498c0f734aa89e9d7a2475ed96",
                "md5": "9b2839e5fcec5d066fe28d5eae1bc12d",
                "sha256": "84e1b0f770ccca14855f4a490d43d9598afd25adbeef0b17219d9425252ccc6a"
            },
            "downloads": -1,
            "filename": "mosec-0.8.9-cp312-cp312-macosx_10_13_x86_64.whl",
            "has_sig": false,
            "md5_digest": "9b2839e5fcec5d066fe28d5eae1bc12d",
            "packagetype": "bdist_wheel",
            "python_version": "cp312",
            "requires_python": ">=3.8",
            "size": 4909723,
            "upload_time": "2024-11-13T15:06:39",
            "upload_time_iso_8601": "2024-11-13T15:06:39.396363Z",
            "url": "https://files.pythonhosted.org/packages/e3/bf/e10475e9186958fe3ff97eccbdb0d12b82498c0f734aa89e9d7a2475ed96/mosec-0.8.9-cp312-cp312-macosx_10_13_x86_64.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "256e25e510689d300405f0f4cd69a2a217e97eff1a3280caa2c5c74072cb1af9",
                "md5": "f36608bd1df2435fbf4fde7c78c925f2",
                "sha256": "6abd88c1d3b5e213753857169b0fa2c3560069b86a31d38245aeadc456ae29d1"
            },
            "downloads": -1,
            "filename": "mosec-0.8.9-cp312-cp312-macosx_11_0_arm64.whl",
            "has_sig": false,
            "md5_digest": "f36608bd1df2435fbf4fde7c78c925f2",
            "packagetype": "bdist_wheel",
            "python_version": "cp312",
            "requires_python": ">=3.8",
            "size": 4947701,
            "upload_time": "2024-11-13T15:06:41",
            "upload_time_iso_8601": "2024-11-13T15:06:41.674894Z",
            "url": "https://files.pythonhosted.org/packages/25/6e/25e510689d300405f0f4cd69a2a217e97eff1a3280caa2c5c74072cb1af9/mosec-0.8.9-cp312-cp312-macosx_11_0_arm64.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "8e298d949e197759d9e3ff981d26b7e22da8291f135a738956cd5b840c86037e",
                "md5": "95cd579839cb59241f014f8e8547e2fd",
                "sha256": "0937cbeab3e0dea828f9c68e0b56c719bb7b630f68b546c81670fc12a2724721"
            },
            "downloads": -1,
            "filename": "mosec-0.8.9-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
            "has_sig": false,
            "md5_digest": "95cd579839cb59241f014f8e8547e2fd",
            "packagetype": "bdist_wheel",
            "python_version": "cp312",
            "requires_python": ">=3.8",
            "size": 5020780,
            "upload_time": "2024-11-13T15:06:43",
            "upload_time_iso_8601": "2024-11-13T15:06:43.833217Z",
            "url": "https://files.pythonhosted.org/packages/8e/29/8d949e197759d9e3ff981d26b7e22da8291f135a738956cd5b840c86037e/mosec-0.8.9-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "fe58122c9988174b43a7937ddfa1f8e299a49dc7c8d5f05254ae8bf6f12f7ef6",
                "md5": "a2da59b6849ae8369fdcfdc059254ed3",
                "sha256": "35ddfc059e0f249f9bc2377f9bd19a4ae39e3b670ddc96ba18c708cbdee879c3"
            },
            "downloads": -1,
            "filename": "mosec-0.8.9-cp313-cp313-macosx_10_13_x86_64.whl",
            "has_sig": false,
            "md5_digest": "a2da59b6849ae8369fdcfdc059254ed3",
            "packagetype": "bdist_wheel",
            "python_version": "cp313",
            "requires_python": ">=3.8",
            "size": 4909725,
            "upload_time": "2024-11-13T15:06:45",
            "upload_time_iso_8601": "2024-11-13T15:06:45.546682Z",
            "url": "https://files.pythonhosted.org/packages/fe/58/122c9988174b43a7937ddfa1f8e299a49dc7c8d5f05254ae8bf6f12f7ef6/mosec-0.8.9-cp313-cp313-macosx_10_13_x86_64.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "91e27ee40729deefda547c691680b7f4df30ee271c40da802455164ea632897e",
                "md5": "b32b366d8d78b2569314b0462acf3db6",
                "sha256": "6b7ba18732df747db61067d9727fd55624352699527aec2dc438c4336e170dce"
            },
            "downloads": -1,
            "filename": "mosec-0.8.9-cp313-cp313-macosx_11_0_arm64.whl",
            "has_sig": false,
            "md5_digest": "b32b366d8d78b2569314b0462acf3db6",
            "packagetype": "bdist_wheel",
            "python_version": "cp313",
            "requires_python": ">=3.8",
            "size": 4947701,
            "upload_time": "2024-11-13T15:06:47",
            "upload_time_iso_8601": "2024-11-13T15:06:47.083713Z",
            "url": "https://files.pythonhosted.org/packages/91/e2/7ee40729deefda547c691680b7f4df30ee271c40da802455164ea632897e/mosec-0.8.9-cp313-cp313-macosx_11_0_arm64.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "0ac116e466c4c793361f9d15bd40b80e273d7d3e46b0f5db01ac720c3a55c795",
                "md5": "df905013fc7bd78426280266df2650f3",
                "sha256": "4aea8b9117e38ae3b06f6154e61e1c5d8d3b40f4b8896828aa543e29a51c3219"
            },
            "downloads": -1,
            "filename": "mosec-0.8.9-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
            "has_sig": false,
            "md5_digest": "df905013fc7bd78426280266df2650f3",
            "packagetype": "bdist_wheel",
            "python_version": "cp313",
            "requires_python": ">=3.8",
            "size": 5020779,
            "upload_time": "2024-11-13T15:06:49",
            "upload_time_iso_8601": "2024-11-13T15:06:49.200976Z",
            "url": "https://files.pythonhosted.org/packages/0a/c1/16e466c4c793361f9d15bd40b80e273d7d3e46b0f5db01ac720c3a55c795/mosec-0.8.9-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "c3ade3823574cce41f01a84652f147c8444f7fe49b1a8eb526c72e5f4df8ff46",
                "md5": "0b815741c94737abf05d30f4ad84f30f",
                "sha256": "0d5d38ff2f2bdbca0f9cb0d7f0c965db335efa7a3a98298bc8a70462dd258fca"
            },
            "downloads": -1,
            "filename": "mosec-0.8.9-cp38-cp38-macosx_10_9_x86_64.whl",
            "has_sig": false,
            "md5_digest": "0b815741c94737abf05d30f4ad84f30f",
            "packagetype": "bdist_wheel",
            "python_version": "cp38",
            "requires_python": ">=3.8",
            "size": 4909722,
            "upload_time": "2024-11-13T15:06:50",
            "upload_time_iso_8601": "2024-11-13T15:06:50.664844Z",
            "url": "https://files.pythonhosted.org/packages/c3/ad/e3823574cce41f01a84652f147c8444f7fe49b1a8eb526c72e5f4df8ff46/mosec-0.8.9-cp38-cp38-macosx_10_9_x86_64.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "516cf681697bbc5a6e21a1c391366e31a5482fa0ab0dd79b8fe264a7ebfc8662",
                "md5": "58d8c9508dc9a92037b49bda25149cb1",
                "sha256": "2b1996bd04b3313639c1f893ca9cd14ef65280b2296e4e53494eacb4dd289424"
            },
            "downloads": -1,
            "filename": "mosec-0.8.9-cp38-cp38-macosx_11_0_arm64.whl",
            "has_sig": false,
            "md5_digest": "58d8c9508dc9a92037b49bda25149cb1",
            "packagetype": "bdist_wheel",
            "python_version": "cp38",
            "requires_python": ">=3.8",
            "size": 4947701,
            "upload_time": "2024-11-13T15:06:52",
            "upload_time_iso_8601": "2024-11-13T15:06:52.249776Z",
            "url": "https://files.pythonhosted.org/packages/51/6c/f681697bbc5a6e21a1c391366e31a5482fa0ab0dd79b8fe264a7ebfc8662/mosec-0.8.9-cp38-cp38-macosx_11_0_arm64.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "dac78ab10ec2caddd8ceae537811eb0a65a4bd5661af6eaef3b0f2dabc7afd8c",
                "md5": "3cff097a59323834e0e3111cf513fef0",
                "sha256": "ec4bb1f9e7cf855caf9942acb20e738589ddac69c7fa9b4e895892118e57c27b"
            },
            "downloads": -1,
            "filename": "mosec-0.8.9-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
            "has_sig": false,
            "md5_digest": "3cff097a59323834e0e3111cf513fef0",
            "packagetype": "bdist_wheel",
            "python_version": "cp38",
            "requires_python": ">=3.8",
            "size": 5020778,
            "upload_time": "2024-11-13T15:06:54",
            "upload_time_iso_8601": "2024-11-13T15:06:54.404913Z",
            "url": "https://files.pythonhosted.org/packages/da/c7/8ab10ec2caddd8ceae537811eb0a65a4bd5661af6eaef3b0f2dabc7afd8c/mosec-0.8.9-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "e0d285157d68236ad1dcd65e85b2c2190878fc41e6e32d7cebe2089b644faff9",
                "md5": "4adce4064226ab731269bef20056c872",
                "sha256": "0026e083ef17ed17414c0a19de22df3849357d3861441c0d8b92abde4545219e"
            },
            "downloads": -1,
            "filename": "mosec-0.8.9-cp39-cp39-macosx_10_9_x86_64.whl",
            "has_sig": false,
            "md5_digest": "4adce4064226ab731269bef20056c872",
            "packagetype": "bdist_wheel",
            "python_version": "cp39",
            "requires_python": ">=3.8",
            "size": 4909721,
            "upload_time": "2024-11-13T15:06:56",
            "upload_time_iso_8601": "2024-11-13T15:06:56.679681Z",
            "url": "https://files.pythonhosted.org/packages/e0/d2/85157d68236ad1dcd65e85b2c2190878fc41e6e32d7cebe2089b644faff9/mosec-0.8.9-cp39-cp39-macosx_10_9_x86_64.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "b91b89414ddf14ee75b1c143dfe5914e3e858898848efc5f89924fbfbfaa4abe",
                "md5": "deb7f1b899a1999fb7fb46064012b419",
                "sha256": "7996d4c6a9d0e243529f31a7e7762b778b8dcd2224b50fb0c05a8b7cac5a4ec1"
            },
            "downloads": -1,
            "filename": "mosec-0.8.9-cp39-cp39-macosx_11_0_arm64.whl",
            "has_sig": false,
            "md5_digest": "deb7f1b899a1999fb7fb46064012b419",
            "packagetype": "bdist_wheel",
            "python_version": "cp39",
            "requires_python": ">=3.8",
            "size": 4947700,
            "upload_time": "2024-11-13T15:06:58",
            "upload_time_iso_8601": "2024-11-13T15:06:58.230384Z",
            "url": "https://files.pythonhosted.org/packages/b9/1b/89414ddf14ee75b1c143dfe5914e3e858898848efc5f89924fbfbfaa4abe/mosec-0.8.9-cp39-cp39-macosx_11_0_arm64.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "5bc1c48c36a18d67a4da49198284534fdec57f8fcf35698c0a2dad80424ce64a",
                "md5": "ed3c25d3a76e1e963774e39cee0bd2e1",
                "sha256": "52a353bad375abed9245cdb3233c080d5f2f9cd93793a5241034c48226b89e02"
            },
            "downloads": -1,
            "filename": "mosec-0.8.9-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
            "has_sig": false,
            "md5_digest": "ed3c25d3a76e1e963774e39cee0bd2e1",
            "packagetype": "bdist_wheel",
            "python_version": "cp39",
            "requires_python": ">=3.8",
            "size": 5020778,
            "upload_time": "2024-11-13T15:06:59",
            "upload_time_iso_8601": "2024-11-13T15:06:59.800667Z",
            "url": "https://files.pythonhosted.org/packages/5b/c1/c48c36a18d67a4da49198284534fdec57f8fcf35698c0a2dad80424ce64a/mosec-0.8.9-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "8e26650b6f5c5a7c83fdbdcf5ea1b0821a4774dafb2e680f3efd0fc9b87da093",
                "md5": "c6865116a8c6f2f67cfb2160ce62af43",
                "sha256": "90db7b7333e7df0ff40718b4b4d76074df1b4a9468b7b68da52648a24d64fa38"
            },
            "downloads": -1,
            "filename": "mosec-0.8.9.tar.gz",
            "has_sig": false,
            "md5_digest": "c6865116a8c6f2f67cfb2160ce62af43",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 85057,
            "upload_time": "2024-11-13T15:07:05",
            "upload_time_iso_8601": "2024-11-13T15:07:05.479702Z",
            "url": "https://files.pythonhosted.org/packages/8e/26/650b6f5c5a7c83fdbdcf5ea1b0821a4774dafb2e680f3efd0fc9b87da093/mosec-0.8.9.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-11-13 15:07:05",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "mosecorg",
    "github_project": "mosec",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "mosec"
}
        
Elapsed time: 0.66324s