Abstract
Accurate optical flow relies on iterative refinement, yet the edge accelerators that small robots and other devices on batteries carry execute only static integer graphs and often leave just 4 bits per weight. Under this constraint, iterative networks lose much of their accuracy, and the networks designed for these chips are far less accurate to begin with.
We trace this loss to a single layer, the linear output of the update block. Refinement needs steps whose sizes differ by more than a factor of one hundred, but a linear output represents them like a fixed point number. The rounding error of its weights therefore adds the same error to every update, however small, and this error accumulates over the iterations.
We introduce SEM, an output layer that instead predicts each flow update as a floating point number with a Sign, an Exponent and a Mantissa. A rounding error then perturbs each update only in proportion to its size, while every output remains bounded and easy to quantize. Replacing only the output layer of existing networks such as RAFT-small and RAPIDFlow preserves their floating point accuracy and removes up to 86% of the error that 4-bit weights add. Built around SEM, NibbleFlow has only 0.51M parameters and runs on a Hailo-8 with most of its weights in 4 bits. It loses less than one pixel of EPE to its floating point version and cuts the Sintel error of the best deployable baseline by up to 45%, with 5.4× fewer parameters.
Motivation
Optical flow underpins visual odometry, structure from motion, tracking and navigation, and its accuracy today is driven by iterative refinement, in which an update block repeatedly corrects the current estimate. These methods run in floating point on desktop GPUs, whereas small robots and other battery-powered devices rely on edge AI accelerators such as the Hailo-8 and the Coral Edge TPU, which deliver several TOPS within a few watts.
This efficiency comes at a price, since these accelerators execute only a static graph with integer weights and keep all weights in the memory on the chip, which often leaves only 4 bits per weight. Under such quantization, iterative flow networks lose much of their accuracy, while the networks that were designed for these chips are far less accurate to begin with. As a result, accurate optical flow has remained out of reach on the very hardware that needs it.
The problem lives in one layer
Refinement asks one output layer for steps of very different sizes. The first iterations must cover most of the motion, while the last ones only polish it. At the first step of our coarsest level alone, the needed steps span seven octaves, from to pixels.
A standard linear output head represents a step the way a fixed point number represents a value. Its error is absolute, so this error decides the smallest step the head can take accurately, while the largest value of the last layer decides the largest one. The window of accurate steps therefore has a fixed width.
SEM: a floating point step
A floating point number escapes this limit because it stores the order of magnitude separately from the significant digits. SEM lets the update block do the same. For each flow component, it predicts a sign logit , exponent logits over powers of two, and a mantissa logit , and the step is their product:
Taking the logarithm turns the product into a sum, so the network's outputs set the logarithm of the step. An error in them becomes a relative error of the step, and a step of pixels and a step of pixels are taken with the same relative precision.
Because only the output layer changes, SEM drops into any network that refines its flow by increments, with the same exponents and no tuning.
NibbleFlow

We build a network around SEM that an edge accelerator can run as a single static graph. Without a warp, each level correlates the two frames only along a few directions through each pixel, eight directions at 1/32, six at 1/16 and four at 1/8, and all three levels use a single SEM update block of width 96. NibbleFlow has 0.51M parameters and runs on a Hailo-8 with 86% of its weights in 4 bits. It is quantized with the Hailo compiler and its quantization-aware fine-tuning, which uses no Sintel data.
See the difference
Drag the slider. Both sides are the same network in INT4, with its linear output layer or with SEM, on one Sintel clean pair from Fig. 3 of the paper, with the EPE of the pair.


RAPIDFlow with 4-bit weights

Linear · 3.65 EPESEM · 1.24 EPENibbleFlow with 4-bit weights

Linear · 6.51 EPESEM · 1.41 EPE
Results
SEM in existing networks
RAFT-small iterates a GRU at a single scale, RAPIDFlow refines from coarse to fine with a shared block, and IRR-PWC refines a feature pyramid with shared weights. In each network, we replace the convolution that regresses the update by the SEM head, with the same exponents for all networks and no tuning, and change nothing else. Both versions are trained from scratch on FlyingChairs with the official settings and the same seed. Replacing the output layer costs no accuracy in RAFT-small and RAPIDFlow in floating point. The picture changes completely once the weights are quantized to 4 bits.
| Network | FP32 | INT4, linear | INT4, SEM |
|---|---|---|---|
| RAFT-small | 2.84 | 17.83 | 8.79 |
| RAPIDFlow, 12 iterations | 2.57 | 4.85 | 3.27 |
| RAPIDFlow, 1 iteration | 5.32 | 9.73 | 5.84 |
| IRR-PWC | 2.94 | 5.72 | 4.43 |
Sintel clean EPE (lower is better). FP32 is the linear version. INT4 is 4-bit weights with 8-bit activations, simulated with the same quantizer for both versions. With one iteration of RAPIDFlow, 4-bit weights add 4.41 EPE to the linear version and only 0.61 to SEM, which removes 86% of the added error.
Attribution of the quantization error. Quantizing one part of the network at a time locates this loss in a single layer. In RAPIDFlow with a single iteration, the 4-bit weights of the last convolution alone, which is the layer that SEM replaces, cost the linear version 4.98 of the 5.00 EPE that quantizing every layer costs, and SEM only 0.10. Keeping this one layer in 8 bits also rescues the linear version, which then matches SEM. The value of SEM is that its output layer tolerates 4-bit weights like every other layer, so no layer needs special treatment.
Comparison with edge optical flow networks
| Network | Params | GMACs | Sintel clean | Sintel final | Chairs | Hailo-8 FPS |
|---|---|---|---|---|---|---|
| NanoFlowNet | 0.17M | 0.93 | 14.14 | 14.31 | 10.39 | 120.55 |
| EdgeFlowNet | 2.75M | 19.98 | 8.65 | 9.22 | 5.50 | 76.30 |
| NibbleFlow (ours) | 0.51M | 6.97 | 4.76 | 5.68 | 3.14 | 15.19 |
EPE of the INT4 networks quantized for the Hailo-8 (lower is better), on all 1041 Sintel pairs and 640 FlyingChairs validation pairs. In FP32, NibbleFlow reaches 3.88 / 4.76 on Sintel clean / final. No network is trained or calibrated on Sintel.
With 86% of its weights in 4 bits, NibbleFlow loses less than one pixel of EPE and reaches 4.76 and 5.68, which cuts the error of EdgeFlowNet, the best deployable baseline, by up to 45%, with 5.4× fewer parameters. NanoFlowNet is smaller and faster, but its INT4 error is more than twice as high.
A controlled test of the update alone
| Update | Sintel clean | Sintel final | Clean, last 50 epochs | Final, last 50 epochs | Range (octaves) | Largest step |
|---|---|---|---|---|---|---|
| Linear | 4.89 | 6.10 | 5.04 ± 0.07 | 6.23 ± 0.07 | 5.6 | 2−0.6 px |
| SEM | 4.85 | 5.84 | 4.95 ± 0.06 | 5.99 ± 0.06 | 7.0 | 20.1 px |
The same network, trained on FlyingChairs only with the same seed, changing only the output of the update block. The range and the largest step are measured at the first update of the 1/32 level.
Downstream: visual odometry

Dense flow on a small robot is rarely the end product, so we test whether the ranking survives a downstream task. The three deployable networks run in INT4 and feed the same pose estimator, the five point algorithm inside RANSAC. No depth is used and the translation scale is taken from the ground truth, so the metrics measure only how well the flow constrains the camera rotation and the direction of travel.
| Mean ATE (m) | NibbleFlow | EdgeFlowNet | NanoFlowNet | Ground truth flow |
|---|---|---|---|---|
| TartanAir, 8 synthetic trajectories | 4.95 | 6.70 | 10.64 | 0.26 |
| UZH-FPV, 3 real drone flights | 5.46 | 8.89 | 18.76 | n/a |
Absolute trajectory error after SE(3) alignment, unweighted mean over the sequences. NibbleFlow has the lowest ATE on seven of the eleven sequences, EdgeFlowNet on four and NanoFlowNet on none.
Beyond optical flow
We believe that the same principle applies to any iterative regressor that must run in fixed point arithmetic, such as depth or disparity refinement. We will release our code and trained checkpoints upon acceptance.
Contact: xiaoao.song@colorado.edu, chahat.singh@colorado.edu