VapourSynth-MLRT-ORT
This package contains the ONNX Runtime backend implementation of the vs-mlrt plugin.
Installation
To install the standard CPU/DirectML/CoreML package:
pip install vapoursynth-mlrt-ort
To install the CUDA-enabled package:
pip install "vapoursynth-mlrt-ort[cuda]"
Building from source
Requirements
- C++ Compiler: C++20 compatible (e.g. MSVC 2019+, GCC, Clang)
- Build Tools: uv, CMake, Ninja
- Dependencies (must be built/installed before the plugin):
onnxruntime(ONNX Runtime SDK — built from source in CI)ONNX(built from source, version matched to ONNX Runtime's pinned submodule)
- Backend-specific Dependencies:
- DirectML (Windows only): DirectML SDK. Set
DML_DIRto the SDK directory. - CUDA (Windows/Linux):
CUDAToolkitandcuDNN. EnsureCUDA_PATHandCUDNN_PATH/CUDNN_HOMEare set. - CoreML (macOS only): Enabled automatically, no extra setup needed.
- DirectML (Windows only): DirectML SDK. Set
Compilation
-
Initialize the submodule:
git submodule update --init --recursive vsmlrt/ort/vs-mlrt
-
Build ONNX Runtime from source (or install a pre-built SDK), then build ONNX from source using the version pinned by ONNX Runtime (
onnxruntime/cmake/external/onnx/). Both must be discoverable by CMake (viaCMAKE_PREFIX_PATHor installed system-wide). -
Set environment variables for backend-specific SDKs:
# Windows DirectML $env:DML_DIR = "C:\Path\To\DirectML"
-
Build the wheel:
uv build --package vapoursynth-mlrt-ort
To disable bundling CUDA provider libraries into the main wheel (CI does this, shipping them in a separate
vapoursynth-mlrt-ort-cudapackage instead):uv build --package vapoursynth-mlrt-ort -C "cmake.define.INSTALL_CUDA=OFF"
Detailed parameter information from the parent project follows.
VapourSynth ONNX Runtime
The vs-onnxruntime plugin provides optimized CPU & CUDA runtime for some popular AI filters.
Usage
Prototype: core.ort.Model(clip[] clips, string network_path[, int[] overlap = None, int[] tilesize = None, string provider = "", int device_id = 0, int verbosity = 2, bint cudnn_benchmark = False, bint fp16 = False, bint path_is_serialization = False, bint use_cuda_graph = False])
Arguments:
clip[] clips: the input clips, only 32-bit floating point RGB or GRAY clips are supported. For model specific input requirements, please consult our wiki.string network_path: the path to the network in ONNX format.int[] overlap: some networks (e.g. CNN) support arbitrary input shape where other networks might only support fixed input shape and the input clip must be processed in tiles. Theoverlapargument specifies the overlapping (horizontal and vertical, or both, in pixels) between adjacent tiles to minimize boundary issues. Please refer to network specific docs on the recommended overlapping size.int[] tilesize: Even for CNN where arbitrary input sizes could be supported, sometimes the network does not work well for the entire range of input dimensions, and you have to limit the size of each tile. This parameter specify the tile size (horizontal and vertical, or both, including the overlapping). Please refer to network specific docs on the recommended tile size.string provider: Specifies the device to run the inference on."CPU"or"": pure CPU backend"CUDA": CUDA GPU backend, requires Nvidia Maxwell+ GPUs."DML": DirectML backend"COREML": CoreML backend
int device_id: select the GPU device for the CUDA backend.'int verbosity: specify the verbosity of logging, the default is warning.- 0: fatal error only,
ORT_LOGGING_LEVEL_FATAL - 1: also errors,
ORT_LOGGING_LEVEL_ERROR - 2: also warnings,
ORT_LOGGING_LEVEL_WARNING - 3: also info,
ORT_LOGGING_LEVEL_INFO - 4: everything,
ORT_LOGGING_LEVEL_VERBOSE
- 0: fatal error only,
bint cudnn_benchmark: whether to let cuDNN use benchmarking to search for the best convolution kernel to use. Default False. It might incur some startup latency.bint fp16: whether to quantize model to fp16 for faster and memory efficient computation.bint path_is_serialization: whether thenetwork_pathargument specifies an onnx serialization of typebytes.bint use_cuda_graph: whether to use CUDA Graphs to improve performance and reduce CPU overhead in CUDA backend. Not all models are supported.int ml_program: select CoreML provider.- 0: NeuralNetwork
- 1: MLProgram
When overlap and tilesize are not specified, the filter will internally try to resize the network to fit the input clips. This might not always work (for example, the network might require the width to be divisible by 8), and the filter will error out in this case.
The general rule is to either:
- left out
overlap,tilesizeat all and just process the input frame in one tile, or - set all three so that the frame is processed in
tilesize[0]xtilesize[1]tiles, and adjacent tiles will have an overlap ofoverlap[0]xoverlap[1]pixels on each direction. The overlapped region will be throw out so that only internal output pixels are used.
Metadata
Release files for vapoursynth-mlrt-ort 17.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| vapoursynth_mlrt_ort-17.0.tar.gz | 104.7 kB | Details |
Built distributions (wheels)
| File | Reset | |||
|---|---|---|---|---|
| vapoursynth_mlrt_ort-17.0-py3-none-win_amd64.whl | Python 3 | none | Windows x86-64 | Details |
| vapoursynth_mlrt_ort-17.0-py3-none-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl | Python 3 | none | Linux glibc 2.28+ x86-64, Linux glibc 2.27+ x86-64 | Details |
| vapoursynth_mlrt_ort-17.0-py3-none-manylinux_2_27_aarch64.manylinux_2_28_aarch64.whl | Python 3 | none | Linux glibc 2.27+ ARM64, Linux glibc 2.28+ ARM64 | Details |
| vapoursynth_mlrt_ort-17.0-py3-none-macosx_15_0_x86_64.whl | Python 3 | none | macOS 15.0+ x86-64 | Details |
| vapoursynth_mlrt_ort-17.0-py3-none-macosx_15_0_arm64.whl | Python 3 | none | macOS 15.0+ ARM64 | Details |
Total release size: 55.2 MB
Release files / vapoursynth_mlrt_ort-17.0.tar.gz
| Download URL | vapoursynth_mlrt_ort-17.0.tar.gz |
|---|---|
| Size | 104.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
7960bb9e22acddf82b60d8ce9ee0c23c496cb17a0a5521aba3f5d581d067583e
|
|
BLAKE2b-256 checksum How to use checksums |
6575f71b33deb0c384743665896b139eeb99864794915327b8d0e83ff73c61be
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 14, 2026.
Transparency logRelease files / vapoursynth_mlrt_ort-17.0-py3-none-win_amd64.whl
| Download URL | vapoursynth_mlrt_ort-17.0-py3-none-win_amd64.whl |
|---|---|
| Size | 16.1 MB |
| Tags | Python 3 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
d158aa6975e7e9b4c3a2320cbdec57a7ec6a5c18be58ee490e39e0f1c3212b2b
|
|
BLAKE2b-256 checksum How to use checksums |
e4cdabef4dc993894e4fcb96dea4fd004427981cfd62755674ef6148f4b1e5f7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 14, 2026.
Transparency logRelease files / vapoursynth_mlrt_ort-17.0-py3-none-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
| Download URL | vapoursynth_mlrt_ort-17.0-py3-none-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl |
|---|---|
| Size | 10.3 MB |
| Tags | Linux glibc 2.27+ x86-64 Linux glibc 2.28+ x86-64 Python 3 |
|
SHA-256 checksum How to use checksums |
887d7333842b77c6d6ff3eec714c21afa8bff2804706447d2cbc65ac4df0ddb3
|
|
BLAKE2b-256 checksum How to use checksums |
6f838464bf2f593ef02658612753b8bd35576641970d65cc2fcf1d5845d03a94
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 14, 2026.
Transparency logRelease files / vapoursynth_mlrt_ort-17.0-py3-none-manylinux_2_27_aarch64.manylinux_2_28_aarch64.whl
| Download URL | vapoursynth_mlrt_ort-17.0-py3-none-manylinux_2_27_aarch64.manylinux_2_28_aarch64.whl |
|---|---|
| Size | 9.0 MB |
| Tags | Linux glibc 2.27+ ARM64 Linux glibc 2.28+ ARM64 Python 3 |
|
SHA-256 checksum How to use checksums |
b0bd17812650fa3d6b882be9e9b3e02a56fc6e3efbcb86a30555aa297a62fd63
|
|
BLAKE2b-256 checksum How to use checksums |
000e64ba46ffd833c93ae2d685534239c6a18ef7ddc2a63b76815d2753aecae1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 14, 2026.
Transparency logRelease files / vapoursynth_mlrt_ort-17.0-py3-none-macosx_15_0_x86_64.whl
| Download URL | vapoursynth_mlrt_ort-17.0-py3-none-macosx_15_0_x86_64.whl |
|---|---|
| Size | 10.8 MB |
| Tags | Python 3 macOS 15.0+ x86-64 |
|
SHA-256 checksum How to use checksums |
e99f5f768b1e7d78c85d681ba68832f5fe28d6012db3db9019335771e387d5af
|
|
BLAKE2b-256 checksum How to use checksums |
c67637d5606b2f8b15cdecf59578c659edc2bf325867ab571ab58d01c6ef33fa
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 14, 2026.
Transparency logRelease files / vapoursynth_mlrt_ort-17.0-py3-none-macosx_15_0_arm64.whl
| Download URL | vapoursynth_mlrt_ort-17.0-py3-none-macosx_15_0_arm64.whl |
|---|---|
| Size | 8.9 MB |
| Tags | Python 3 macOS 15.0+ ARM64 |
|
SHA-256 checksum How to use checksums |
f5df3cfea21a514acf9c78e837d866ac5e218d5bffc3ba3e6762bf5cebf046d3
|
|
BLAKE2b-256 checksum How to use checksums |
dc15b0f78557c7acbe53c94a1d64ab1a5cb76d2ecba4afcb64a147a5706f2ebb
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 14, 2026.
Transparency log