Log in

View Full Version : Buffer Underflow Violations in AVINaptic


mozzle
1st July 2008, 21:17
Hello.

I recently discovered the AVINaptic tool and have been using it to check my DVD to AVI backups. I seem to be having issues with "buffer underflow." I've read posts that reference this issue and from what I gather it has something to do with exceeding the combined maximum bitrate of video and audio which is apparently around 10000kbps (please correct me if I'm wrong.)

Anyway, I'm nowhere close to that maximum as you can see by the AVINaptic results below. I'm pretty new to this and given that the bitrate does not appear to exceed the maximum, I'm at a loss as to why I'm getting the overruns (and what, if any, detrimental impact this is having on my encodes.) They look okay to me, but who knows? I have done five backups so far but all have resulted in some instances of overrun. This was the first that reported "too many violations". One thing I noticed was that for some of my encodes, AVINaptic displays the Container type as "AVI OpenDML" and sometimes as "AVI OpenDML indexes multi-chunks (*) rec-lists (*)". I'm not sure if this has anything to do with it.

My process:
1) rip DVD with DVD Decrypter
2) create D2V with DGIndex
3) Create AVS script
4) Encode and mux in MeGUI

By the way, I am using the "Advanced Simple @ L5" profile setting in AVINaptic.

Here is the AVINaptic report:

[ About file ]

Name: final.avi
Date: 1/07/2008 09:41:34
Size: 1,426,967,434 bytes (1360.862 MB)

[ Generic infos ]

Play duration: 01:43:12 (6192.222759 s)
Container type: AVI OpenDML indexes multi-chunks (*) rec-lists (*)
Number of streams: 2
Type of stream nr. 0: video
Type of stream nr. 1: audio {final}
Audio streams: 1
ISFT: AVI-Mux GUI 1.17.7, Aug 8 2006 20:59:17
JUNK:

[ Relevant data ]

Resolution: HIGH (704 x 384)
Width: multiple of 32 (GOOD)
Height: multiple of 32 (GOOD)
Average DRF quality: HIGH (2.482952)
Standard deviation quality: HIGH (0.499709)
Std. dev. weighted mean: HIGH (0.002598)

[ Video track ]

FourCC: xvid/XVID
Resolution: 704 x 384
Frame aspect ratio: 11:6 = 1.833333 (~1.85:1)
Pixel aspect ratio: 1:1 = 1
Display aspect ratio: 11:6 = 1.833333 (~1.85:1)
Framerate: 23.976043 fps
Number of frames: 148465 (212)
Stream size: 1,324,987,198 bytes
Bitrate: 1711.808181 kbps
Qf: 0.264103
Key frames: 2323 (0; 123; 125; 127; 129; ... 148366)
Null frames: 0
Min key int: 1
Max key int: 240
Avg key int: 63.910891
Delay: 0 ms

[ Audio track ]

Audio tag: 0x55 (MP3)
Bitrate (container): 128 kbps CBR
Channels (container): 2
Sample rate (container): 48000 Hz
Chunks: 12640
Stream size: 99,073,152 bytes
Preload: 216 ms
Max A/V diff: 4041 ms
Type: MPEG-1 Layer III
Encoder: LAME3.98a
MPEG frames: 258003
Play duration: 01:43:12 (6192.072 s)
Chunk-aligned: Yes
Emphasis: none
Mode: joint stereo
Delay: 0 ms

[ About MPEG4 encoding ]

User data: DivX503b1393p
User data: XviD0047
Packed bitstream: Yes
QPel: No
GMC: No
Interlaced: No
Aspect ratio: Square pixels
Quant type: MPEG custom (*)
Custom intra quant matrix:
8 10 11 12 12 13 14 15
10 11 12 13 13 15 15 16
11 12 12 14 15 15 16 17
12 13 14 15 15 16 17 18
12 13 15 15 16 17 18 19
13 15 15 16 17 18 19 19
14 15 16 17 18 19 19 20
15 16 17 18 19 19 20 20
Custom inter quant matrix:
10 10 11 12 12 13 14 15
10 11 12 13 14 14 15 16
11 12 12 14 14 15 16 17
12 13 14 14 15 16 17 18
12 14 14 15 16 17 18 19
13 14 15 16 17 18 19 20
14 15 16 17 18 19 20 20
15 16 17 18 19 20 20 20
Number of frames: 148465
Drop/delay frames: 0
Corrupted frames: 0

I-VOPs: 2323 ( 1.565 %)
P-VOPs: 74442 ( 50.141 %) #############
B-VOPs: 71699 ( 48.294 %) ############
S-VOPs: 0 ( 0.000 %)
N-VOPs: 1 ( 0.001 %)

Max consecutive B-VOPs: 1

[ DRF analysis ]

Average DRF: 2.482952
Standard deviation: 0.499709
Max DRF: 3

DRF<2: 0 ( 0.000 %)
DRF=2: 76763 ( 51.705 %) #############
DRF=3: 71701 ( 48.295 %) ############
DRF>3: 0 ( 0.000 %)

I-VOPs average DRF: 2
I-VOPs std. deviation: 0
I-VOPs max DRF: 2

P-VOPs average DRF: 2.000026
P-VOPs std. deviation: 0.005183
P-VOPs max DRF: 3

B-VOPs average DRF: 3
B-VOPs std. deviation: 0
B-VOPs max DRF: 3

[ Profile compliancy ]

Profile to check: Advanced Simple @ L5
Resolution: Ok
Framerate: Ok
Buffer underflow: 00:18:09 (frame 26105)
Buffer underflow: 00:18:09 (frame 26112)
Buffer underflow: 00:18:10 (frame 26125)
Buffer underflow: 00:18:10 (frame 26137)
Buffer underflow: 00:18:19 (frame 26357)
Buffer underflow: 00:18:20 (frame 26364)
Buffer underflow: 00:19:06 (frame 27475)
Buffer underflow: 00:25:39 (frame 36890)
Buffer underflow: 00:25:39 (frame 36893)
Buffer underflow: 00:25:39 (frame 36895)
Buffer underflow: 00:25:39 (frame 36897)
Buffer underflow: 00:25:39 (frame 36900)
Buffer underflow: 00:25:39 (frame 36902)
Buffer underflow: 00:25:39 (frame 36905)
Buffer underflow: 00:25:39 (frame 36908)
Buffer underflow: 00:25:39 (frame 36910)
Buffer underflow: 00:25:40 (frame 36913)
Buffer underflow: 00:30:48 (frame 44297)
Buffer underflow: 00:31:06 (frame 44729)
Buffer underflow: 00:41:26 (frame 59608)
Error: Too many violations

This report was created by AVInaptic (18-11-2007) on 1 lug 2008, h 09:58:43

And, here is my AVS script:

LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\mt_masktools-26.dll")
Import("C:\Program Files\AviSynth 2.5\plugins\FastDegrain.avs")
DGDecode_mpeg2source("C:\VIDEO_TS\rip.d2v",info=3)
ColorMatrix(hints=true)
crop(0,0,718,476)
LanczosResize(704,384)
FastDegrain()

Any explanations and/or guidance for eliminating these overruns would be greatly appreciated. Let me know if you need more info.

Thanks!

Dark Shikari
1st July 2008, 21:24
Buffer underflows are not at all important unless you're intending to play the file on a hardware player.

mozzle
1st July 2008, 21:40
Thanks for the quick reply.

Supposing I did want to play the AVIs on a standalone player, what effect will these overruns have on my ability to do so?

Also, if this will hinder playback on standalones, is there a method for avoiding the overruns?

Thanks again.

setarip_old
1st July 2008, 22:28
Hi!Supposing I did want to play the AVIs on a standalone player, what effect will these overruns have on my ability to do so?To find out with certainty, burn this .AVI to a disc and play it on your standalone (presuming the player is normally capable of playing such an XviD-compressed .AVI)

mozzle
1st July 2008, 23:11
Thanks setarip_old


I thought of that. Unfortunately I previously discovered my current standalone doesn't support custom matrices. Suffice it to say, I am in the market for a new standalone (looking at the Philips DVP5960 by the way.)

I guess I'm looking for more info about what causes the overruns and how to avoid them if possible.

foxyshadis
4th July 2008, 01:22
Buffer underflow means that the bitrate at that point is too high for too long, and that a player that strictly follows the profile will have problems playing it in those areas. (Usually a skip, some players just freeze.) The buffer is the amount of memory the device has available, and underruns are related to how quickly it can read and decode the video. The most important thing to do is to set AVInaptic for the correct profile for your player - it most likely isn't advanced simple @ any level, which are standard levels, since every divx player has its own quirks. There's technical information on some of the chipsets in the hardware players forum stickies.

If you do have buffer underruns relative to your player's actual buffer, you have to live with the skips or re-encode to the player's profile (celtic druid's xvid builds have the most profiles, or xvid encraw lets you specify custom buffer settings on the commandline). Later mediatek players like the DVP5960 have no practical restrictions on the buffer.

mozzle
5th July 2008, 21:07
Hey there.

Thanks a lot for the explanation and for the tip on what profile settings to use in AVINaptic. My current standalone (Philips DVP642) has the ESS Vibratto II chip set; hence the limitations.

I sure upgrading to something like the DVP5960 will relieve most of the issues.

Thanks again for taking the time. I'm won't stress over the overrruns.