Changes between Version 12 and Version 13 of DenoiseExamples


Ignore:
Timestamp:
Jun 9, 2024, 3:48:52 PM (2 years ago)
Author:
MasterQuestionable
Comment:

[m] Use "shell" highlight.

Legend:

Unmodified
Added
Removed
Modified
  • DenoiseExamples

    v12 v13  
    4242For example, when an analog source is digitized, there may be a disproportionate amount of noise in the chroma plane.  The following will produce a 4x4 mosaic containing `{original, luma, Cb, Cr}`, similar to the tools such as [https://www.neatvideo.com/support/tutorials/nv5/building-noise-profile Neat Video noise-preview].  Frames are converted to yuv444p (or yuv444p10le for 10-bit) in order to remove chroma-subsampling of a yuv422p or yuv420p source, where chroma-planes are encoded at a lower resolution.
    4343
    44 {{{
    45   $ ffplay -f 'lavfi' "movie='${In}', \
     44{{{#!shell
     45$ ffplay -f 'lavfi' "movie='${In}', \
    4646  format=pix_fmts='yuv444p',split=2[split1][split2]; \
    4747  [split2]extractplanes='y+u+v'[y][u][v]; \
    … …  
    6464The visual effect of a denoise filter is subjective.  A user is encouraged to compare denoise filters.  The following command will compare `null` (no-operation) filter on the left of the player window with the `hqdn3d` filter (with default properties) on the right of the center-line.
    6565
    66 {{{
     66{{{#!shell
    6767$ ffplay -f 'lavfi' "movie='${In}', \
    6868  split=2[split1][split2]; \
    … …  
    7676It is possible to extend the above command to cycle through the `{ combined, luma, Cb, Cr }` planes using FFplay's ''"cycle video filters or show modes"'' using the `w` key.
    7777
    78 {{{
     78{{{#!shell
    7979$ ffplay -f 'lavfi' "movie='${In}', \
    8080  split=2[split1][split2]; \
    … …  
    9696For example, here is a comparison of the relative performance of the `hqdn3d` and the `nlmeans` filters across 1000 video frames.  These comparisons and values are not recommendations, but are to demonstrate how algorithm and options selection can have a major impact on performance.
    9797
    98 {{{
     98{{{#!shell
    9999$ ffmpeg -an -dn -sn -i "${In}" -filter:v hqdn3d,latency,trim=end_frame=1000 -f null -
    100100 [Parsed_latency] Min latency: 156 bitrate=N/A speed=14.1x
    … …  
    119119
    120120Simple usage with default options...
    121 {{{
     121{{{#!shell
    122122$ ffmpeg -i "${In}" -vf atadenoise "${Out}"
    123123
    … …  
    126126
    127127Advanced options usage...
    128 {{{
     128{{{#!shell
    129129$ ffmpeg -i "${In}" \
    130130  -filter:v "atadenoise=0a=0.02:0b=0.04:1a=0.02:1b=0.04:2a=0.02:2b=0.04:s=9:p=7:a='p':0s=32767:1s=32767:2s=32767" \
    … …  
    135135
    136136Command-line help is available at the terminal prompt...
    137 {{{
     137{{{#!shell
    138138$ ffmpeg -hide_banner -h filter=atadenoise
    139139}}}
    … …  
    146146
    147147Simple usage with default options...
    148 {{{
     148{{{#!shell
    149149$ ffmpeg -i "${In}" -vf bm3d "${Out}"
    150150
    … …  
    153153
    154154Advanced options usage...
    155 {{{
     155{{{#!shell
    156156$ ffmpeg -i "${In}" \
    157157  -filter:v "bm3d=sigma=1.0:block=8:bstep=4:group=1:range=9:mstep=1:thmse=0:hdthr=2.70:estim='basic':ref='disabled':planes=7" \
    … …  
    162162
    163163Command-line help is available at the terminal prompt...
    164 {{{
     164{{{#!shell
    165165$ ffmpeg -hide_banner -h filter=bm3d
    166166}}}
    … …  
    173173
    174174Simple usage with default options...
    175 {{{
     175{{{#!shell
    176176$ ffmpeg -i "${In}" -vf dctdnoiz "${Out}"
    177177
    … …  
    180180
    181181Advanced options usage...
    182 {{{
     182{{{#!shell
    183183$ ffmpeg -i "${In}" \
    184184  -filter:v "dctdnoiz=sigma=0:overlap=-1:n=3" \
    … …  
    189189
    190190Command-line help is available at the terminal prompt...
    191 {{{
     191{{{#!shell
    192192$ ffmpeg -hide_banner -h filter=dctdnoiz
    193193}}}
    … …  
    200200
    201201Simple usage with default options...
    202 {{{
     202{{{#!shell
    203203$ ffmpeg -i "${In}" -vf fftdnoiz "${Out}"
    204204
    … …  
    207207
    208208Advanced options usage...
    209 {{{
     209{{{#!shell
    210210$ ffmpeg -i "${In}" \
    211211  -filter:v "fftdnoiz=sigma=1:amount=1:block=32:overlap=0.5:method='wiener':prev=0:next=0:planes=7:window='hann'" \
    … …  
    216216
    217217Command-line help is available at the terminal prompt...
    218 {{{
     218{{{#!shell
    219219$ ffmpeg -hide_banner -h filter=fftdnoiz
    220220}}}
    … …  
    229229
    230230Simple usage with default options...
    231 {{{
     231{{{#!shell
    232232$ ffmpeg -i "${In}" -vf hqdn3d "${Out}"
    233233
    … …  
    236236
    237237Advanced options...
    238 {{{
     238{{{#!shell
    239239$ ffmpeg -i "${In}" \
    240240  -filter:v "hqdn3d=hqdn3d=luma_spatial=4.00:chroma_spatial=3.00:luma_tmp=6.00:chroma_tmp=4.5" \
    … …  
    245245
    246246Command-line help is available at the terminal prompt...
    247 {{{
     247{{{#!shell
    248248$ ffmpeg -hide_banner -h filter=hqdn3d
    249249}}}
    … …  
    264264
    265265Simple usage with default options...
    266 {{{
     266{{{#!shell
    267267$ ffmpeg -i "${In}" -vf nlmeans "${Out}"
    268268
    … …  
    271271
    272272Advanced options usage...
    273 {{{
     273{{{#!shell
    274274$ ffmpeg -i "${In}" \
    275275  -filter:v "nlmeans=s=1.00:p=7:pc=0:r=15:rc=0" \
    … …  
    280280
    281281Command-line help is available at the terminal prompt...
    282 {{{
     282{{{#!shell
    283283$ ffmpeg -hide_banner -h filter=nlmeans
    284284$ ffmpeg -hide_banner -h filter=nlmeans_opencl
    … …  
    301301
    302302Simple usage with default options...
    303 {{{
     303{{{#!shell
    304304$ ffmpeg -i "${In}" -vf owdenoise "${Out}"
    305305
    … …  
    308308
    309309Advanced options usage...
    310 {{{
     310{{{#!shell
    311311$ ffmpeg -i "${In}" \
    312312  -filter:v "fftdnoiz=owdenoise=depth=8:luma_strength=1:chroma_strength=1 " \
    … …  
    317317
    318318Command-line help is available at the terminal prompt...
    319 {{{
     319{{{#!shell
    320320$ ffmpeg -hide_banner -h filter=owdenoise
    321321}}}
    … …  
    328328
    329329Simple usage with default options...
    330 {{{
     330{{{#!shell
    331331$ ffmpeg -i "${In}" -vf vaguedenoiser "${Out}"
    332332
    … …  
    335335
    336336Advanced options usage...
    337 {{{
     337{{{#!shell
    338338$ ffmpeg -i "${In}" \
    339339  -filter:v "vaguedenoiser=threshold=2:method='garrote':nsteps=6:percent=85:planes=7:type='universal'" \
    … …  
    344344
    345345Command-line help is available at the terminal prompt...
    346 {{{
     346{{{#!shell
    347347$ ffmpeg -hide_banner -h filter=vaguedenoiser
    348348}}}