FFT3DFilter

From Avisynth wiki
Jump to: navigation, search
Abstract
Author Fizick, martin53, pinterf
Version v2.6
Download FFT3dFilter-v2.6.7z
Category Denoisers
License GPLv2
Discussion Doom9 Forum (original)

Doom9 Forum (2.6 update)

Contents

Description

FFT3DFilter uses Fast Fourier Transform method for image processing in frequency domain. It is based on some advanced mathematical algorithms of optimal filtration. It works not locally, but makes some de-localized (block) processing. In 3D mode, it results in effect similar to partial motion compensation. This filter can reduce noise without visible quality loss and artifacts, even with quite strong settings. It can greatly improve compression and reduce encoded file size. Also it has option of limited sharpening without both noise amplifying and over-sharpening (haloing).

Requirements


Syntax and Parameters

FFT3DFilter (clip, float "sigma", float "beta", int "plane", int "bw", int "bh", int "bt", int "ow", int "oh", float "kratio", float "sharpen", float "scutoff", float "svr", float "smin", float "smax", bool "measure", bool "interlaced", int "wintype", int "pframe", int "px", int "py", bool "pshow", float "pcutoff", float "pfactor", float "sigma2", float "sigma3", float "sigma4", float "degrid", float "dehalo", float "hr", float "ht", int "ncpu")


clip   =
Input clip


float  sigma = 2.0
Given noise value for all (or highest) frequencies. Only values greater that 0.0


float  beta = 1.0
Noise margin (float>=1.0, default=1.0 for no noise left): control noise amount left in the restoration for Wiener filter, so max filter noise attenuation = (beta-1)/beta.


int  plane = 0
Processed color plane:
  • 0 : luma(Y)
  • 1 : chroma U
  • 2 : chroma V
  • 3 : chroma planes U and V
  • 4 : both luma and chroma


int  bw = 48
int  bh = 48
Block width and height.


int  bt = 3
Block temporal size, number of frames.
  • 0 : all previous frames (switch Kalman filter mode)
  • 1 : only current frame (spatial 2D Wiener filter)
  • 2 : previous and current frame (3D Wiener filter)
  • 3 : previous, current and next frame (3D Wiener filter)
  • 4 : two previous, current and next frame (3D Wiener filter)
  • 5 : two previous, current and two next frames (3D Wiener filter)
  • -1 : sharpen only (2D)


int  ow = bw/3
int  oh = bh/3
Overlap width and height.


float  kratio = 2.0
Ratio of threshold to sigma to reset Kalman filter. Variation threshold = sigma*kratio, good value is about from 1.5 to 3.0


float  sharpen = 0.0
Sharpening strength (default=0 - do not sharpen). Good values are about 0.3 to 1.0 (negative values results in reverse effect)


float  scutoff = 0.3
Sharpening cutoff frequency, relative to max.


float  svr = 1.0
Sharpening (and dehalo) vertical ratio (to horizontal) (default=1.0 - same as horizontal, 0 - no vertical sharpening)


float  smin = 4.0
float  smin = 20.0
Minimum and maximum limit (approximate noise margin) for sharpening stage.


bool  measure = true
Select the most optimal (fastest) FFT method by speed measure (with longer init stage) instead of simple estimation.


bool  interlaced = false
Separate fields processing.


int  wintype = 0
weighting windows type:
  • 0 : same analysis and synthesis half-cosine window, used in all versions before 1.4.
  • 1 : intermediate between 0 and 2
  • 2 : flat analysis window, rised cosine (Hanning) synthesis window.


bool  pframe = false
Noise pattern frame number.


int  px = 0
int  py = 0
Noise pattern block horizontal X position and vertical Y position. If px=py=0, then the pattern block is defined automatically with minimal power spectral density.


bool  pshow = false
Show noise pattern block and its properties.


float  pcutoff = 0.1
Noise pattern cutoff frequency (relative to max).


float  pfactor = 0.0
Noise pattern denoise strength (0 to 1.0, default=0, this method disabled).


float  singma2 = sigma
float  singma3 = sigma
float  singma4 = sigma
Given noise value at second, third, and lowest scale level frequencies. Only values greater that 0.0


float  degrid = 1.0
Weighting window compensation degree for grid decreasing. Only values greater that 0.0


float  dehalo = 0.0
Halo removal strength. Only values greater that 0.0


float  hr = 2.0
Halo approximate radius. Only values greater that 0.0


float  ht = 50.0
Halo approximate threshold. Only values greater that 0.0


int  ncpu = 1
Max number of CPU threads to use for FFT calculation.


Changelog

Version      Date            Changes
v2.1.1 2007/02/20 - Last release by fizick, see included docs for full changelog





Back to External Filters

Personal tools