Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > Capturing and Editing Video > Avisynth Usage

Reply
 
Thread Tools Search this Thread Display Modes
Old 24th March 2007, 20:47   #1  |  Link
ficofico
Registered User
 
Join Date: Nov 2006
Posts: 146
A very hard work (a lot of filter)

I want to encode 5 hours of mpeg recording using avisynth filter.
I have italy-france ( The final ) football match recorded with my dvdrecording ( sp recording), The mpeg file are interlaced and with a not good quality, I want to encode with x264 insane quality and I'm not afraid for time to spending!!!

I ask for some script improvement, This is what I use at this moment ( the script is using in virtual dub, The returned avi file without compression, next time pass trough megui)

Code:
DGDecode_mpeg2source("K:\Satellite\prove\3-parte.d2v",info=3)

ColorMatrix(hints=true)

mt("mcbob")

YToUV(FFT3DFilter(sigma=3, plane=1, bw=32, bh=32).UToY,\
FFT3DFilter(sigma=3, plane=2, bw=32, bh=32).VToY,\
FFT3DFilter(sigma=2, plane=0, bw=32, bh=32))
YToUV(FFT3DFilter(sigma=3, plane=1, bw=4, bh=4).UToY,\
FFT3DFilter(sigma=3, plane=2, bw=4, bh=4).VToY,\
FFT3DFilter(sigma=2, plane=0, bw=4, bh=4))

mt("Dehalo_alpha")

LimitedSharpenfaster(ss_x=2.0,ss_y=2.0,smode=3,strength=150,overshoot=7)

Lanczosresize(640,512)
400 mb - 9 hours of encoding without recompression!!! I want more

ORIGINAL MPEG FILE
x264 ENCODED FILE

Last edited by ficofico; 24th March 2007 at 21:20.
ficofico is offline   Reply With Quote
Old 24th March 2007, 21:12   #2  |  Link
Terranigma
*Space Reserved*
 
Terranigma's Avatar
 
Join Date: May 2006
Posts: 953
Sure. take a look at number 12.
Terranigma is offline   Reply With Quote
Old 24th March 2007, 21:19   #3  |  Link
ficofico
Registered User
 
Join Date: Nov 2006
Posts: 146
forget the best................. how I can improve my script for my mpeg video?
ficofico is offline   Reply With Quote
Old 24th March 2007, 21:25   #4  |  Link
Terranigma
*Space Reserved*
 
Terranigma's Avatar
 
Join Date: May 2006
Posts: 953
Quote:
Originally Posted by ficofico View Post
forget the best................. how I can improve my script for my mpeg video?
Well we can't really advise you if there's no sample. Each video is different, therefore I can't give you a straight answer.
I have a question for you first. Does mt("mcbob") actually do anything? I was told that it's not possible to use mt with mcbob
Anyways, you can try adding a stronger denoiser such as mvdegrain2 with a blksize of 4, (Note: this will slow encoding speed to a crawl).
Do you really need dehalo alpha when you got fft3d?
Terranigma is offline   Reply With Quote
Old 24th March 2007, 21:40   #5  |  Link
ficofico
Registered User
 
Join Date: Nov 2006
Posts: 146
Sample's are in my first script, and I've linked also a part of the encoded video with the code.
mcbob with mt is fastest for my procio, cpu usage go to 90%

Quote:
Do you really need dehalo alpha when you got fft3d?
Today 21:19
Is that I don't know!!! Usually i copy and paste script from threads and I watch the results, fft3d is a very good filter, but I don't know if this way to use is the better for my video, and if is possible to use with another filter with good results.
ficofico is offline   Reply With Quote
Old 24th March 2007, 21:45   #6  |  Link
Pookie
Registered User
 
Join Date: Apr 2005
Posts: 1,339
You can't MT on MCBob - it uses MVtools, which does not work with multithreading.
Pookie is offline   Reply With Quote
Old 24th March 2007, 21:48   #7  |  Link
Terranigma
*Space Reserved*
 
Terranigma's Avatar
 
Join Date: May 2006
Posts: 953
Quote:
Originally Posted by ficofico View Post
Sample's are in my first script, and I've linked also a part of the encoded video with the code.
mcbob with mt is fastest for my procio, cpu usage go to 90%

Is that I don't know!!! Usually i copy and paste script from threads and I watch the results, fft3d is a very good filter, but I don't know if this way to use is the better for my video, and if is possible to use with another filter with good results.
Yes, fft3d is very good. that's why I asked if you need dehalo alpha as well since it can do a better job at removing halos imo. I'll check out your samples, somehow i missed those links when reading your posts.
Terranigma is offline   Reply With Quote
Old 24th March 2007, 21:52   #8  |  Link
ficofico
Registered User
 
Join Date: Nov 2006
Posts: 146
But it work....... in megui I've seen that an avs file without mt on mcbob give me 50% cpu usage, with mt cpu usage is 70-80%

In this moment my cpu work with mt on mcbob, the script work, I don't know if it really work.
ficofico is offline   Reply With Quote
Old 24th March 2007, 21:59   #9  |  Link
Terranigma
*Space Reserved*
 
Terranigma's Avatar
 
Join Date: May 2006
Posts: 953
double fps for the x264 encode. add selecteven() after mcbob to retain the original fps.
e.g.
mt("mcbob").selecteven()

The 50fps clip is more fluid though. Looks like there's a lost of a lot of details as well. What went wrong there?
Terranigma is offline   Reply With Quote
Old 24th March 2007, 22:09   #10  |  Link
ficofico
Registered User
 
Join Date: Nov 2006
Posts: 146
I've tried your suggestion time ago, but video non look good, images aren't fluently. I've tried also tdeint and other deinterlacer but result aren't for me good, good image but not fluently images. mvbob and mcbob for me are the best, 50 fps but very good result ( my english is horrible!!!!! )
ficofico is offline   Reply With Quote
Old 24th March 2007, 22:19   #11  |  Link
Terranigma
*Space Reserved*
 
Terranigma's Avatar
 
Join Date: May 2006
Posts: 953
Quote:
Originally Posted by ficofico View Post
I've tried your suggestion time ago, but video non look good, images aren't fluently. I've tried also tdeint and other deinterlacer but result aren't for me good, good image but not fluently images. mvbob and mcbob for me are the best, 50 fps but very good result ( my english is horrible!!!!! )
They're not fluent, but that's how the source is. why should it be different? You're encoding too many frames. Quality will be lower because of that. But to each their own, I need an expert telling you why encoding useless frames is a bad idea. Maybe you'll think twice about that the next time
Terranigma is offline   Reply With Quote
Old 24th March 2007, 22:28   #12  |  Link
ficofico
Registered User
 
Join Date: Nov 2006
Posts: 146
Source looks good because I use pure video decoder that is incredible, excellent images and fluent video. If I watch the file with media player classic or videolan, with deinterlacer, video became non fluently, and a football match with this "look" is horrible. To put into an mkv container with x264 video, I need to deinterlace, but I want that video became fluently.
ficofico is offline   Reply With Quote
Old 24th March 2007, 23:45   #13  |  Link
Didée
Registered User
 
Join Date: Apr 2002
Location: Germany
Posts: 5,389
@ ficofico:

When using MCbob or MVbob, do not use any MT filters on these bobbers. In a nutshell - IF you do so, then internally something is going terribly wrong. It doesn't help that it runs faster, since the results will be of much lower quality, compared to not using MT.


@ Terranigma:

Quote:
They're not fluent, but that's how the source is. why should it be different? You're encoding too many frames. Quality will be lower because of that. But to each their own, I need an expert telling you why encoding useless frames is a bad idea.
That's nonsense, and
Quote:
Maybe you'll think twice about that the next time
is *your* task.

True interlaced video contains the double amount of field-based temporal information. Bobbers convert those fields to full frames. There are no "useless" frames.
Sure you'll need a higher bitrate when compressing a bobbed stream, because the framecount was doubled, compaired to simple-rate progressive. However, if one can afford the higher bitrate, then keeping the full doubled framerate is definetly preferred.

(Wrapping your statement into the equivalent of the spatial domain, it would mean that keeping HD resolution would be useless, and always shrinking to tiny SD resolution would be better, because the big resolution is useless. That's bullsh*t, isn't it?)
__________________
- We´re at the beginning of the end of mankind´s childhood -

My little flickr gallery. (Yes indeed, I do have hobbies other than digital video!)
Didée is offline   Reply With Quote
Old 25th March 2007, 01:15   #14  |  Link
Terranigma
*Space Reserved*
 
Terranigma's Avatar
 
Join Date: May 2006
Posts: 953
Quote:
Originally Posted by Didée View Post
(Wrapping your statement into the equivalent of the spatial domain, it would mean that keeping HD resolution would be useless, and always shrinking to tiny SD resolution would be better, because the big resolution is useless. That's bullsh*t, isn't it?)
There's actually a thread here about large res vs. small res, don't know if you've seen it. if you haven't, you can find it Here. Are you shocked by the current poll standings?
Speaking of fps, i did find that the 50fps clip was smoother. The 25fps clip seem as if it was jerky. Looks like I got a lot to learn about fps :/
Terranigma is offline   Reply With Quote
Old 25th March 2007, 01:35   #15  |  Link
Alain2
Registered User
 
Join Date: May 2005
Posts: 236
Quote:
Originally Posted by Terranigma View Post
Yes, fft3d is very good. that's why I asked if you need dehalo alpha as well since it can do a better job at removing halos imo. I'll check out your samples, somehow i missed those links when reading your posts.
Well it all depends on what type of video... For real life video, I agree, I prefer fft3d internal dehalo, but it does not perform an as good job as dehalo_alpha, it decreases linearly the halo according to the strength of the halo and therefore residual halo is always there, very visible were halos were very strong ; raising too much the strength of the dehalo reduces the overall picture dynamic contrast (as you need to keep threshold low otherwise it does not catch the halos enough)...
On animation though I much prefer dehalo_alpha, it's much more performant and the artefacs created are not as bad of a problem as on real life video imo.
Alain2 is offline   Reply With Quote
Old 25th March 2007, 10:53   #16  |  Link
ficofico
Registered User
 
Join Date: Nov 2006
Posts: 146
Ok, thanks for your suggestion!!!

My new script will be :

Code:
DGDecode_mpeg2source("K:\Satellite\prove\prove\calcio.d2v",info=3)
ColorMatrix(hints=true)
mvbob
YToUV(FFT3DFilter(sigma=3, plane=1, bw=32, bh=32).UToY,\
FFT3DFilter(sigma=3, plane=2, bw=32, bh=32).VToY,\
FFT3DFilter(sigma=2, plane=0, bw=32, bh=32))
YToUV(FFT3DFilter(sigma=3, plane=1, bw=4, bh=4).UToY,\
FFT3DFilter(sigma=3, plane=2, bw=4, bh=4).VToY,\
FFT3DFilter(sigma=2, plane=0, bw=4, bh=4))
Dehalo_alpha()
mt("LimitedSharpenfaster(ss_x=2.0,ss_y=2.0,smode=3,strength=150,overshoot=7)")
Lanczosresize(640,512)
mcbob without mt is impossible to use!!!!

Any other suggestion, related to my specific video?
ficofico is offline   Reply With Quote
Old 25th March 2007, 13:13   #17  |  Link
foxyshadis
ангел смерти
 
foxyshadis's Avatar
 
Join Date: Nov 2004
Location: Lost
Posts: 9,558
I wonder how this ugly ytouv fft3d business started spreading. You should really replace
Code:
YToUV(FFT3DFilter(sigma=3, plane=1, bw=32, bh=32).UToY,\
FFT3DFilter(sigma=3, plane=2, bw=32, bh=32).VToY,\
FFT3DFilter(sigma=2, plane=0, bw=32, bh=32))
YToUV(FFT3DFilter(sigma=3, plane=1, bw=4, bh=4).UToY,\
FFT3DFilter(sigma=3, plane=2, bw=4, bh=4).VToY,\
FFT3DFilter(sigma=2, plane=0, bw=4, bh=4))
with
Code:
FFT3DFilter(sigma=2, plane=0, bw=32, bh=32)
FFT3DFilter(sigma=2, plane=0, bw=4, bh=4)
FFT3DFilter(sigma=3, plane=3, bw=32, bh=32)
FFT3DFilter(sigma=3, plane=3, bw=4, bh=4)
just so you can read them. And since I know you just copied them from somewhere, you should load your script into avsp, turn them into sliders, and play around with them - tune them to your content, so that you don't smooth too much or too little.

Doubled-up fft3d with different block sizes is rarely necessary, and slows things down quite a bit. Even though fft3d is threaded, you can also just wrap the whole block in mt:
Code:
mt("""
FFT3DFilter(sigma=2, plane=0, bw=32, bh=32)
FFT3DFilter(sigma=2, plane=0, bw=4, bh=4)
FFT3DFilter(sigma=3, plane=3, bw=32, bh=32)
FFT3DFilter(sigma=3, plane=3, bw=4, bh=4)
Dehalo_alpha()
LimitedSharpenfaster(ss_x=2.0,ss_y=2.0,smode=3,strength=150,overshoot=7)
""")
Otherwise I can't yet offer specific suggestions, as it's still downloading.
foxyshadis is offline   Reply With Quote
Old 25th March 2007, 13:17   #18  |  Link
foxyshadis
ангел смерти
 
foxyshadis's Avatar
 
Join Date: Nov 2004
Location: Lost
Posts: 9,558
Quote:
Originally Posted by Terranigma View Post
There's actually a thread here about large res vs. small res, don't know if you've seen it. if you haven't, you can find it Here. Are you shocked by the current poll standings?
Speaking of fps, i did find that the 50fps clip was smoother. The 25fps clip seem as if it was jerky. Looks like I got a lot to learn about fps :/
People here are bitrate misers, the home of the 1-cd dvds and 1-dvd hds, but that's orthoganal to what Didée asked. Higher framerates are definitely harder to get playing smoothly, though, which is why I rarely bother even when the source could use it.
foxyshadis is offline   Reply With Quote
Old 25th March 2007, 17:54   #19  |  Link
Didée
Registered User
 
Join Date: Apr 2002
Location: Germany
Posts: 5,389
Quote:
Originally Posted by ficofico
mcbob without mt is impossible to use!!!!
Then don't.

Once more:
- MVTools do not work correctly with MT.
- MCBob & MVBob do use MVTools.

The conclusion is obvious.


Quote:
Originally Posted by Terranigma
There's actually a thread here about large res vs. small res, don't know if you've seen it. if you haven't, you can find it Here. Are you shocked by the current poll standings?
Sure I have seen it. If I'm shocked in any way, then by the silliness of the poll ... the Question "HiRes/LowQ vs. LowRes/HiQ" is plain bollocks. A poll "Do you prefer a yellow banana or a green apple" would be about as significant...
Plus, it has nothing to do with the comparison I tried to make. You're distracting.


Quote:
Originally Posted by foxyshadis
Higher framerates are definitely harder to get playing smoothly, though, which is why I rarely bother even when the source could use it.
Sure, but not that hard. If you're used to play 1920ish HD content smoothly, there should be no problem with playing 720 50/60p content smoothly.
__________________
- We´re at the beginning of the end of mankind´s childhood -

My little flickr gallery. (Yes indeed, I do have hobbies other than digital video!)
Didée is offline   Reply With Quote
Old 25th March 2007, 19:48   #20  |  Link
foxyshadis
ангел смерти
 
foxyshadis's Avatar
 
Join Date: Nov 2004
Location: Lost
Posts: 9,558
Who says I can get 1920 playing smoothly? (Lately even standard DVD playing with subtitles has been causing nasty interactions on my system, and tracking them down has been a huge pain. I've avoided watching much lately thanks to that.) If you don't try to push the filters, and have the power and tv for it, it's definitely liquid-smooth though.
foxyshadis is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 05:37.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.