PDA

View Full Version : Help. Removing diagonal analog noise from video.


kastiauto
3rd February 2007, 10:49
Hello.

What filter can handle this kind of noise?

http://img382.imageshack.us/img382/3084/snap2mk1.jpg
and i also need some quality improvements to this video, deblocking, color correction and sharpen.
Can You please help me with proper filter and script.

Some screens here http://www.speedyshare.com/444392250.html

k

Boulder
3rd February 2007, 12:04
Looks like a job for Fizick's DeFreq.

Didée
3rd February 2007, 12:57
A similar case (http://forum.gleitz.info/showthread.php?t=28979&highlight=spatiales+sieb+goldw%E4scher-manier) once was solved with just MaskTools.

(Thread is in German, but the small script in the middle is Avisynth.) ;)

foxyshadis
3rd February 2007, 20:37
I have a feeling defreq and fanfilter would have a problem with this, look how the frequency changes across the frame. It could be done if it's just a few nearby frequencies, but if there's wide variations the Didée thing will probably work better. ;p

Deblocking is easy - just use deblock_qed if it's not horrible. You're going to have to gauge color yourself (avsp with coloryuv can help), and sharpening is also a matter of taste.

vcmohan
4th February 2007, 09:43
With FFTQuiver plugin using following script the noise can be removed satisfactorily.
The first call (commented out) to function F2Quiver is to look at the freq spectrum to decide upon filter(s) to be used.
<code>
snap = imagereader("D:\TransPlugins\images\snap2mk1.jpg",0,1,25,false).converttoYUY2()

#F2Quiver(snap,test = true, morph = true, gamma = 0.07)
F2 = F2Quiver(snap,"gp5",100,25)

</code>
loadPlugin ("D:\..\FFTQuiver.dll")
F1Quiver(snap,"gn",100,10) can also be used but due to strong amplitude changes some artifacts will be prominent.

Incidentally FanFilter is not that sensitive to frequency of noise. A range of nearby frequencies can be filtered with one call.

EasyStart
12th July 2007, 06:37
Hi vcmohan,

I have a similar problem with my vhs capture. Except that the noise is stronger. Wouldn't mind trying out your FFTQuiver plugin - F2Quiver, but I cannot work it out how to use it to filter an avi file. Please, help.

Regards,

Easystart:thanks:

J_Darnley
12th July 2007, 11:07
What can't you do? Download the plugin, load it, use it?

LoadPlugin("X:\Path to\FFTQuiver.dll")
AviSource("X:\Path to\file.avi")
#F2Quiver(test = true, morph = true, gamma = 0.07)
F2Quiver("gp5",100,25)
Is how I would use load and use it in a script. The LoadPlugin() line is not needed if you put the dll in the AviSynth auto load folder. See vcmohan's post about the commented line.

EasyStart
12th July 2007, 12:34
Thanks J_Darnley. Tried to call F2Quiver with and without the commented line. Both got an error - System exception - Access Violation. My avi is yv12 pal 720x576 resize down to 352x288 before calling F2Quiver.

#F2Quiver(test = true, morph = true, gamma = 0.07)
F2Quiver("gp5",100,25)

Any more thoughts.

Easystart:thanks:

Boulder
12th July 2007, 12:39
Try F2Quiver(last,"gp5",100,25). I've had access violations sometimes with MVTools stuff if I haven't specified any clip.

vcmohan
12th July 2007, 17:06
Hi vcmohan,

I have a similar problem with my vhs capture. Except that the noise is stronger. Wouldn't mind trying out your FFTQuiver plugin - F2Quiver, but I cannot work it out how to use it to filter an avi file. Please, help.

Regards,

Easystart:thanks:

If you can upload a single frame having the diagonal noise I can experiment for the optimum parameters.

mohan

EasyStart
13th July 2007, 00:44
F2Quiver(last,"gp5",100,25) still give Access Violation error. One more thing. My avi is progressive. I de-interlaced it during capturing. My Avisynth is version 2.6 runs in Windows Vista. Since, MVTools is mentioned. Here's a list of my plugins

#SetMTMode(2,2)
LoadPlugin("C:\Dvd\Avisynth 2.5x\MT.dll")
LoadPlugin("c:\Dvd\Avisynth 2.5x\SmoothDeinterlacer.dll")
#loadplugin("C:\Dvd\Avisynth 2.5x\tomsmocomp.dll")
LoadPlugin("C:\Dvd\Avisynth 2.5x\smoothD.dll")
LoadPlugin("C:\Dvd\Avisynth 2.5x\Deen.dll") #set 2
LoadPlugin("C:\Dvd\Avisynth 2.5x\TemporalCleaner.dll") #set 2
LoadPlugin("C:\Dvd\Avisynth 2.5x\unDot.dll") #set 2
LoadPlugin("C:\Dvd\Avisynth 2.5x\unFilter.dll") #set 2
LoadPlugin("C:\Dvd\Avisynth 2.5x\RemoveGrain.dll")
LoadPlugin("C:\Dvd\Avisynth 2.5x\RemoveDirt.dll")
LoadPlugin("C:\Dvd\Avisynth 2.5x\RSharpen.dll")
LoadPlugin("C:\Dvd\Avisynth 2.5x\Repair.dll")
LoadPlugin("C:\Dvd\Avisynth 2.5x\MaskTools.dll")
LoadPlugin("C:\Dvd\Avisynth 2.5x\mt_MaskTools.dll") #ver2.x
LoadPlugin("C:\Dvd\Avisynth 2.5x\mvtools.dll")
LoadPlugin("C:\Dvd\Avisynth 2.5x\warpsharp.dll")
LoadPlugin("C:\Dvd\Avisynth 2.5x\asharp.dll")
LoadPlugin("C:\Dvd\Avisynth 2.5x\aWarpSharp.dll")
LoadPlugin("C:\Dvd\Avisynth 2.5x\FFT3DFilter.dll")
LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\FFT3dGPU.dll")
LoadPlugin("C:\Dvd\Avisynth 2.5x\frfun7.dll")
LoadPlugin("C:\Dvd\Avisynth 2.5x\frfun3b.dll")
LoadPlugin("C:\Dvd\Avisynth 2.5x\degrainmedian.dll")
LoadPlugin("C:\Dvd\Avisynth 2.5x\cnr2.dll")
LoadPlugin("C:\Dvd\Avisynth 2.5x\AGC.dll")
LoadPlugin("C:\Dvd\Avisynth 2.5x\FluxSmooth.dll")
LoadPlugin("C:\Dvd\Avisynth 2.5x\VagueDenoiser.dll")
LoadPlugin("C:\Dvd\Avisynth 2.5x\deblock.dll")
LoadPlugin("C:\Dvd\Avisynth 2.5x\GiCoCU.dll") #Video2Film
LoadPlugin("C:\Dvd\Avisynth 2.5x\TweakColor.dll") #Video2Film
LoadPlugin("C:\Dvd\Avisynth 2.5x\Chanmix.dll") #Video2Film
LoadPlugIn("D:\Download\Mpeg\Encoder\Avisynth\scripts\LimitedSupport_09Jan06B.dll")
LoadPlugin("C:\Dvd\Avisynth 2.5x\EEDI2_imp.dll")

LoadPlugin("C:\Dvd\Avisynth 2.5x\FFTQuiver.dll")
LoadPlugin("C:\Dvd\Avisynth 2.5x\BiFrost.dll")
LoadPlugin("C:\Dvd\Avisynth 2.5x\SSIQ.dll")
LoadPlugin("C:\Dvd\Avisynth 2.5x\MipSmooth.dll")
LoadPlugin("C:\Dvd\Avisynth 2.5x\mSharpen.dll")

#LoadCPlugin("C:\Program Files\AviSynth 2.5\plugins\ffavisynth.dll")

Import("D:\Download\Mpeg\Encoder\Avisynth\scripts\LimitedSharpenFaster.avs")
Import("D:\Download\Mpeg\Encoder\Avisynth\scripts\pSharpen.avs")
Import("D:\Download\Mpeg\Encoder\Avisynth\scripts\SeeSaw_2006.01.02.avs")
Import("D:\Download\Mpeg\Encoder\Avisynth\scripts\Soothe masktools2.avs")
Import("D:\Download\Mpeg\Encoder\Avisynth\scripts\LanczosPlus.avs")



Here's my avisynth script function

function SeeSaw_FFT3DGPU( Clip Clip )
{
Clip

#F2Quiver( snap,"gp5",50,-133,"gp5",50,120)
#F2QuiverUV("gvn",50,30,"ghn", 60,20, uu = true, vv = true)

#F2Quiver(test = true, morph = true, gamma = 0.07)
#F2Quiver("gp5",100,25)

#Bifrost( interlaced=false ) #de-rainbow
#SmartSSIQ( strength=200 )

DeRainbow( thresh=80 )

mt("LimitedSharpenFaster( ss_x=2.5, ss_y=2.25, strength=180, smode=4 )")
#mt("pSharpen()")

( last.height > 288 )
\ ? fft3dGPU( sigma=5, plane=0 ).fft3dGPU( sigma=6, plane=3 )
\ : fft3dGPU( sigma=2, bt=2 )

mt("
a = last
b = a.degrainmedian( mode=1 ).cnr2()
SeeSaw( a,b,NRlimit=17,bias=18,Smode=11,Szp=18,SdampLo=20 )
")

Bifrost( interlaced=false ) #de-rainbow

return last
}




Here's 10 jpeg screens http://download.yousendit.com/1AF3676E6AC84081

Easystart:thanks::script:

Boulder
13th July 2007, 03:20
My Avisynth is version 2.6 runs in Windows Vista.2.6 or 2.5.6? Better try 2.5.7 or 2.5.8 alpha.

EasyStart
13th July 2007, 04:05
I have problem with avisynth 2.5.6a and 2.5.7, MT.dll crashes my avs file when frameserving. I will have another go again later on tonight.

:thanks:

Boulder
13th July 2007, 04:12
2.6 is not stable and not meant for any production use so you really should try to get 2.5.x working. You have to use tsp's special Avisynth build if you intend to use MT. The required avisynth.dll is included in the MT package.

EasyStart
13th July 2007, 04:40
Avisynth 2.5.7 and latest version of MT works ok this time after doing a Windows Vista update but still getting Access Violation error. I then tried creating a 3 lines avs file and still getting error.

LoadPlugin("C:\Dvd\Avisynth 2.5x\FFTQuiver.dll")

AviSource("g:\tmp\capture.avi", true, "YV12")

#F2Quiver( test = true, morph = true, gamma = 0.07)
F2Quiver( "gp5",100,25)

Easystart

Boulder
13th July 2007, 06:00
Well, there probably is something in F2Quiver so it's up to vcmohan to check it out.

vcmohan
13th July 2007, 14:30
I will look into it. I am away from my desktop (will be away for another 4 months) and have a notebook with vista. It refuses to instal VC++ or mingw. I will check and do my best if I find a bug.
Hope Avisynth loads into Vista without any problem.

vcmohan
14th July 2007, 00:23
I could get my notebook to work with avisynth. I have seen the images in the zip file. The following code removes (not all) noise. As many features in the image have similar pattern to that of noise I did not think of using stronger filters. It can be experimented if desired.
Loadplugin("c:\aviplugins\fftquiver.dll")
Imagesource("c:\images\capture008.jpeg",0,0,24)
converttoyuy2()
f=f2quiver("gvn",53,20)

EasyStart
14th July 2007, 01:11
Thanks guys for you fast replies. I got F2Quiver to work on in Windows Vista. F2Quiver is not compartible with the new version of fftw3.dll. It works if you download fftw3.dll from vcmohan's website.

Easystart:thanks:

vcmohan
14th July 2007, 14:03
On my plugins page link to warpenterprises link to FFTw3.dll is given, and warpenterprises usually updates very fast.

I did not get any access violations while working with this plugin. However I will continue to check.

EasyStart
15th July 2007, 00:40
I was using fftw 3.1 dll before. It is dated January 2006. The version downloaded from vcmohan's link is dated January 2004. The newer version does not work with F2Quiver. You will get an Access Violation error.

Easystart