Quantcast Mvbr one-Pass Calculation. "a New Approach" - digitalFAQ.com Forums [Archives]
  #1  
03-07-2003, 03:51 PM
kwag kwag is offline
Free Member
 
Join Date: Apr 2002
Location: Puerto Rico, USA
Posts: 13,537
Thanks: 0
Thanked 0 Times in 0 Posts
I've been busy the last 3 days fiddling with file prediction, and I found something very interesting in TMPEG that we hadn't tried before. Deep in TMPEG, there's an option where you can force TMPEG to encode at a specified average bit rate So basically, it will encode at a specified "Average" instead of a specified "Quality" as we have been encoding. This could be an alternate method, and might be very accurate too. After experimenting with this, I've made some tests, and I'm very surprised at the results and I developed a small calculator with some factors taken into consideration, and here it is with a full explanation

First, download this: http://www.kvcd.net/kvcdcalc.exe ( Small, about ~12KB ). Here's a screenshot of the program:



Now Run "SwiftAVS" or "MovieStacker" and create your favorite script as usual.
Now take a look at the suggested average bit rate in MovieStacker.

On the KVCD MVBR Calculator, adjust the top track bar and select your resolution. Then enter the average bit rate that you got from MovieStacker and press "Calculate"

Now here comes the fun part :
Open TMPEG and change the encoding mode from CQ to MVBR, and enter the MAX bit rate and MIN bit rate that the calculator gave you in the step above. Make sure you set the P and B spoilage to 0
Here a screenshot of what it should look like:



Next go to TMPEG's "GOP Structure" tab an click on "Force picture setting" and click on the "Settings" right beside it. Like this:



You'll get a screen like this:



Right click on the line that says so , and you'll get this screen:



Then select "Bitrate" and you get this:



And enter the "New ABR" (New Average Bit Rate) value suggested by the KVCD MVBR Calculator. DO NOT enter the average bit rate suggested by MovieStacker or other programs. The calculator already takes into consideration an offset, which based on my tests, is close to the actual and final average bit rate. So take the number calculated from the "New ABR" field and enter it on the "Set bitrate" field.

You're done Start your encode using "High quality". Read notes below.

Notes:

This is still VERY experimental, and more tests have to be conducted. I have had great results with three movies, one targeting less than 1% final file size, and another one around -6% to -7%. What I did find is that no matter what filters I use, TMPEG compensates and produces the same output file size ( At least on the limited tests I have done )
So if this does work for everyone, I can adjust the calculator to take other factors into consideration. For example, I get a different file size if I encode as "High quality" than if I encode as "Motion estimation fast". So version 0.36 of the calculator will add a selector, where you can choose your encoding mode. I just need more people to test this, and if your file size was way off, then tell me here what was the difference from the actual file size to the one suggested by MovieStacker. Also tell me what encoding mode you used. Ex: "Normal", "High quality", 'Fast", etc.

I still have to do some quality comparison between this mode and CQ mode. As far as I can tell looking at my monitor on what I have encoded, It looks the same as my CQ encodes.

Edit:
Please try this ONLY at 352x240(28.
I have not done that many tests with higher resolutions, so the ABR calculations will probably be off.

Edit: Higher resolutions WILL NOT WORK with this method. Use only at 352x240 or 352x288.

Enjoy,
-kwag
Reply With Quote
Someday, 12:01 PM
admin's Avatar
Site Staff / Ad Manager
 
Join Date: Dec 2002
Posts: 42
Thanks: ∞
Thanked 42 Times in 42 Posts
  #2  
03-07-2003, 03:56 PM
CheronAph CheronAph is offline
Free Member
 
Join Date: Feb 2003
Location: Espoo, Finland
Posts: 494
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to CheronAph
Sounds interesting, I´ll try it when I got some time, propably many people will do the same...
Reply With Quote
  #3  
03-07-2003, 08:59 PM
muaddib muaddib is offline
Free Member
 
Join Date: Jun 2002
Location: São Paulo - Brasil
Posts: 879
Thanks: 0
Thanked 0 Times in 0 Posts
YEAH!
If this works, we can say "bye-bye" to all other kinds of prediction!

Great work kwag!
Reply With Quote
  #4  
03-07-2003, 09:05 PM
kwag kwag is offline
Free Member
 
Join Date: Apr 2002
Location: Puerto Rico, USA
Posts: 13,537
Thanks: 0
Thanked 0 Times in 0 Posts
Quote:
Originally Posted by muaddib
YEAH!
If this works, we can say "bye-bye" to all other kinds of prediction!
It's working great, but only at 352x240(28. TMPEG tries to keep the bit rate close to average, and doesn't let the bit rate fluctuate too much. It goes up to ~1300Kbps MAX, so it's no good for higher resolutions. However, it's excelent for 352x240(28
But I'm still working on it's limitations, so let's see if I can take the 352x240(28 cap off and go beyond that
Right now, this method should work great with KVCD_ULBR and KVCD_LBR, but NOT KVCD 352x240(28 PLUS, because that template is set to MAX=1,800Kbps and that bit rate will never be reached.

-kwag
Reply With Quote
  #5  
03-08-2003, 03:06 AM
Bud Bud is offline
Free Member
 
Join Date: Apr 2002
Location: Hawaii
Posts: 241
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to Bud
Kwag

Let see if I can follow using my best principal (KISS) and believe me this is the only I can follow. If I go beyond that I’m lost. For those that don’t know KISS – Keep It Simple Stupid ----Is what I use. An I keep telling myself to use the KISS system.

First I run the d2v through Moviestack, create the avs (I always start with the default templates). Then I get the average bit rate (My test gave me 880).

The rest I can follow. Now my question is after I set up TMPGEnc, I’m assuming that it will adjust the bit rate based on the template. So with this procedure I no longer have to worry about what the CQ is going to be.

I hope I got this right. I am running a test now on a 110 Min movie. Will keep you posted on the results. This jsut keeps getting better all the time.

Bud
Reply With Quote
  #6  
03-08-2003, 09:24 AM
kwag kwag is offline
Free Member
 
Join Date: Apr 2002
Location: Puerto Rico, USA
Posts: 13,537
Thanks: 0
Thanked 0 Times in 0 Posts
Quote:
Originally Posted by Bud
Kwag

Let see if I can follow using my best principal (KISS) and believe me this is the only I can follow. If I go beyond that I’m lost. For those that don’t know KISS – Keep It Simple Stupid ----Is what I use. An I keep telling myself to use the KISS system.
I use the same principle too
Quote:

First I run the d2v through Moviestack, create the avs (I always start with the default templates). Then I get the average bit rate (My test gave me 880).
So far, so good, but you must load the KVCD_LBR template for this method, or any other 352x240 template only. Not higher resolutions.
Quote:

The rest I can follow. Now my question is after I set up TMPGEnc, I’m assuming that it will adjust the bit rate based on the template. So with this procedure I no longer have to worry about what the CQ is going to be.
Not exactly!. You have to set the bit rates and the average bit rate that you get with the KVCD calculator in TMPEG. You don't use the default bit rates that are on the template, and you must change the encoding in the template from CQ to MVBR as in the screenshot.
Quote:

I hope I got this right.
Almost

-kwag
Reply With Quote
  #7  
03-08-2003, 01:33 PM
jorel jorel is offline
Invalid Email / Banned / Spammer
 
Join Date: Aug 2002
Location: Brasil - MG - third stone from the sun
Posts: 5,570
Thanks: 0
Thanked 0 Times in 0 Posts
Kwag,

why don't use the 480x480 feature?

thanks in advance!
Reply With Quote
  #8  
03-08-2003, 01:37 PM
Bud Bud is offline
Free Member
 
Join Date: Apr 2002
Location: Hawaii
Posts: 241
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to Bud
Kwag

Thanks...Hey at my age almost if good enough for me (I almost hit the toilet every time, at least that’s what my wife tells me).....looking forward to more testing....with the movies not the toilet......


Bud
Reply With Quote
  #9  
03-08-2003, 02:04 PM
kwag kwag is offline
Free Member
 
Join Date: Apr 2002
Location: Puerto Rico, USA
Posts: 13,537
Thanks: 0
Thanked 0 Times in 0 Posts
Quote:
Originally Posted by jorel
Kwag,

why don't use the 480x480 feature?

thanks in advance!
It only works with 352x240(28

-kwag
Reply With Quote
  #10  
03-08-2003, 02:10 PM
jorel jorel is offline
Invalid Email / Banned / Spammer
 
Join Date: Aug 2002
Location: Brasil - MG - third stone from the sun
Posts: 5,570
Thanks: 0
Thanked 0 Times in 0 Posts
Quote:
Originally Posted by kwag
Quote:
Originally Posted by jorel
Kwag,

why don't use the 480x480 feature?

thanks in advance!
It only works with 352x240(28

-kwag
hi again,Kwag

yes,but the control jump from 352x240 to 528x480 and no to 480x480.
in the future you don't want to use this resolution?

Reply With Quote
  #11  
03-08-2003, 02:58 PM
kwag kwag is offline
Free Member
 
Join Date: Apr 2002
Location: Puerto Rico, USA
Posts: 13,537
Thanks: 0
Thanked 0 Times in 0 Posts
Quote:
Originally Posted by jorel

yes,but the control jump from 352x240 to 528x480 and no to 480x480.
in the future you don't want to use this resolution?

Only if we're able to make this method work at higher resolutions

-kwag
Reply With Quote
  #12  
03-08-2003, 03:16 PM
jorel jorel is offline
Invalid Email / Banned / Spammer
 
Join Date: Aug 2002
Location: Brasil - MG - third stone from the sun
Posts: 5,570
Thanks: 0
Thanked 0 Times in 0 Posts
Quote:
Originally Posted by kwag
Quote:
Originally Posted by jorel

yes,but the control jump from 352x240 to 528x480 and no to 480x480.
in the future you don't want to use this resolution?

Only if we're able to make this method work at higher resolutions

-kwag
of course you can do it .
this forum make miracles!
Reply With Quote
  #13  
03-08-2003, 06:27 PM
Red-M Red-M is offline
Free Member
 
Join Date: Nov 2002
Posts: 20
Thanks: 0
Thanked 0 Times in 0 Posts
Yea, and Im always <<Watching>>
Reply With Quote
  #14  
03-08-2003, 06:50 PM
alfredini alfredini is offline
Free Member
 
Join Date: Dec 2002
Posts: 38
Thanks: 0
Thanked 0 Times in 0 Posts
OK... i have tried this with 2 Samples.
Both at the resolution 352x288.
Motion search precision: slow

The samples are a little smaller then predicted. 11,25MB:10,3MB and 11,06MB:10,8. But it seems to me that the MVBR gives me a better quality. Trying now on the complete movie.

Edit: finish. MVBR Calculator is not really hitting ABR. But you can use the Sampler() to be sure. So it is not a replacement for the predicting stuff. MVBR produces more "striped" blocks
Reply With Quote
  #15  
03-09-2003, 06:23 PM
alfredini alfredini is offline
Free Member
 
Join Date: Dec 2002
Posts: 38
Thanks: 0
Thanked 0 Times in 0 Posts
Hey... what happend... hasn't anybody other tried it yet?
Maybe i am wrong...
Last year i tried this MVBR. I used standard Matrix and "force picture type setting". I needed almost the same time to set the pictures as TMPGEnc needed to encode But the result was really amazing. It was really like a DVD
Reply With Quote
  #16  
03-09-2003, 11:45 PM
kwag kwag is offline
Free Member
 
Join Date: Apr 2002
Location: Puerto Rico, USA
Posts: 13,537
Thanks: 0
Thanked 0 Times in 0 Posts
Hi alfredini,

The problem with MVBR and the method I describe here, is that TMPEG clamps the MIN and MAX fluctuations close to average. But it's not wide enough to go to a high MAX on action scenes. So fast scenes look blocky. I haven't found a way around it, so we might as well stick to CQ with file prediction. Nothing beats that yet

-kwag
Reply With Quote
  #17  
03-10-2003, 08:41 PM
vhelp vhelp is offline
Free Member
 
Join Date: Jan 2003
Posts: 1,009
Thanks: 0
Thanked 0 Times in 0 Posts
hay kwag..

looks like nothing will ever beat CQ

Personall, I love using it. Thanks to you. And, in my best opinion,
CQ is as good as multi-pass (if bitrate min/max/CQ) are properly setup
for the encode. I can't ever see myself going back to 2-pass, though
I reailly used it, because I used to use CQ_VBR though it's good too.

Well, that was me beafing.
-vhelp
Reply With Quote
  #18  
06-02-2003, 03:17 PM
ezysk ezysk is offline
Free Member
 
Join Date: Apr 2003
Posts: 197
Thanks: 0
Thanked 0 Times in 0 Posts
Can this predict the final mpeg size? Be nice to know before you start encoding,also can this work within Tok?
Reply With Quote
  #19  
06-02-2003, 03:21 PM
kwag kwag is offline
Free Member
 
Join Date: Apr 2002
Location: Puerto Rico, USA
Posts: 13,537
Thanks: 0
Thanked 0 Times in 0 Posts
Hi ezysk,

This method (and old thread!) worked "so so", but only at 352x240. It was an experiment, and didn't work very well. There's nothing like CQ encoding. At least not yet

-kwag
Reply With Quote
  #20  
06-02-2003, 04:48 PM
ezysk ezysk is offline
Free Member
 
Join Date: Apr 2003
Posts: 197
Thanks: 0
Thanked 0 Times in 0 Posts
..problem is, there's a variety of prediction methods and tools on this site,so I was just kind of wondering,what and where would be the best place to start for a beginner like me
Reply With Quote
Reply




Similar Threads
Thread Thread Starter Forum Replies Last Post
""""""Por favor me ajude" ficoboy Conversão e Codificação de Vídeo (Português) 49 08-24-2004 05:35 PM
"""Legenda no virtualdub""" ficoboy Conversão e Codificação de Vídeo (Português) 6 08-06-2004 01:30 PM
Quais os codec's? """"""" ficoboy Conversão e Codificação de Vídeo (Português) 1 05-11-2004 10:14 AM
Como passar videos no formato "rm" e "rmvb&qu soultaker Conversão e Codificação de Vídeo (Português) 1 01-02-2004 04:35 PM
CQ con Tok "automatico" o CQ_VBR "manual" r1racing1 Convertir y Codificar Video (Español) 4 11-27-2003 05:14 PM

Thread Tools



 
All times are GMT -5. The time now is 11:38 PM  —  vBulletin © Jelsoft Enterprises Ltd