Skip to content

WebSR 0.1.1: edge pixel fix

Latest

Choose a tag to compare

@sb2702 sb2702 released this 13 Nov 14:42
· 1 commit to main since this release

Fixes missing pixels at the right and bottom edges.

Compute layers dispatched floor(W/8) × floor(H/8) workgroups, so when the width or height wasn't a
multiple of the workgroup size the last few columns and rows were never computed. For
realesrgan/x4v3 (16×16 workgroups) the gap also spread inward through its convolutions.
0.1.1 dispatches with ceil and adds a bounds check to every compute shader.

  • Output is unchanged at sizes that are multiples of 16, and for websr/gan-* at every size.
  • realesrgan/x4v3 edges now match a full reference (93 dB vs 33–39 dB before, f32).
  • The legacy anime4k/cnn-2x-s, cnn-2x-m, cnn-restore-s and cnn-restore-m networks also change in their first few left/top edge pixels at those sizes.