p2o
A PaddlePaddle New IR (PIR) to ONNX model converter, written in Rust.
Converts PaddlePaddle inference models (inference.json + inference.pdiparams) to the ONNX format.
Installation
Pre-built binaries
Download from GitHub Releases.
From PyPI
pip install p2o
From crates.io
cargo install p2o
Build from source
git clone https://github.com/greatv/p2o.git
cd p2o
cargo build --release
Usage
p2o <model.json> <model.pdiparams> <output.onnx> [--opset 17] [--strict]
Arguments
| Argument | Description |
|---|---|
model.json |
Path to the PaddlePaddle .json model file |
model.pdiparams |
Path to the PaddlePaddle .pdiparams weight file |
output.onnx |
Path to the output .onnx model file |
--opset <N> |
Target ONNX opset version (≥ 10, default: 17) |
--strict |
Reject lossy conversions (e.g. multinomial → ArgMax) |
Example
p2o inference_models/PP-OCRv5_server_det_infer/inference.json \
inference_models/PP-OCRv5_server_det_infer/inference.pdiparams \
output.onnx --opset 17
Metadata
Release files for p2o 0.1.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| p2o-0.1.2.tar.gz | 128.9 kB | Details |
Built distributions (wheels)
| File | Reset | |||
|---|---|---|---|---|
| p2o-0.1.2-py3-none-win_amd64.whl | Python 3 | none | Windows x86-64 | Details |
| p2o-0.1.2-py3-none-musllinux_1_2_x86_64.whl | Python 3 | none | Linux musl 1.2+ x86-64 | Details |
| p2o-0.1.2-py3-none-musllinux_1_2_aarch64.whl | Python 3 | none | Linux musl 1.2+ ARM64 | Details |
| p2o-0.1.2-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl | Python 3 | none | Linux glibc 2.17+ x86-64 | Details |
| p2o-0.1.2-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl | Python 3 | none | Linux glibc 2.17+ ARM64 | Details |
| p2o-0.1.2-py3-none-macosx_11_0_arm64.whl | Python 3 | none | macOS 11.0+ ARM64 | Details |
Total release size: 8.3 MB
Release files / p2o-0.1.2.tar.gz
| Download URL | p2o-0.1.2.tar.gz |
|---|---|
| Size | 128.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
64e900e4b739f194211b938dafb97faba65c78aed0aea27456ab5aa112268f29
|
|
BLAKE2b-256 checksum How to use checksums |
601b44f9ea2d7593cb5ffad42acdb7715b15d0d60f10302e9b7a4a9bee8b58fe
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
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 Jun 23, 2026.
Transparency logRelease files / p2o-0.1.2-py3-none-win_amd64.whl
| Download URL | p2o-0.1.2-py3-none-win_amd64.whl |
|---|---|
| Size | 1.2 MB |
| Tags | Python 3 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
aeaae35cffa2eedd5e5a7bdea809a61310392495b156d423ac480899d21ddd8a
|
|
BLAKE2b-256 checksum How to use checksums |
0aca31506603d15bf365185ddfa115a7c6b8fbdde5237eb53608de1f605d61b7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
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 Jun 23, 2026.
Transparency logRelease files / p2o-0.1.2-py3-none-musllinux_1_2_x86_64.whl
| Download URL | p2o-0.1.2-py3-none-musllinux_1_2_x86_64.whl |
|---|---|
| Size | 1.5 MB |
| Tags | Linux musl 1.2+ x86-64 Python 3 |
|
SHA-256 checksum How to use checksums |
3b25f2b0775e6628af8375e1058a7f9161d1f2b609fe11a8dc813be443ecfefe
|
|
BLAKE2b-256 checksum How to use checksums |
7c764308139b62fc2c894165e0d50d7c653929491a22bcf8c42f3a39f77627e9
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
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 Jun 23, 2026.
Transparency logRelease files / p2o-0.1.2-py3-none-musllinux_1_2_aarch64.whl
| Download URL | p2o-0.1.2-py3-none-musllinux_1_2_aarch64.whl |
|---|---|
| Size | 1.4 MB |
| Tags | Linux musl 1.2+ ARM64 Python 3 |
|
SHA-256 checksum How to use checksums |
b3424f02d6e7c7f92146cfe140d890c1ed123603ab96259ef37e55494343aee3
|
|
BLAKE2b-256 checksum How to use checksums |
9117c90bec5a25f18e3a358511a9c519790d0e515288a55f36498a65ce570fa4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
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 Jun 23, 2026.
Transparency logRelease files / p2o-0.1.2-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
| Download URL | p2o-0.1.2-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl |
|---|---|
| Size | 1.4 MB |
| Tags | Linux glibc 2.17+ x86-64 Python 3 |
|
SHA-256 checksum How to use checksums |
6b8aef24c87a1615d4a16cdbc79dfd8ac416c75a9ea1c2d82d6b14b9d8d3c845
|
|
BLAKE2b-256 checksum How to use checksums |
e1c8c96322608a43f5bac882ee2f6c0df997b45725c8934de15d21d4d4595ec8
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
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 Jun 23, 2026.
Transparency logRelease files / p2o-0.1.2-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
| Download URL | p2o-0.1.2-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl |
|---|---|
| Size | 1.4 MB |
| Tags | Linux glibc 2.17+ ARM64 Python 3 |
|
SHA-256 checksum How to use checksums |
2e26b4f6a4588a41e199c71af8ffa4f6b4365c5ed7d2c4f88b49c029561805e6
|
|
BLAKE2b-256 checksum How to use checksums |
55d21dabfaf4054122e9ec1cc8db4429da945bb22c81c3fc9d17932411f908a5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
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 Jun 23, 2026.
Transparency logRelease files / p2o-0.1.2-py3-none-macosx_11_0_arm64.whl
| Download URL | p2o-0.1.2-py3-none-macosx_11_0_arm64.whl |
|---|---|
| Size | 1.3 MB |
| Tags | Python 3 macOS 11.0+ ARM64 |
|
SHA-256 checksum How to use checksums |
e178b3482defcfb245c9a06d460e5de7c349dfdc1edeb4176c113cee2f0ea8fc
|
|
BLAKE2b-256 checksum How to use checksums |
954f94acd27d6265d3b94db19aa314e1126f0709c0189f3b04ab58bb3a27c746
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
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 Jun 23, 2026.
Transparency log