-
Notifications
You must be signed in to change notification settings - Fork 20
RealESRGANv2
AkarinVS edited this page Jan 21, 2022
·
22 revisions
RealESRGANv2 is a practical image super-resolution neural network that removes common image artifacts.
Link:
Includes small models optimized for anime videos:
- RealESRGANv2: requires RGB input
- animevideo-xsx2, animevideo-xsx4 (2x / 4x upscaling)
In order to simplify usage, we provided a Python wrapper module vsmlrt:
from vsmlrt import RealESRGANv2, RealESRGANv2Model, Backend
src = core.std.BlankClip(format=vs.RGBS)
# backend could be:
# - CPU Backend.OV_CPU(): the recommended CPU backend; generally faster than ORT-CPU.
# - CPU Backend.ORT_CPU(num_streams=1, verbosity=2): vs-ort cpu backend.
# - GPU Backend.ORT_CUDA(device_id=0, cudnn_benchmark=True, num_streams=1, verbosity=2)
# - use device_id to select device
# - set cudnn_benchmark=False to reduce script reload latency when debugging, but with slight throughput performance penalty.
# - GPU Backend.TRT(fp16=True, device_id=0, num_streams=1): TensorRT runtime, the fastest NV GPU runtime.
flt = RealESRGANv2(src, model=RealESRGANv2Model.animevideo_xsx2, backend=Backend.ORT_CUDA())
src = core.std.BlankClip(width=1920, height=1080, format=vs.RGBS)
flt = core.ov.Model(src, "RealESRGANv2/RealESRGANv2-animevideo-xsx2")
Measurements: FPS / Device Memory (GB)
Device memory:
- CPU: private memory including VapourSynth
- GPU: device memory including context
Software: VapourSynth R57, Windows Server 2019, Graphics Driver 511.23
Input size: 1920x1080
- vs-mlrt v6
- vs-realesrgan v2.0.0, PyTorch 1.10.1+cu113
Model | [1] ort-cuda | [1] trt | [1] trt (2 streams) | [2] cuda |
---|---|---|---|---|
xsx2 | 5.27 / 2213 | 6.07 / 1835 | 6.86 / 2999 | 3.64 / 6799 |
Model | [1] ort-cuda | [1] trt | [1] trt (2 streams) | [2] cuda |
---|---|---|---|---|
xsx2 | N/A | 11.8 / 1637 | 15.5 / 2539 | 4.72 / 4291 |
Software: VapourSynth R57, Windows Server 2019, Graphics Driver 511.23, lock the GPU clocks at max frequency.
Input size: 1920x1080
- vs-mlrt v6
- vs-realesrgan v2.0.0, PyTorch 1.10.1+cu113
Model | [1] ort-cuda | [1] trt | [1] trt (2 streams) | [2] cuda |
---|---|---|---|---|
xsx2 | 4.15 / 2817 | 4.97 / 1965 | 5.26 / 3125 | 3.47 / 7075 |
Model | [1] ort-cuda | [1] trt | [1] trt (2 streams) | [2] cuda |
---|---|---|---|---|
xsx2 | N/A | 11.5 / 1881 | 12.1 / 2769 | 4.90 / 4585 |
Hardware: Xeon Icelake Server 32C64T @2.90 GHz
Software: VapourSynth R57, Windows Server 2019
Input size: 1920x1080
- vs-mlrt v6
Model | [1] ov-cpu |
---|---|
xsx2 | 1.48 / 5239 |
Hardware: EPYC Milan 16C32T @2.55 GHz
Software: VapourSynth R57, Windows Server 2019
Input size: 1920x1080
- vs-mlrt v6
Model | [1] ov-cpu |
---|---|
xsx2 | 0.42 / 5201 |
- Runtimes
- Models
- Device-specific benchmarks
- NVIDIA GeForce RTX 4090
- NVIDIA GeForce RTX 3090
- NVIDIA GeForce RTX 2080 Ti
- NVIDIA Quadro P6000
- AMD Radeon RX 7900 XTX
- AMD Radeon Pro V620
- AMD Radeon Pro V520
- AMD Radeon VII
- AMD EPYC Zen4
- Intel Core Ultra 7 155H
- Intel Arc A380
- Intel Arc A770
- Intel Data Center GPU Flex 170
- Intel Data Center GPU Max 1100
- Intel Xeon Sapphire Rapids