Quantcast CQ vs. CQ_VBR ... Very Interesting... - Page 12 - digitalFAQ.com Forums [Archives]
Go Back    digitalFAQ.com Forums [Archives] > Video Production Forums > Avisynth Scripting

Reply
 
LinkBack Thread Tools
  #221  
12-30-2002, 04:00 PM
black prince black prince is offline
Free Member
 
Join Date: Jul 2002
Posts: 1,224
Thanks: 0
Thanked 0 Times in 0 Posts
@Kwag,

Well I tried avs with Blockbuster dither and without. I used "avscompare" just
to have a visual look. For starters dither added about 6MB to the
test file. The script without dither looked better than the one with it.
I'm not sure what it's suppose to do to picture quality, but it reduced
colour richiness, gave the picture a hazy apperance, and almost
appeared like a smoother filter. Maybe settings need further tweaking.

Converted KVCDx3 CQ_VBR to CQ using the GOP 1-12-2-1-24 and the KVCD
Notch (Beta-2) Q-Matrix. It's the "Bomb" as hip hoppers would save or
"PHAT". File size has decreased so CQ was set higher. This may
be the best combination for 1 or 2 CD's with better picture quality
than (if that were possible) 704x480 resolution. I viewed 704x480
vs 528x480 with "avscompare" at the same CQ of 70 and there was
no doubt that 528x480 is superior with a smaller file to boot.

-black prince
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
  #222  
12-30-2002, 04:02 PM
SansGrip SansGrip is offline
Free Member
 
Join Date: Nov 2002
Location: Ontario, Canada
Posts: 1,135
Thanks: 0
Thanked 0 Times in 0 Posts
Quote:
Originally Posted by kwag
Hey SansGrip Tick, Tick, Tick, Tick
heheh sorry, real world intervened for a while (grocery shopping, etc.). I've finished all the old matrix samples, all the CQ_VBR new matrix samples, 352x240 CQ new, and 352x480 CQ new. Now I'm doing 528x480 CQ new and then all that remains is 704x480 CQ new.

After that I'll post basic stats (file sizes, quality settings etc.) and will start my visual comparisons...

Reply With Quote
  #223  
12-30-2002, 04:03 PM
SansGrip SansGrip is offline
Free Member
 
Join Date: Nov 2002
Location: Ontario, Canada
Posts: 1,135
Thanks: 0
Thanked 0 Times in 0 Posts
Quote:
Originally Posted by black prince
For starters dither added about 6MB to the
test file.
That's an awful lot. What settings are you using?
Reply With Quote
  #224  
12-30-2002, 04:04 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
Quote:
Originally Posted by kwag
Hey SansGrip Tick, Tick, Tick, Tick

Are the results or are they :P

-kwag
Yeah man!
That's the most expected answer... CQ_VBR with Blockbuster or CQ without Blockbuster?
Which will give a better encode? I mean, by now, which will give more viewing pleasure?
Reply With Quote
  #225  
12-30-2002, 04:09 PM
SansGrip SansGrip is offline
Free Member
 
Join Date: Nov 2002
Location: Ontario, Canada
Posts: 1,135
Thanks: 0
Thanked 0 Times in 0 Posts
Quote:
Originally Posted by kwag
DON'T USE WMP
You can use WMP if you install the Ligos MPEG decoder DirectShow filter. It'll rescale to 4:3 like WinDVD does.
Reply With Quote
  #226  
12-30-2002, 04:12 PM
black prince black prince is offline
Free Member
 
Join Date: Jul 2002
Posts: 1,224
Thanks: 0
Thanked 0 Times in 0 Posts
@SansGrip,

SansGrip wrote:
Quote:
That's an awful lot. What settings are you using?
LegalClip()
LanczosResize(672,44
FluxSmooth()
Blockbuster(method="dither", detail_min=1, detail_max=10, variance=1)
AddBorders(16,16,16,16)
LegalClip()
Sampler()


Got dither settings from Kwag:

Without dither test file size for CQ 50 704x480 = 21,896,415
With dither test file size for CQ 50 704x480 = 27,158,387

-black prince
Reply With Quote
  #227  
12-30-2002, 04:32 PM
SansGrip SansGrip is offline
Free Member
 
Join Date: Nov 2002
Location: Ontario, Canada
Posts: 1,135
Thanks: 0
Thanked 0 Times in 0 Posts
Quote:
Originally Posted by black prince
Blockbuster(method="dither", detail_min=1, detail_max=10, variance=1)
These settings shouldn't produce such a huge increase in file size. Are you sure the presence/absence of Blockbuster is the only variable?

Quote:
Without dither test file size for CQ 50 704x480 = 21,896,415
With dither test file size for CQ 50 704x480 = 27,158,387
Very strange. Try with variance=0.7.
Reply With Quote
  #228  
12-30-2002, 04:40 PM
SansGrip SansGrip is offline
Free Member
 
Join Date: Nov 2002
Location: Ontario, Canada
Posts: 1,135
Thanks: 0
Thanked 0 Times in 0 Posts
All samples are 11.4mb, new GOP, min bit rate 400. CQ_VBR mode has a dither variance of 1, CQ mode with no dither.

Old matrix

352x240 CQ 100
352x240 CQ_VBR 54
352x480 CQ 78.85
352x480 CQ_VBR 15.6
528x480 CQ 69.95
528x480 CQ_VBR 9.3
704x480 CQ 56.8
704x480 CQ_VBR 6.4

New matrix

352x240 CQ 80.2
352x240 CQ_VBR 36
352x480 CQ 70
352x480 CQ_VBR 15.2
528x480 CQ 56.8
528x480 CQ_VBR 9.25
704x480 CQ 45
704x480 CQ_VBR 6.4

Some interesting results there (e.g. the new matrix causes a much more significant decrease in CQ quality level than CQ_VBR quality level).

I'm going to start the visual comparisons now (unfortunately kwag's DirectShowSource method doesn't work for me, so I'll have to convert to AVI still. It'll take some time ).

If anyone is interested in seeing specific samples, I can put them on the web. I was thinking about putting all of them up, but I think 183mb might be a little too much for people to download .
Reply With Quote
  #229  
12-30-2002, 04:42 PM
apoc apoc is offline
Free Member
 
Join Date: Dec 2002
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
I've just encoded a low action scene with old and new matrix (1 mn 10 ) 544x576 :

CQ 58 - KVCD matrix : 7369021 bytes
CQ 58 - KVCD NOTCH beta2 : 9330948 bytes

The script I used :

LegalClip()
Crop(8, 74, 692, 42
BilinearResize(512, 320)
FluxSmooth()
AddBorders(16,128,16,12
LegalClip()

--
apoc
Reply With Quote
  #230  
12-30-2002, 05: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
Quote:
Originally Posted by SansGrip

You can use WMP if you install the Ligos MPEG decoder DirectShow filter. It'll rescale to 4:3 like WinDVD does.
AH!, ok, I'll get that

-kwag
Reply With Quote
  #231  
12-30-2002, 05:52 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 apoc
I've just encoded a low action scene with old and new matrix (1 mn 10 ) 544x576 :

CQ 58 - KVCD matrix : 7369021 bytes
CQ 58 - KVCD NOTCH beta2 : 9330948 bytes

The script I used :

LegalClip()
Crop(8, 74, 692, 42
BilinearResize(512, 320)
FluxSmooth()
AddBorders(16,128,16,12
LegalClip()

--
apoc
That would be about the correct sizes, because you left CQ the same for both matrixes. As SansGrip just mentioned before: "The new matrix causes a much more significant decrease in CQ quality level than CQ_VBR quality level. "

That is for the same reference file size.

-kwag
Reply With Quote
  #232  
12-30-2002, 06:18 PM
SansGrip SansGrip is offline
Free Member
 
Join Date: Nov 2002
Location: Ontario, Canada
Posts: 1,135
Thanks: 0
Thanked 0 Times in 0 Posts
Ok, all 16 samples have now been magically transformed into video-only system streams, then into a .bin file, and are currently residing on a shiny piece of metal-covered plastic in a case on my desk.

As soon as the kids are in bed I'll stick it in my standalone and watch them all on TV. After that, I will know. I hope .

I did do some visual compares in VirtualDub and there were some noticible differences between the old and new matrices. Sometimes things looked better with the new matrix, and sometimes with the old. The good news is that on balance I'd say more things looked better with the new matrix than the old...

The bad news is that because of the significant reduction in CQ quality level, fast-motion scenes tended to be quite a bit blockier with the new matrix than with the old. Bear in mind these weren't DCT blocks, they were macroblocks introduced because of insufficient bits to describe the motion.

It's a tough call as to whether the improvements seen with the new matrix outweigh the difference in CQ quality levels and hence the increased occurance of macroblocks.

As for whether CQ_VBR-with-dither is better than CQ-without-dither, when watching on my monitor I'd say that the former is better in all resolutions. However, there's a huge difference between watching on a monitor and watching on a TV, so I'm going to keep my mind open until I can see all the clips on the big screen.

That's the status so far. I hope someone else duplicates at least part of the testing I've done here, otherwise my main concern will be that it's totally a judgement call on my part. I'd rather have input from others as well.
Reply With Quote
  #233  
12-30-2002, 06:28 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'm 8 minutes to go on a 11 hour 2-pass VBR encode with the new matrix, and then I'll compare the CQ I did yesterday, also with the new matrix. BTW SansGrip, If you do notice more blocks with the new matrix on high action scenes, then maybe the notch (BETA-1) is the way to go, because that one has the non-intra modified and is basically the original KVCD matrix with the small "notch" modification. The BETA-2 hast all 16's on intra.
I'll also report, hopefully with some screenshots, a couple of samples from the 2-pass and CQ.

-kwag
Reply With Quote
  #234  
12-30-2002, 06:32 PM
SansGrip SansGrip is offline
Free Member
 
Join Date: Nov 2002
Location: Ontario, Canada
Posts: 1,135
Thanks: 0
Thanked 0 Times in 0 Posts
Quote:
Originally Posted by kwag
I'm 8 minutes to go on a 11 hour 2-pass VBR encode with the new matrix, and then I'll compare the CQ I did yesterday, also with the new matrix.
Sounds good -- will be interesting to see if what is theoretically the highest quality mode (2-pass) really matches (or even exceeds ) our CQ and prediction .

Quote:
BTW SansGrip, If you do notice more blocks with the new matrix on high action scenes, then maybe the notch (BETA-1) is the way to go
Ah, you mean make another 8 encodes with beta-1? hehe yep, I'll do that too. Probably tomorrow, because I've spent far too much time in front of this machine already today .

I think the all-16s non-intra-frame matrix is probably the culprit wrt the much larger file sizes. It'll compress much less than the KVCD version.

Quote:
I'll also report, hopefully with some screenshots, a couple of samples from the 2-pass and CQ.
I'm looking forward to that .
Reply With Quote
  #235  
12-30-2002, 06:59 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
As usual, Murphy strikes again . My 2-pass file size came out to 646,240KB and the CQ size is 690,770KB .
The predicted size was correct for CQ, so I screwed up somewhere on the average bit rate calc for 2-Pass. Now I could re-calculate a lower CQ value and encode just some portions for comparison, targeting CQ for the size that the 2-pass came out. But I'm not sure that will be necessary, because the difference in quality is just bizarre I'll let you guys decide if you want me to encode again with CQ, because I think that the difference will just be a little better for 2-pass. Encoding times were 11 hours for 2-pass and ~5 hours for CQ. You decide:

Script used was this:

LoadPlugin("C:\encoding\MPEG2DEC.dll")
LoadPlugin("C:\encoding\fluxsmooth.dll")
LoadPlugin("C:\encoding\sampler.dll")
LoadPlugin("C:\encoding\blockbuster.dll")
LoadPlugin("C:\encoding\legalclip.dll")
mpeg2source("K:\K19\VIDEO_TS\k19.d2v")
LegalClip()
LancZosResize(496,336)
FluxSmooth()
Blockbuster(method="dither", detail_min=1, detail_max=10, variance=1)
AddBorders(16,72,16,72)
LegalClip()

Images are blown up to enhance details.

Reply With Quote
  #236  
12-30-2002, 07:48 PM
gonzopdx gonzopdx is offline
Free Member
 
Join Date: Dec 2002
Location: Corvallis, OR
Posts: 86
Thanks: 0
Thanked 0 Times in 0 Posts
the 2-pass kinda looks like poo
Reply With Quote
  #237  
12-30-2002, 08:29 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 gonzopdx
the 2-pass kinda looks like poo
I would say more like poopoo
I'm going to re-encode that portion after I run prediction to target CQ for the same size that the 2-pass came out. Just for curiosity .
I'll post result in a little while.

-kwag
Reply With Quote
  #238  
12-30-2002, 08:48 PM
SansGrip SansGrip is offline
Free Member
 
Join Date: Nov 2002
Location: Ontario, Canada
Posts: 1,135
Thanks: 0
Thanked 0 Times in 0 Posts
Quote:
Originally Posted by kwag
I would say more like poopoo
It's certainly poo-esque. Well, that answered that question .
Reply With Quote
  #239  
12-30-2002, 09:02 PM
Daagar Daagar is offline
Free Member
 
Join Date: May 2002
Posts: 158
Thanks: 0
Thanked 0 Times in 0 Posts
Just for the record, back a few months ago when people were duking it out on vcdhelp.com about how 'kvcd sucked' and '2-pass' was the only way to go, I tried my darnedest to use 2-pass mode and never came up with anything better than what Kwag just showed us. It always came out horrible. Granted, this was before all the kvcd matrixes and file prediciton, but it doesn't look like things have changed!

I converted a 2-disc SVCD file the other night to a 1-disc KVCD (352x480) using the standard CQ/CQ_VBR methods and SansGrip filters and the results were spectacular. I prefer using CQ_VBR because it takes _much_ less effort to narrow down to the correct CQ_VBR value. As others have mentioned, CQ values over 80 skew the prediction formulas quite a bit.
Reply With Quote
  #240  
12-30-2002, 09:14 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 guys ,
I created the same CQ sample by lowering the CQ value re-calculated with prediction to target the file size that the 2-pass VBR made. The original CQ value was 53.7 and the new one is 46. Here's the result, still with an advantage for CQ over 2-pass VBR

Reply With Quote
Reply




Similar Threads
Thread Thread Starter Forum Replies Last Post
Avisynth: Interesting results with YlevelsS supermule Avisynth Scripting 2 08-06-2006 11:59 PM
Avisynth: Interesting ASharp phenomenon... audioslave Avisynth Scripting 12 10-23-2003 06:36 AM
Interesting info about the Luminance Level in CCE digitalize Video Encoding and Conversion 0 04-28-2003 12:29 PM
A couple of interesting links.. kwag Off-topic Lounge 0 12-31-2002 03:47 PM
KVCD: Interesting poll found kwag Video Encoding and Conversion 2 12-31-2002 02:44 AM




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