No project description provided
Project description
:thought_balloon:
EZKL
Easy Zero-Knowledge Inference
ezkl
is a library and command-line tool for doing inference for deep learning models and other computational graphs in a zk-snark (ZKML). It enables the following workflow:
- Define a computational graph, for instance a neural network (but really any arbitrary set of operations), as you would normally in pytorch or tensorflow.
- Export the final graph of operations as an .onnx file and some sample inputs to a
.json
file. - Point
ezkl
to the.onnx
and.json
files to generate a ZK-SNARK circuit with which you can prove statements such as:
"I ran this publicly available neural network on some private data and it produced this output"
"I ran my private neural network on some public data and it produced this output"
"I correctly ran this publicly available neural network on some public data and it produced this output"
In the backend we use Halo2 as a proof system.
- If you have any questions, we'd love for you to open up a discussion topic in Discussions. Alternatively, you can join the ✨EZKL Community Telegram Group💫.
resources 📖
docs | the official ezkl docs page |
tutorial | end-to-end tutorial using pytorch and ezkl |
notebook | end-to-end tutorial using pytorch and ezkl in a jupyter notebook |
cargo doc --open |
compile and open the docs in your default browser |
Getting Started ⚙️
building the project 🔨
Note that the library requires a nightly version of the rust toolchain. You can change the default toolchain by running:
rustup override set nightly
After which you may build the library
cargo build --release
A folder ./target/release
will be generated. Add this folder to your PATH environment variable to call ezkl
from the CLI.
# For UNIX like systems
# in .bashrc, .bash_profile, or some other path file
export PATH="<replace with where you cloned the repo>/ezkl/target/release:$PATH"
Restart your shell or reload your shell settings
# example, replace .bash_profile with the file you use to configure your shell
source ~/.bash_profile
You will need a functioning installation of solc
in order to run ezkl
properly.
solc-select is recommended.
Follow the instructions on solc-select to activate solc
in your environment.
Repos
The EZKL project has several libraries and repos.
Repo | Description |
---|---|
@zkonduit/ezkl | the main ezkl repo in rust |
@zkonduit/pyezkl | helper functions in python for processing onnx files |
@zkonduit/ezkl-docs | official ezkl docs |
Contributing 🌎
If you're interested in contributing and are unsure where to start, reach out to one of the maintainers:
- dante (alexander-camuto)
- jason (jasonmorton)
More broadly:
-
See currently open issues for ideas on how to contribute.
-
For PRs we use the conventional commits naming convention.
-
To report bugs or request new features create a new issue within Issues to inform the greater community.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distributions
File details
Details for the file ezkl_lib-0.3.0-cp37-abi3-win_amd64.whl
.
File metadata
- Download URL: ezkl_lib-0.3.0-cp37-abi3-win_amd64.whl
- Upload date:
- Size: 9.9 MB
- Tags: CPython 3.7+, Windows x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/4.0.1 CPython/3.11.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2d357614f1ceb68cd977045850d751867c54973b68f65598c853732a1c06370b |
|
MD5 | 8fe892c2e8a9981ae175dfbbace5c0e7 |
|
BLAKE2b-256 | 96faf9d7dd91127a961c673cf7f3cf283ef967182182552e89f03d46bb9e9b11 |
File details
Details for the file ezkl_lib-0.3.0-cp37-abi3-win32.whl
.
File metadata
- Download URL: ezkl_lib-0.3.0-cp37-abi3-win32.whl
- Upload date:
- Size: 9.0 MB
- Tags: CPython 3.7+, Windows x86
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/4.0.1 CPython/3.11.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e8f33d34378e40b0da2b661bd323ddbe5fc2b76a5301daaf7f3a224ae69a86b5 |
|
MD5 | c25084e585b06e9775742fc323ab40de |
|
BLAKE2b-256 | 970c8ae52aecb84271562860109a43a9ed076331ad806aeeffa7fad6eb34948d |
File details
Details for the file ezkl_lib-0.3.0-cp37-abi3-musllinux_1_2_x86_64.whl
.
File metadata
- Download URL: ezkl_lib-0.3.0-cp37-abi3-musllinux_1_2_x86_64.whl
- Upload date:
- Size: 13.8 MB
- Tags: CPython 3.7+, musllinux: musl 1.2+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/4.0.1 CPython/3.11.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 81039501dbb8e56752539444c0409885b3814ef56871620095d903422799379f |
|
MD5 | e785cad3abe62af130fdea4be0316a19 |
|
BLAKE2b-256 | 82db0a4bf7f68b66a3d37b342b8b0af2bcc98648cf6f5e4421c9092aa1c947fe |
File details
Details for the file ezkl_lib-0.3.0-cp37-abi3-musllinux_1_2_armv7l.whl
.
File metadata
- Download URL: ezkl_lib-0.3.0-cp37-abi3-musllinux_1_2_armv7l.whl
- Upload date:
- Size: 12.8 MB
- Tags: CPython 3.7+, musllinux: musl 1.2+ ARMv7l
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/4.0.1 CPython/3.11.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | acb9495ced45b25851d21b3767578b7098c46360cc2ff0efe3418f0253458b49 |
|
MD5 | 2069816d43bb85e6624a333c74216f93 |
|
BLAKE2b-256 | e1f93c67301d2e165ba3f14c4ebb2196aed41086053a0fdf6c369cceae99f502 |
File details
Details for the file ezkl_lib-0.3.0-cp37-abi3-musllinux_1_2_aarch64.whl
.
File metadata
- Download URL: ezkl_lib-0.3.0-cp37-abi3-musllinux_1_2_aarch64.whl
- Upload date:
- Size: 12.9 MB
- Tags: CPython 3.7+, musllinux: musl 1.2+ ARM64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/4.0.1 CPython/3.11.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 19a1425f2bc979f4b661362560dfd75ded8a22a46f654fc0d72323d5b521ad85 |
|
MD5 | afd5333bad033092ceffd5e2bd849ab6 |
|
BLAKE2b-256 | 7ed38ff3630e12f4fbb353db0db985d7507c9f79b1c6b07709da16145a736800 |
File details
Details for the file ezkl_lib-0.3.0-cp37-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
.
File metadata
- Download URL: ezkl_lib-0.3.0-cp37-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 13.6 MB
- Tags: CPython 3.7+, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/4.0.1 CPython/3.11.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | d9c4255d629e184cab7d29616e7aa335b2084f842d10552a622df61daedd1b16 |
|
MD5 | 0202f4f320ae110b28bbd0053b61be0c |
|
BLAKE2b-256 | c57d71e4bb36d556db1aa87c9db2719c8a00f51a549047071970c22aa208ad3a |
File details
Details for the file ezkl_lib-0.3.0-cp37-abi3-manylinux_2_17_i686.manylinux2014_i686.whl
.
File metadata
- Download URL: ezkl_lib-0.3.0-cp37-abi3-manylinux_2_17_i686.manylinux2014_i686.whl
- Upload date:
- Size: 14.0 MB
- Tags: CPython 3.7+, manylinux: glibc 2.17+ i686
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/4.0.1 CPython/3.11.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9582a6efb70d99d8013897be0acc62c7c41af264bcaaf76c7fef7f48584eb6a8 |
|
MD5 | 1f606527152394ae17a9cc9480f766c6 |
|
BLAKE2b-256 | f69319ea7e40090f7ade429c00bafa710418662e20c5f0e28a59981405cc934d |
File details
Details for the file ezkl_lib-0.3.0-cp37-abi3-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl
.
File metadata
- Download URL: ezkl_lib-0.3.0-cp37-abi3-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl
- Upload date:
- Size: 21.1 MB
- Tags: CPython 3.7+, macOS 10.9+ universal2 (ARM64, x86-64), macOS 10.9+ x86-64, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/4.0.1 CPython/3.11.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | dad319eda6476af0290b3652c645f490106e65db4467a4fb9e81aa6e017ec068 |
|
MD5 | c82dc98e0f842583e6d18242a8206c45 |
|
BLAKE2b-256 | 514791236f214f7fc731287435e2ec8d946c6b3d5e99f5376a9f576673e08c27 |
File details
Details for the file ezkl_lib-0.3.0-cp37-abi3-macosx_10_7_x86_64.whl
.
File metadata
- Download URL: ezkl_lib-0.3.0-cp37-abi3-macosx_10_7_x86_64.whl
- Upload date:
- Size: 11.2 MB
- Tags: CPython 3.7+, macOS 10.7+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/4.0.1 CPython/3.11.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3c1a65ca46a338e97afca5c038c7b5925d4e6e96ecbbba8c5af90bcc38d23df3 |
|
MD5 | 2de210c2d8f24af47fe51f4a96d95dd0 |
|
BLAKE2b-256 | 8d681d68aba7abb8fae775d4573d399d2dad8d106fc37529b9bb589bb9d243b0 |