Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

ML SDK VGF Library

The VGF Library is a library that encodes and decodes VGF files. The VGF format covers the entire model use cases. These use cases can be a combination of SPIR-V™ module binary data, their constants, and compute shaders. The library provides a suite of APIs and tools for working with VGF files. The library includes the following:

  • C++ encoder API
  • C++ decoder API
  • C decoder API
  • VGF dumping tool: vgf_dump
  • VGF updating tool: vgf_updater

The encoder provides a simple, high-level API for building up VGF files. It is designed for easy integration into offline tooling.

The decoder is designed to be lightweight and to be included in high-performing programs, for example game engines. Therefore, the decoder does not allocate any dynamic memory on its own. To maintain full control, you must allocate the memory required and provide it to this library. To minimize copies and peak memory requirements, the format also supports mmap read operations on the contents.

VGF Library also provides a dumping tool which is called vgf_dump. vgf_dump prints the content of a VGF file into human-readable JSON format. You can also use vgf_dump to generate scenario file templates. You can use the scenario file templates with the Scenario Runner tool.

The VGF Updater rewrites an existing VGF file to the latest VGF format version supported by the VGF library. The new version of the VGF file is written to the provided output path.

To see the contents of a VGF file in a visual format, you can use the VGF Adapter for Model Explorer, which lets you view the inputs, outputs, constants and SPIR-V™ graphs.

Cloning the repository

To clone the ML SDK VGF Library as a stand-alone repository, you can use regular git clone commands. However, for better management of dependencies and to ensure everything is placed in the appropriate directories, we recommend using the git-repo tool to clone the repository as part of the ML SDK for Vulkan® suite. Repo tool.

For a minimal build and to initialize only the ML SDK VGF Library and its dependencies, run:

repo init -u https://github.com/arm/ai-ml-sdk-manifest -g vgf-lib

Alternatively, to initialize the repo structure for the entire ML SDK for Vulkan®, including the VGF Library, run:

repo init -u https://github.com/arm/ai-ml-sdk-manifest -g all

After the repo is initialized, fetch the contents with:

repo sync --no-clone-bundle

Cloning on Windows®

To ensure nested submodules do not exceed the maximum long path length, you must enable long paths on Windows®, and you must clone close to the root directory or use a symlink. Make sure to use Git for Windows.

Using PowerShell:

Set-ItemProperty -Path "HKLM:\SYSTEM\CurrentControlSet\Control\FileSystem" -Name "LongPathsEnabled" -Value 1
git config --global core.longpaths true
git --version # Ensure you are using Git for Windows, for example 2.50.1.windows.1
git clone <git-repo-tool-url>
python <path-to-git-repo>\git-repo\repo init -u <manifest-url> -g all
python <path-to-git-repo>\git-repo\repo sync --no-clone-bundle

Using Git Bash:

cmd.exe "/c reg.exe add \"HKLM\System\CurrentControlSet\Control\FileSystem"" /v LongPathsEnabled /t REG_DWORD /d 1 /f"
git config --global core.longpaths true
git --version # Ensure you are using the Git for Windows, for example 2.50.1.windows.1
git clone <git-repo-tool-url>
python <path-to-git-repo>/git-repo/repo init -u <manifest-url> -g all
python <path-to-git-repo>/git-repo/repo sync --no-clone-bundle

After the sync command completes successfully, you can find the ML SDK VGF Library in <repo_root>/sw/vgf-lib/. You can also find all the dependencies required by the ML SDK VGF Library in <repo_root>/dependencies/.

Building VGF Library from source

The build system must have:

  • C/C++ 17 compiler: GCC, or optionally Clang on Linux and MSVC on Windows®.
  • CMake 3.25 or later.
  • Ninja 1.8.2 or later.
  • Python 3.10 or later and uv 0.9.26. Test and tooling dependencies are declared in pyproject.toml and locked in uv.lock.

The following dependencies are also needed:

For the preferred dependency versions see the manifest file.

Building with the script

To make the build configuration options easily discoverable, we provide a python build script. When you run the script from a git-repo manifest checkout, the script uses default paths and does not require any additional arguments. If you do not use the script, you must specify paths to the dependencies.

To build on the current platform, for example on Linux or Windows®, run the following command:

python3 $SDK_PATH/sw/vgf-lib/scripts/build.py -j $(nproc)

To cross compile for AArch64 architecture, add the following option:

python3 $SDK_PATH/sw/vgf-lib/scripts/build.py -j $(nproc) --target-platform aarch64

To enable and run tests, use the --test option. To lint the tests, use the --lint option. To enable tests and documentation building python dependencies must be installed:

uv sync --locked --no-install-project --no-default-groups --group test --group tooling

Run build commands with uv run --no-sync python scripts/build.py to use the locked environment. To build documentation, pass --doc; Doxygen must also be installed on your machine.

You can install the build artifacts for this project into a specified location. To install the build artifacts, pass the --install option with the required path.

To create an archive containing the build artifacts, pass the --package-type option with an archive type such as zip or tgz. Use --package-dir to choose where the archive is written; by default, packages are written to the build directory.

For more command line options, see the help output:

python3 $SDK_PATH/sw/vgf-lib/scripts/build.py --help

Code coverage

Sync the locked test and tooling dependencies, then run the C++ and Python unit tests on Linux with GCC coverage instrumentation:

uv sync --locked --no-install-project --no-default-groups --group test --group tooling
uv run --no-sync python scripts/build.py --coverage --build-dir build-coverage

The command writes a detailed HTML report to build-coverage/coverage/index.html and a machine-readable JSON summary to build-coverage/coverage/summary.json. Coverage is collected for the native library and Python binding sources, including native code exercised through pytest. Python source-line coverage is not collected.

PyPI

The ML SDK VGF Library is available on PyPI as the ai-ml-sdk-vgf-library package.

Install:

pip install ai-ml-sdk-vgf-library

Install from source with pip

From the repository root, install the package with:

pip install .

This command compiles the project’s C/C++ library and Python extension, then installs the resulting Python package. Ensure the prerequisites listed in Building VGF Library from source are installed and the repository dependencies have been initialized.

Sequential wheel builds reuse native libraries and tools in a shared CMake tree under build/pip/<platform>/<build-type>. Python binding objects are kept in separate ABI directories, and Python discovery is refreshed for each build. Linux manylinux builds use their own platform directory instead of reusing host-built artifacts. Changing native build options still rebuilds affected targets through CMake.

License

The ML SDK VGF Library is distributed under the software licenses in LICENSES directory.

Trademark notice

Arm® is a registered trademark of Arm Limited (or its subsidiaries) in the US and/or elsewhere.

Khronos® and Vulkan® are registered trademarks, and SPIR-V™ is a trademark of The Khronos Group Inc..

Metadata

Release files for ai-ml-sdk-vgf-library 0.12.0.dev20261024

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distributions (wheels)

Table of built distributions (wheels) for ai-ml-sdk-vgf-library 0.12.0.dev20261024
File
ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp314-cp314-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl CPython 3.14 CPython 3.14 Linux glibc 2.28+ x86-64, Linux glibc 2.27+ x86-64 Details
ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp314-cp314-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl CPython 3.14 CPython 3.14 Linux glibc 2.26+ ARM64, Linux glibc 2.28+ ARM64 Details
ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp314-cp314-macosx_15_0_arm64.whl CPython 3.14 CPython 3.14 macOS 15.0+ ARM64 Details
ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp313-cp313-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl CPython 3.13 CPython 3.13 Linux glibc 2.28+ x86-64, Linux glibc 2.27+ x86-64 Details
ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp313-cp313-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl CPython 3.13 CPython 3.13 Linux glibc 2.26+ ARM64, Linux glibc 2.28+ ARM64 Details
ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp313-cp313-macosx_15_0_arm64.whl CPython 3.13 CPython 3.13 macOS 15.0+ ARM64 Details
ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp312-cp312-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl CPython 3.12 CPython 3.12 Linux glibc 2.27+ x86-64, Linux glibc 2.28+ x86-64 Details
ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp312-cp312-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl CPython 3.12 CPython 3.12 Linux glibc 2.28+ ARM64, Linux glibc 2.26+ ARM64 Details
ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp312-cp312-macosx_15_0_arm64.whl CPython 3.12 CPython 3.12 macOS 15.0+ ARM64 Details
ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp311-cp311-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl CPython 3.11 CPython 3.11 Linux glibc 2.28+ x86-64, Linux glibc 2.27+ x86-64 Details
ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp311-cp311-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl CPython 3.11 CPython 3.11 Linux glibc 2.26+ ARM64, Linux glibc 2.28+ ARM64 Details
ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp311-cp311-macosx_15_0_arm64.whl CPython 3.11 CPython 3.11 macOS 15.0+ ARM64 Details

Total release size: 9.9 MB

Release files / ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp314-cp314-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl

Download URL ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp314-cp314-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
Size 968.2 kB
Tags CPython 3.14 Linux glibc 2.27+ x86-64 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
7e0272e2a04e67d818e4cf192af04338070bfeecb18df6bd0062fbf06283aac9
BLAKE2b-256 checksum
How to use checksums
c987305325c4f4c3c3df91d6f4ba246b744f1416a3b2981c425bc8893cdd1629
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.15

Release files / ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp314-cp314-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl

Download URL ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp314-cp314-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl
Size 897.5 kB
Tags CPython 3.14 Linux glibc 2.26+ ARM64 Linux glibc 2.28+ ARM64
SHA-256 checksum
How to use checksums
b468bad4038aefc92d173a730991be81efd79f5c8bb1ee80ca35be55d90af4ab
BLAKE2b-256 checksum
How to use checksums
e4701b47c346d4e052d903088e0a393fd66c58dfa661819c911bf797bcf36f60
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.15

Release files / ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp314-cp314-macosx_15_0_arm64.whl

Download URL ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp314-cp314-macosx_15_0_arm64.whl
Size 603.2 kB
Tags CPython 3.14 macOS 15.0+ ARM64
SHA-256 checksum
How to use checksums
67f30a5a4bb4e47fb0e3a9366248092c92d90a549e8f02a0678e0459c24346c8
BLAKE2b-256 checksum
How to use checksums
1d08c8d01393e001c4eeebce0b49c6d3758707ed43e128a5c60572cdcec5538a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.11.14

Release files / ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp313-cp313-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl

Download URL ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp313-cp313-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
Size 967.9 kB
Tags CPython 3.13 Linux glibc 2.27+ x86-64 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
fe68ffd3602305f50da04140229a8b525497964c429efd3fb61f2c4b469689d8
BLAKE2b-256 checksum
How to use checksums
3f2ec6deba1beee709cebca19dbe27cd1bc50ccf685d4e4fccaff9173632a171
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.15

Release files / ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp313-cp313-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl

Download URL ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp313-cp313-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl
Size 896.4 kB
Tags CPython 3.13 Linux glibc 2.26+ ARM64 Linux glibc 2.28+ ARM64
SHA-256 checksum
How to use checksums
cd254466c5f7fbff1017fc454f1417324d03f12024d4000485ccbf093253fe4e
BLAKE2b-256 checksum
How to use checksums
13c1520703fa6f742bd69f598bc8db9f788bba07d698a284b32a4556b0f76551
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.15

Release files / ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp313-cp313-macosx_15_0_arm64.whl

Download URL ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp313-cp313-macosx_15_0_arm64.whl
Size 602.4 kB
Tags CPython 3.13 macOS 15.0+ ARM64
SHA-256 checksum
How to use checksums
6b71b1056ede0b59e7927b5c197ddbf27b2586cfe34a381de231e53e9bf3d28c
BLAKE2b-256 checksum
How to use checksums
b96987c512e488929283df3a21fe77b8948aba793206b65690f87535a216b5ae
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.11.14

Release files / ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp312-cp312-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl

Download URL ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp312-cp312-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
Size 967.9 kB
Tags CPython 3.12 Linux glibc 2.27+ x86-64 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
bdbb7f9acbed8c9e7a20d36bbd0fc360b7c2f4cafc406042bcbcf30e329f8f80
BLAKE2b-256 checksum
How to use checksums
2e1a432cef36c0708ec2d708f7d23e19d378c153d8bd1b5e1578dcb1349c151f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.15

Release files / ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp312-cp312-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl

Download URL ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp312-cp312-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl
Size 896.4 kB
Tags CPython 3.12 Linux glibc 2.26+ ARM64 Linux glibc 2.28+ ARM64
SHA-256 checksum
How to use checksums
42b1070787d8c3bbf15eedf1af38038977d3942c8544dfd660adaaab390f548f
BLAKE2b-256 checksum
How to use checksums
63b5d62a6fb77685b0000bb8933bc11badaefa943ad31a4e6129054dffff0b24
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.15

Release files / ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp312-cp312-macosx_15_0_arm64.whl

Download URL ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp312-cp312-macosx_15_0_arm64.whl
Size 602.4 kB
Tags CPython 3.12 macOS 15.0+ ARM64
SHA-256 checksum
How to use checksums
915d996bf1392e334887dad56adb36621cf2c9b018e48ab878aa86bdc4f6664e
BLAKE2b-256 checksum
How to use checksums
fe40fb00a43ed0dbfb7a98da303a39cebc69b8e52ebfcb3779149f5c9be374a8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.11.14

Release files / ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp311-cp311-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl

Download URL ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp311-cp311-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
Size 966.7 kB
Tags CPython 3.11 Linux glibc 2.27+ x86-64 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
627ebdfa9150d7de2235ded9d495c8dda23d315735c3eca7ffb0a17e43685319
BLAKE2b-256 checksum
How to use checksums
c45bcba840d00c170598feb1e00689185b72f9f64fc1f70ac3dde4bae7f19ec1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.15

Release files / ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp311-cp311-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl

Download URL ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp311-cp311-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl
Size 895.5 kB
Tags CPython 3.11 Linux glibc 2.26+ ARM64 Linux glibc 2.28+ ARM64
SHA-256 checksum
How to use checksums
e3ef7cbb2c02b0c49370d349d33b8111dcc401bd90060b2c8c796c568a09d453
BLAKE2b-256 checksum
How to use checksums
8cd8af6e60b8856973696b400468b2911573dc419ee5406cf15b5e9853627632
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.15

Release files / ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp311-cp311-macosx_15_0_arm64.whl

Download URL ai_ml_sdk_vgf_library-0.12.0.dev20261024-cp311-cp311-macosx_15_0_arm64.whl
Size 602.1 kB
Tags CPython 3.11 macOS 15.0+ ARM64
SHA-256 checksum
How to use checksums
407fba82382e21f58c654464b759538efbb686c5eb4e213c7c310c3bcd39bcd1
BLAKE2b-256 checksum
How to use checksums
07a84c687e6ebcbc50b1969fc3a4cfd48f7b2b39abc91e86c8ed57f9bc2db115
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.11.14

Security for ai-ml-sdk-vgf-library 0.12.0.dev20261024

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.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page