ANVIL: Accelerator-Native Video Interpolation via Codec Motion Vector Priors
Organizations: College of Science, North China University of Science and Technology, Tangshan 063210, China
Abstract
Real-time 30-to-60 fps video frame interpolation on mobile neural processing units (NPUs) requires each synthesized frame within 33.3 ms. We show that mainstream flow-based video frame interpolation faces three structural deployment barriers on mobile NPUs: spatial sampling operators exceed the frame budget or lack hardware support, iterative flow refinement collapses under 8-bit integer post-training quantization, and memory-bound operators dominate the inference graph. ANVIL addresses these barriers by reusing motion vectors from the H.264/AVC decoder to prealign input frames, removing learned optical flow, spatial sampling, and iterative accumulation from the accelerator graph. The remaining residual is refined by a convolution-dominated network composed almost entirely of compute-bound operators. On a Snapdragon 8 Gen 3 device, ANVIL achieves 12.8 ms 1080p inference at 8-bit integer precision; an open-source Android player sustains 28.4 ms median end-to-end latency over 30-minute continuous playback. Per-operator causal analysis identifies quantized accumulation on recurrent flow states as a key mechanism behind integer quantization failure in iterative methods. The current design targets H.264/AVC playback with decoder-exposed motion vectors.
Figures & tables
| SoC | NPU | ANVIL-S | ANVIL-M | RIFE ‡ | 33.3ms |
|---|---|---|---|---|---|
| SD 7+ Gen2 | HTP V69 | 46.0 ms | 56.6 ms | 45.6 ms | |
| SD 8 Gen2 | HTP V73 | 15.5 ms | 20.8 ms | 20.7 ms | ✓ |
| SD 8 Gen3 | HTP V75 | 12.8 ms | 16.7 ms | 14.7 ms | ✓ |
| Group | Operator | Freq | HTP V75 | APU 790 | Impact |
| A | Conv2d 3 3 | 9/9 | 1.0 | 1.0 | Baseline |
| A | Conv2d 1 1 | 8/9 | 0.9 | 1.0 | |
| A | Conv + ReLU | 5/9 | 1.0 | 1.0 | |
| A | ConvTranspose2d | 7/9 | 3.9 | 2.7 | Moderate cost both platforms |
| A | Residual Add | 9/9 | 2.3 | 1.8 | |
| B | GridSample | 7/9 | 3.2 | N/A | MTKEXT custom op, public SDK unavailable |
| Method | Stg | Mode | PSNR: FP32 INT8 ( ) | 95% CI |
|---|---|---|---|---|
| ANVIL-S | 0 | direct | 29.28 29.09 ( 0.19 ) † | — † |
| ANVIL-M | 0 | direct | 29.37 29.28 ( 0.09 ) † | — † |
| RIFE | 3 | flow | 26.79 25.90 ( 0.89) | [ 0.96, 0.83] |
| IFRNet | 4 | flow | 25.43 25.03 ( 0.40) | [ 0.44, 0.37] |
| IFRNet | 4 | frame | 25.84 21.46 ( 4.38) | [ 4.75, 4.01] |
| Quantized Ops | RIFE (3-stage) | IFRNet (4-stage) | ||
|---|---|---|---|---|
| CosSim | CosSim | |||
| None (FP32) | 1.000 | — | 1.000 | — |
| Conv, ConvTr | 0.952 | 0.048 | 0.945 | 0.055 |
| PReLU | 0.952 | 0.000 | 0.945 | 0.000 |
| Add | 0.815 | 0.137 | 0.878 | 0.068 |
| Full W8A8 | 0.790 | Add | 0.859 | Add |
| Method | Params | Vimeo90K | Xiph 1080p | Deployment Status | ||||
| PSNR | SSIM | LPIPS | PSNR | SSIM | LPIPS | |||
| Zero-parameter baselines | ||||||||
| Naive Blend | 0 | 25.61 | 0.753 | 0.099 | 25.32 | 0.658 | 0.165 | — |
| MV Blend | 0 | 31.20 | 0.926 | 0.053 | 28.98 | 0.813 | 0.115 | — |
| ANVIL (ours) — 1080p INT8 deployable | ||||||||
| ANVIL-S | 855K | 33.45 | 0.949 | 0.037 | 29.65 | 0.835 | 0.154 | Deployable |
| Res. | Mode | FP32 | ORT | QNN | INT8 lat. |
|---|---|---|---|---|---|
| 360p | flow | 28.54 | 2.03 | 1.43 | 14.7 ms |
| 360p | frame | 27.00 | 3.80 | 3.44 | 17.8 ms |
| 480p | flow | 29.13 | 2.90 | 2.24 | 28.2 ms |
| 480p | frame | 28.23 | 5.12 | 4.84 | 36.3 ms ∗ |
| ∗ Exceeds 33.3 ms deadline even at INT8. | |||||
| Flow construction | Post-processing | PSNR |
|---|---|---|
| ZOH | none (sub-pixel remap only) | 29.63 |
| OBMC (cosine) | none | 29.58 |
| Daala | Gaussian | 30.89 |
| ZOH | median 5 Gaussian | 31.20 |
| Model | Params | Vimeo PSNR | INT8 1080p |
|---|---|---|---|
| Route A (no prealignment) | |||
| A-small | 33K | 29.00 | — |
| Route D (MV prealignment) | |||
| D-tiny-nomv | 1.8K | 30.67 | 3.52 ms |
| D-mini-nomv | 10.6K | 31.08 | 4.26 ms |
| D-mid-nomv | 33K | 31.38 | 8.16 ms |
| Stage | HW | Latency | Operation |
|---|---|---|---|
| P1a | CPU | 2.9 ms | ZOH densify + downsample + YUV pack |
| P1b+P2 | GPU | 3.7 ms | median 5 + Gauss + warp + quant |
| Copy | CPU | 0.9 ms | 12 MB uint8 NHWC to QNN buffer |
| P3 | HTP | 17.0 ms | INT8 graphExecute (async, pipelined) |
| P4 | GPU | 3.3 ms | dequant + residual + RGB YUV420 |
| Total per pair | 28.4 ms | median; 94.9% 33.3 ms | |
| Method | tOF | tOF | WE |
|---|---|---|---|
| GT | 8.93 | — | 0.034 |
| RIFE HDv3 | 7.42 | 1.62 | 0.027 |
| ANVIL-S | 6.91 | 2.09 | 0.027 |
| ANVIL-M | 6.87 | 2.09 | 0.027 |
| MV Blend | 6.13 | 2.83 | 0.026 |
Video Frame Interpolation
Video frame interpolation estimates intermediate frames between observed video frames to create smoother playback and reconstruct temporal detail.
See all 26 papers