Skip to main content

Model Explorer Adapter

The Model Explorer Adapter provides graph extraction and visualization conversion for ML models (TensorFlow SavedModel, GraphDef, FlatBuffer/TFLite, StableHLO/MLIR) to Model Explorer's visualization JSON format.

It is implemented as a stable C-ABI library (libai_edge_model_explorer_adapter.so / .dylib) with a pure Python ctypes FFI wrapper for universal ABI stability across Python versions without pybind11 compile-time matrix bloat.

Install from PyPI

Install ai-edge-model-explorer-adapter via pip from PyPI. For example, in a Python virtual environment:

% python3 -m venv ~/tmp/venv
% source ~/tmp/venv/bin/activate
(venv) $ pip install ai-edge-model-explorer-adapter

Use the Package

After installation, the package can be imported directly:

import ai_edge_model_explorer_adapter as adapter

config = adapter.VisualizeConfig()
json_str = adapter.ConvertFlatbufferDirectlyToJson(config, "model.tflite")
print(json_str)

Build and Install Locally

Declarative Bazel Build

Build the Python wheel directly using Bazel:

bazel build -c opt //python/ai_edge_model_explorer_adapter:wheel

The resulting wheel is located under bazel-bin/: bazel-bin/python/ai_edge_model_explorer_adapter/

Install

Install the resulting wheel via pip:

(venv) $ pip install \
  bazel-bin/python/ai_edge_model_explorer_adapter/*.whl

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

ai_edge_model_explorer_adapter-0.2.0-py3-none-manylinux_2_27_x86_64.whl (131.6 MB view details)

Uploaded Python 3manylinux: glibc 2.27+ x86-64

ai_edge_model_explorer_adapter-0.2.0-py3-none-manylinux_2_27_aarch64.whl (105.8 MB view details)

Uploaded Python 3manylinux: glibc 2.27+ ARM64

ai_edge_model_explorer_adapter-0.2.0-py3-none-macosx_12_0_arm64.whl (103.0 MB view details)

Uploaded Python 3macOS 12.0+ ARM64

File details

Details for the file ai_edge_model_explorer_adapter-0.2.0-py3-none-manylinux_2_27_x86_64.whl.

File metadata

File hashes

Hashes for ai_edge_model_explorer_adapter-0.2.0-py3-none-manylinux_2_27_x86_64.whl
Algorithm Hash digest
SHA256 a09ef992bc6de85ba6451dc7fda46d06de339f451561c57e378bd50c478e28cb
MD5 681de9adab8d32ed270e6652f1a00358
BLAKE2b-256 0fc2bb3ed7dde8e31dface3a2310c7444b9326a900480a10eb0f56beb410c475

See more details on using hashes here.

File details

Details for the file ai_edge_model_explorer_adapter-0.2.0-py3-none-manylinux_2_27_aarch64.whl.

File metadata

File hashes

Hashes for ai_edge_model_explorer_adapter-0.2.0-py3-none-manylinux_2_27_aarch64.whl
Algorithm Hash digest
SHA256 a602424f31cea2646a12296e49b04591edce5ac0936a77046d942207b2c42a91
MD5 aa53cd231d9d5203cff4dd5ca28ed716
BLAKE2b-256 caf394b32c5058512e25604ee1f18c79553613d2f1ba6d052e126d896f7c13e9

See more details on using hashes here.

File details

Details for the file ai_edge_model_explorer_adapter-0.2.0-py3-none-macosx_12_0_arm64.whl.

File metadata

File hashes

Hashes for ai_edge_model_explorer_adapter-0.2.0-py3-none-macosx_12_0_arm64.whl
Algorithm Hash digest
SHA256 8a95a9e24b610189c7258b036634dfc9dc3e768ed622ff750f19459961d26ecd
MD5 3cf0f863996c31b9979f1bdfbcbc5d75
BLAKE2b-256 ec319227bae801dc3e6f740778ff4ac28b862c5dee67b2949371ac3e6887788d

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.2.0 This release

3 files

0.1.14

15 files

0.1.13

15 files

0.1.12

15 files

0.1.11

12 files

0.1.10

12 files

0.1.9

12 files

0.1.8

12 files

0.1.5

12 files

0.1.3

12 files

0.1.2

12 files

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page