How espressif/esp-dl works
ESP-DL is an embedded neural-network inference framework for Espressif chips. Its main workflow is to obtain a quantized model in the ESP-DL FlatBuffers format, load it, plan tensor memory, and execute model operators to produce results. The repository also provides image, vision, audio, and recognition capabilities, plus a zoo of ready-to-integrate models. Relationships below are limited to README statements and source-index references; several domain implementations are represented by their listed directories because their source was not sampled.
Main entry points: dl_module_base.hpp Operator Modules · dl_model_base.hpp Model Execution · fbs_model.hpp ESP-DL Model · speaker_verification.cpp Speaker Verification
Components 19
Model Runtime
- FlatBuffers Loader
esp-dl/fbs_loader/src/fbs_loader.cpp - Model Execution
esp-dl/dl/model/include/dl_model_base.hpp - Memory Planner
esp-dl/dl/model/src/dl_memory_manager_greedy.cpp - Model Context
esp-dl/dl/model/include/dl_model_context.hpp - Tensor Data
esp-dl/dl/tensor/include/dl_tensor_base.hpp
Operator Compute
- Operator Modules
esp-dl/dl/module/include/dl_module_base.hpp - Operator Kernels
esp-dl/dl/base/dl_base.hpp - Chip Kernels
esp-dl/dl/base/isa/dl_base_isa.hpp
Media Processing
- Image Processing
esp-dl/vision/image - Speech Features
esp-dl/audio/speech_features/dl_fbank.hpp
AI Tasks
- Vision Tasks
esp-dl/vision - Feature Recognition
esp-dl/vision/recognition - Speaker Verification
models/speaker_verification/speaker_verification.cpp - Feature Verification DB
models/feat_database/dl_feat_verification_database.cpp
Models And Tools
- ESP-DL Model
esp-dl/fbs_loader/include/fbs_model.hpp - Model Zoo
models - Quantization Helpers
tools/agents/skills/espdl-quantize/scripts/run_iteration.py
Other components
- Application Developer
- ESP-PPQ
Connections 21
- Application Developer → ESP-PPQ: quantizes model
README.md - ESP-PPQ → ESP-DL Model: exports model
README.md - Application Developer → FlatBuffers Loader: loads model
README.md - FlatBuffers Loader → ESP-DL Model: reads model
esp-dl/fbs_loader/src/fbs_loader.cpp - Application Developer → Model Execution: runs model
README.md - Model Execution → Operator Modules: dispatches operators
- Operator Modules → Model Context: uses context
esp-dl/dl/module/include/dl_module_base.hpp - Operator Modules → Tensor Data: uses tensors
esp-dl/dl/module/include/dl_module_base.hpp - Operator Modules → Operator Kernels: uses kernels
esp-dl/dl/module/include/dl_module_base.hpp - Operator Modules → ESP-DL Model: deserializes nodes
esp-dl/dl/module/include/dl_module_base.hpp - Operator Kernels → Chip Kernels: selects kernels
esp-dl/dl/base/isa/dl_base_isa.hpp - Memory Planner → ESP-DL Model: reads model metadata
- Memory Planner → Model Context: plans allocations
- Model Context → Tensor Data: holds tensors
esp-dl/dl/model/include/dl_model_context.hpp - Image Processing → Vision Tasks: prepares images
- Speech Features → Speaker Verification: extracts features
- Speaker Verification → Model Execution: runs model
- Speaker Verification → Speech Features: uses features
- Feature Verification DB → Model Execution: verifies embeddings
- Application Developer → Model Zoo: integrates models
README.md - Quantization Helpers → ESP-PPQ: assists tuning