Python library for converting PyTorch models to TFLite format
Top 48.5% on sourcepulse
AI Edge Torch is a Python library designed to convert PyTorch models into the TFLite format, enabling on-device execution for Android, iOS, and IoT applications. It targets developers building mobile and edge AI solutions, offering broad CPU support with initial GPU and NPU capabilities, and a specialized Generative API for LLMs.
How It Works
The library leverages torch.export()
to convert PyTorch models, aiming for broad coverage of Core ATen operators. This approach integrates closely with the PyTorch ecosystem. For LLMs, the Generative API facilitates model authoring and quantization for optimized on-device performance, with conversion to TFLite for execution via the TensorFlow Lite runtime or direct integration with the MediaPipe LLM Inference API.
Quick Start & Requirements
pip install ai-edge-torch
or pip install ai-edge-torch-nightly
Highlighted Details
Maintenance & Community
Licensing & Compatibility
Limitations & Caveats
The PyTorch converter is in Beta, and the Generative API is in Alpha. The Generative API is currently CPU-only, with GPU and NPU support planned.
1 day ago
1 day