Show HN: Static-allocation MLP inference in ANSI C using a 2-slot ring buffer
MLPico is a header-only implementation of a Multi-Layer Perceptron (MLP) in ANSI C designed for efficient memory and speed. It features a 2-slot circular buffer and supports various platforms, including Arduino. The article provides a detailed example of training an MLP to emulate a double XOR gate using TensorFlow.
- ▪MLPico is a statically-allocatable MLP implementation written in ANSI C.
- ▪It utilizes a 2-slot circular buffer for efficient feedforward prediction.
- ▪The implementation supports int-quantized weights and is compatible with AVR MCUs.
Opening excerpt (first ~120 words) tap to expand
MLPico - ANSI C (Multi-Layer Perceptron) A general-purpose header-only statically-allocatable MLP (Multi-Layer Perceptron) implementation\library written in ANSI C that utilizes a 2-slot circular-buffer with fixed stride indexing, for the process of feedforward\prediction; a technique that provides optimal speed and memory efficiency without compromises across most systems. Features Supports PROGMEM for AVR MCUs. Supports int-quantized weights. Blazingly fast and portable. Supports Arduino, too. Memory-efficienct. Simple in use. Usage See examples, for arduino or native-os\bare-metal.
…
Excerpt limited to ~120 words for fair-use compliance. The full article is at GitHub.