LiveActionSR-2x
Two tiny 2x luma super-resolution networks for real-time upscaling of streamed films and TV in the browser. They run as hand-written WGSL compute shaders in ArtPlayerPluginLiveActionSR, an ArtPlayer plugin. They were trained on live-action footage pushed through real x264 / x265 / SVT-AV1 round-trips, so they upscale streaming video rather than clean photos.
| Model | Params | Channels Γ convs | RTX 5080, 1080pβ4K | 720pβ1440p |
|---|---|---|---|---|
balanced |
12,340 | 16 Γ 7 | 2.95 ms | 1.31 ms |
quality |
47,716 | 32 Γ 7 | 9.90 ms | 4.13 ms |
The times cover the plugin's whole chain (deband, CNN, sharpening, grain) on Chrome WebGPU with f16.
Results
The table gives the PSNR-Y gain over Lanczos on 1,024 held-out validation pairs from scenes not in training (including Netflix and UVG-VCM). Most went through x264 / x265 / SVT-AV1 at streaming quality (CRF 18β46); some are clean.
| Model | All | clean | x264 | x265 | AV1 |
|---|---|---|---|---|---|
| bicubic | β0.09 | ||||
balanced |
+0.44 | +0.26 | +0.45 | +0.42 | +0.49 |
quality |
+0.52 | +0.43 | +0.53 | +0.48 | +0.58 |
The models are small on purpose: they have to fit a few milliseconds per frame on integrated GPUs. For a stronger, ten times larger option (487k parameters) see EfRLFN-2x-WebGPU.
Architecture
- Input: the BT.709 luma Y of the source frame, values 0..1.
- Network:
y β conv3x3(1βC) β ReLU β [conv3x3(CβC) β ReLU] Γ 5 β conv3x3(Cβ4) β depth_to_space(2) ββ βββββββββββββ bilinear 2x (half-pixel centres, clamp-to-edge) ββββββββββββββββββββββββββ(+)ββ clamp[0,1] - Padding: clamp-to-edge (replicate) everywhere.
- Chroma: upscaled bilinearly.
- Training: L1 loss, AdamW, 64Γ64 LR patches, bf16.
balancedran 200k iterations andquality300k, on a single RTX 5080 (1 h 40 min end to end, including data).
Files
| File | What |
|---|---|
balanced.json, quality.json |
The plugin's weights format: layers of conv3x3 (weights[out][in][ky][kx], bias), relu and depth_to_space, plus residual: "bilinear" |
*.onnx |
The same network for ONNX Runtime and others. Input 1Γ1ΓHΓW luma, output 1Γ1Γ2HΓ2W; the bilinear residual is included |
*.safetensors |
PyTorch state dicts for LumaSR in the training code |
NOTICE.md |
Training footage and attribution |
Use
import Artplayer from 'artplayer';
import liveActionSR from 'artplayer-plugin-liveaction-sr';
new Artplayer({
container: '#player',
url: 'film.m3u8',
plugins: [liveActionSR({
models: {
balanced: 'https://huggingface.co/PianoNic/LiveActionSR-2x/resolve/main/balanced.json',
quality: 'https://huggingface.co/PianoNic/LiveActionSR-2x/resolve/main/quality.json',
},
})],
});
The npm package also ships these files under artplayer-plugin-liveaction-sr/models/*.
Training data
All sources are permissively licensed:
- Netflix Open Content, CC BY 4.0: Chimera, El Fuente, Meridian, Nocturne, Sparks.
- Tears of Steel: (CC) Blender Foundation, CC BY 3.0.
- UVG-VCM (Tampere University): CC BY 4.0.
- TU MΓΌnchen and SVT test sequences.
Altogether: 6,464 clips and 75,372 training pairs. The full list and terms are in DATASETS.md, and the attribution lines are in NOTICE.md.
Limitations
- Upscaling: 2x only.
- Grain: these are PSNR-trained models, so they smooth rather than invent detail. The plugin adds film grain back afterwards.
- Colour: chroma is not super-resolved.
- HDR: HDR sources must be tone-mapped to SDR first; the plugin does that.
Licence
The weights are MIT, like the plugin. The training footage keeps its own licences (see NOTICE.md).