Optimized machine learning models for edge and mobile devices. Showcasing efficient model deployment, optimization techniques, and real-world edge AI applications.
Features β’ Installation β’ Quick Start β’ Documentation β’ Contributing
- Features
- Project Structure
- Prerequisites
- Installation
- Quick Start
- Documentation
- Contributing
- Versioning
- Authors
- Citation
- License
- Acknowledgments
- Model quantization and optimization
- Mobile-first architectures
- Battery-efficient inference
- Cross-platform deployment
- Edge-optimized pipelines
graph TD
A[edge-ai-engineering] --> B[models]
A --> C[optimization]
A --> D[deployment]
A --> E[benchmarks]
B --> F[tflite]
B --> G[pytorch-mobile]
C --> H[quantization]
C --> I[compression]
D --> J[android]
D --> K[ios]
E --> L[performance]
E --> M[battery]
Click to expand full directory structure
edge-ai-engineering/
βββ models/ # Model implementations
β βββ tflite/ # TensorFlow Lite models
β βββ pytorch/ # PyTorch Mobile models
βββ optimization/ # Optimization tools
β βββ quantization/ # Model quantization
β βββ compression/ # Model compression
βββ deployment/ # Platform-specific deployment
β βββ android/ # Android deployment
β βββ ios/ # iOS deployment
βββ benchmarks/ # Performance testing
βββ README.md # Documentation
- Python 3.8+
- TensorFlow Lite 2.14+
- PyTorch Mobile 2.2+
- Android SDK/NDK
- Xcode (for iOS)
# Clone repository
git clone https://github.com/BjornMelin/edge-ai-engineering.git
cd edge-ai-engineering
# Create environment
python -m venv venv
source venv/bin/activate
# Install dependencies
pip install -r requirements.txt
from edge_ai import optimization, deployment
# Optimize model for mobile
optimized_model = optimization.quantize_for_mobile(
model,
target_platform="android",
quantization="int8"
)
# Deploy to device
deployment = deployment.MobileDeployment(
model=optimized_model,
platform="android",
optimize_battery=True
)
# Generate deployment package
deployment.export()
Model | Task | Size | Latency (ms) |
---|---|---|---|
MobileNetV3 | Classification | 4MB | 15 |
TinyYOLO | Detection | 8MB | 25 |
MobileViT | Vision | 6MB | 20 |
- Int8 quantization
- Model pruning
- Architecture optimization
- Memory footprint reduction
Performance on different devices:
Device | Model | Battery Impact | FPS | Memory |
---|---|---|---|---|
Pixel 6 | MobileNet | 2%/hr | 30 | 120MB |
iPhone 13 | TinyYOLO | 3%/hr | 25 | 150MB |
RPi 4 | MobileViT | N/A | 15 | 200MB |
We use SemVer for versioning. For available versions, see the tags on this repository.
Bjorn Melin
- GitHub: @BjornMelin
- LinkedIn: Bjorn Melin
@misc{melin2024edgeaiengineering,
author = {Melin, Bjorn},
title = {Edge AI Engineering: Optimized Mobile Machine Learning},
year = {2024},
publisher = {GitHub},
url = {https://github.com/BjornMelin/edge-ai-engineering}
}
This project is licensed under the MIT License - see the LICENSE file for details.
- TensorFlow Lite team
- PyTorch Mobile developers
- Mobile ML community
- Edge computing researchers
Made with π± and β€οΈ by Bjorn Melin