Skip to content

Repository files navigation

EdgeConvert

See the graph. Check the target. Ship the model.

Python PyQt5 Tests License

EdgeConvert is a desktop workspace for inspecting ONNX graphs, checking edge-device constraints, and running real conversion backends for OpenVINO, TensorRT, ncnn, and LiteRT/TFLite.

It is built for the awkward part between “the model exports to ONNX” and “the model actually deploys on the target device.” Instead of hiding missing tools or unsupported constraints, EdgeConvert surfaces them before conversion and only reports success when the expected artifacts exist.

中文简介:EdgeConvert 是一个面向边缘部署的可视化模型工作台,集模型结构查看、设备兼容性预检和真实格式转换于一体。

EdgeConvert deployment workbench

Why EdgeConvert?

  • Inspect complex model graphs with the official Netron viewer, including branches, tensor shapes, operator attributes, and model metadata.
  • Choose a deployment target, not just a file extension: NVIDIA Jetson, Intel CPU/GPU/NPU, Android, or Raspberry Pi.
  • Catch deployment blockers early with checks for precision, dynamic shapes, input signatures, risky operators, and missing backend tools.
  • Run real converters through OpenVINO, trtexec, pnnx, and onnx2tf using safe argument-list process execution.
  • Keep failures honest: missing dependencies, non-zero exits, timeouts, and absent output artifacts remain visible in the conversion log.
  • Work in Chinese or English, with the selected language remembered across sessions.

Quick Start

Requirements: Python 3.10+ and Windows 10/11. The core code is cross-platform, while this early release is primarily validated on Windows.

git clone https://github.com/John-art-king/EdgeConvert.git
cd EdgeConvert
python -m pip install -r requirements.txt
python app.py

Open an ONNX model, inspect it in Netron, then choose Convert & Deploy to select the target device, precision, concrete input shapes, and output directory.

No ONNX model yet? Click Load Demo or open sample_models/demo_graph.json.

Backend Support

Target Backend Output Precision Validation status
Intel CPU / GPU / NPU OpenVINO .xml + .bin FP32, FP16 End-to-end validated with a real YOLOv10s ONNX model
NVIDIA Jetson TensorRT trtexec .engine FP32, FP16* Command contract tested; NVIDIA runtime required
Android / Raspberry Pi pnnx / ncnn .ncnn.param + .ncnn.bin FP32, FP16 Command contract tested; pnnx runtime required
Android onnx2tf / LiteRT .tflite FP32, FP16 Command contract tested; onnx2tf runtime required

* TensorRT 10 accepts trtexec --fp16. TensorRT 11 removed that flag and requires a strongly typed or ModelOpt-converted mixed-precision ONNX model. EdgeConvert detects this mismatch before launching an incompatible command.

Install the backend required by your target:

# OpenVINO
python -m pip install openvino

# ncnn conversion
python -m pip install pnnx

# LiteRT/TFLite conversion
# Follow the onnx2tf installation guide for its platform-specific dependencies.

TensorRT must be installed from NVIDIA and trtexec must be available on PATH.

Device-Aware Preflight

Before conversion, EdgeConvert validates:

  • ONNX source format and non-empty graph
  • input names, ranks, and static dimensions
  • unresolved dynamic dimensions and concrete shape overrides
  • precision support for the selected target
  • known unsupported or high-risk operators
  • backend availability and expected output artifacts

Concrete shapes use a compact format:

images=1x3x640x640; scale=1x2

The compatibility report is a preflight check, not a promise of semantic equivalence. The target runtime remains the final authority.

Project Structure

app.py                   Main PyQt5 workspace
deployment_ui.py         Device configuration and conversion dialog
conversion_core.py       Device profiles and compatibility rules
conversion_backends.py   OpenVINO, TensorRT, ncnn, and TFLite adapters
model_core.py            ONNX/Graph JSON parsing and export primitives
netron_view.py           Managed local Netron service
tests/                   Unit and UI regression tests

Development

$env:QT_QPA_PLATFORM = "offscreen"
python -m pytest -q
python -m py_compile app.py conversion_backends.py conversion_core.py deployment_ui.py model_core.py netron_view.py

Current verification: 35 tests passed. OpenVINO FP16 conversion was also exercised end to end with a real YOLOv10s ONNX model, producing both IR artifacts.

Roadmap

  • Post-conversion inference smoke tests
  • ONNX-to-target numerical output comparison
  • Classification, detection, and segmentation example models
  • Windows packaged release and Linux AppImage
  • Device-specific performance and memory reports
  • Extensible user-defined device profiles

Contributing

Issues and pull requests are welcome. See CONTRIBUTING.md for the local workflow and the expectations for new conversion backends.

License

Released under the MIT License.

About

Visualize ONNX graphs, validate edge-device compatibility, and convert models to OpenVINO, TensorRT, ncnn, and LiteRT/TFLite from one desktop app.

Topics

Resources

Contributing

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages