<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.selur.net/index.php?action=history&amp;feed=atom&amp;title=Vapoursynth_GRLIR</id>
	<title>Vapoursynth GRLIR - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.selur.net/index.php?action=history&amp;feed=atom&amp;title=Vapoursynth_GRLIR"/>
	<link rel="alternate" type="text/html" href="https://wiki.selur.net/index.php?title=Vapoursynth_GRLIR&amp;action=history"/>
	<updated>2026-11-19T06:07:57Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.46.2</generator>
	<entry>
		<id>https://wiki.selur.net/index.php?title=Vapoursynth_GRLIR&amp;diff=563&amp;oldid=prev</id>
		<title>Selur: New filter page (via create-page on MediaWiki MCP Server)</title>
		<link rel="alternate" type="text/html" href="https://wiki.selur.net/index.php?title=Vapoursynth_GRLIR&amp;diff=563&amp;oldid=prev"/>
		<updated>2026-11-16T08:50:23Z</updated>

		<summary type="html">&lt;p&gt;New filter page (via create-page on MediaWiki MCP Server)&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;&amp;lt;div style=&amp;quot;float:right; margin:0 0 1em 1em;&amp;quot;&amp;gt;__TOC__&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;GRLIR&amp;#039;&amp;#039;&amp;#039; runs the restoration models of GRL, a transformer network that models image structure at several scales: deblurring, demosaicking, denoising and JPEG artifact removal at the input size. It runs on an NVIDIA GPU through PyTorch and is slow; the super-resolution models are in [[Vapoursynth GRLIR Resize]].&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;Filtering → Vapoursynth → Other&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
[[File:Vapoursynth_GRLIR.png|none|GRLIR controls in Hybrid]]&lt;br /&gt;
&lt;br /&gt;
== What it does ==&lt;br /&gt;
Every frame is restored on its own (no temporal processing) by the chosen model; the output keeps the input size.&lt;br /&gt;
&lt;br /&gt;
== Requirements ==&lt;br /&gt;
* Windows, Hybrid&amp;#039;s torch add-on and an NVIDIA GPU with CUDA.&lt;br /&gt;
&lt;br /&gt;
== Settings ==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Control !! Parameter !! Range / values !! Hybrid default !! Meaning&lt;br /&gt;
|-&lt;br /&gt;
| Model || model || Defocus Deblurring, Motion Deblurring (GoPro), (RealBlur-J), (RealBlur-R), Demosaicking, Denoising (sigma 15/25/50), JPEG compression artifact removal (quality 10/20/30/40) || Defocus Deblurring || Network; denoising and JPEG models are trained for one noise level or JPEG quality.&lt;br /&gt;
|-&lt;br /&gt;
| GPU ID || device_index || 0 – 4 || 0 || CUDA device.&lt;br /&gt;
|-&lt;br /&gt;
| Streams || num_streams || 1 – 64 || 1 || Number of CUDA streams; not more than VapourSynth&amp;#039;s thread count.&lt;br /&gt;
|-&lt;br /&gt;
| CUDA Graph || cuda_graphs || on/off || off || Uses CUDA graphs.&lt;br /&gt;
|-&lt;br /&gt;
| Tile (x/y) || tile_w, tile_h || 0 – 8192 || 0 / 0 || Splits the frame into tiles to save GPU memory; 0 = no tiling (both values must be set).&lt;br /&gt;
|-&lt;br /&gt;
| Tile pad || tile_pad || 0 – 64 || 16 || Overlap of the tiles; only with tiling. Changing the model while tiling sets the model&amp;#039;s own pad (16 deblurring/denoising, 12 motion deblurring, 8 demosaicking, 36 JPEG).&lt;br /&gt;
|-&lt;br /&gt;
| FP16 || – || on/off || off || Half precision (16-bit float clip); faster and needs less memory.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Example ==&lt;br /&gt;
Default settings on a 10-bit YUV 4:2:0 source (640x356):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# adjusting color space from YUV420P10 to RGBS for vsGRLIRFilter&lt;br /&gt;
clip = core.resize.Bicubic(clip=clip, format=vs.RGBS, matrix_in_s=&amp;quot;470bg&amp;quot;, range_in_s=&amp;quot;limited&amp;quot;, range_s=&amp;quot;full&amp;quot;)&lt;br /&gt;
# restoring using GRLIR&lt;br /&gt;
from vsgrlir import grlir&lt;br /&gt;
clip = grlir(clip, model=1)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== How Hybrid calls it ==&lt;br /&gt;
* The clip is converted to 32-bit float RGB (16-bit float with FP16); the plugin pads the frame to its window size itself.&lt;br /&gt;
* The model is always written, and so is the tile pad while tiling is on; GPU ID, streams, tiles and CUDA Graph only when they differ from the defaults.&lt;br /&gt;
* GRLIR also offers the [[Vapoursynth common filter options|common options]] (Masked, ApplyOnlyTo, Merge, OnRegion, Gimmick).&lt;br /&gt;
&lt;br /&gt;
== Background ==&lt;br /&gt;
=== GRL ===&lt;br /&gt;
GRL (Li et al., CVPR 2023, &amp;quot;Efficient and Explicit Modelling of Image Hierarchies for Image Restoration&amp;quot;) combines regional, local and global attention, so the network sees structure at several distances at once.&lt;br /&gt;
&lt;br /&gt;
=== vs-grlir ===&lt;br /&gt;
HolyWu&amp;#039;s vs-grlir runs GRL in VapourSynth with PyTorch and accepts 16- or 32-bit float RGB. Without an explicit tile pad it picks one per model, which is why Hybrid always writes the value shown.&lt;br /&gt;
&lt;br /&gt;
== Sources ==&lt;br /&gt;
* [https://github.com/HolyWu/vs-grlir vs-grlir]&lt;br /&gt;
* [https://github.com/ofsoundof/GRL-Image-Restoration GRL]&lt;br /&gt;
* Hybrid&amp;#039;s tooltips&lt;br /&gt;
&lt;br /&gt;
[[Category:Vapoursynth Filters]]&lt;/div&gt;</summary>
		<author><name>Selur</name></author>
	</entry>
</feed>