Personal View site logo
AVCHD maximum image quality settings and testing
  • 1002 Replies sorted by
  • I think it's a bug. Increasing overall bitrate didn't help. Lowering AQ helped. The issue goes away at AQ0. I've seen the patterns before. It happened in 66Mbps GOP6 and 88Mbps GOP6, too. 88Mbps GOP3 AQ3 didn't have any issue, but it failed high detail test.

    44Mbps GOP12 AQ3 is looking good. I frame size reaching 7Mbps. B & P frames looking "healthy". Good candidate for baseline 24L setting.
  • @stonebat - with that in mind would you recommend staying at gop 3 for now? Does AQ4 make a difference? It seemed to really up the bitrate overall for our last tests at 88Mbps.
  • So here is what I have tested so far.

    I tested the firmware without any changes against 42 mb/sec High and 24 mb/sec low settings for all of the Qauntizer settings.

    The only thing I varied between tests was the Quantizer. After I tested the default firmware I set the bit rates to 42 and 24 and started with a Quant of zero. Then I tested each Quant after that without changing any other setting and without adjusting the camera at all. I left all of the GOPs at their default firmware settings.

    I filmed the resolution chart with my 55mm F1.2 stopped way down to make sure it was sharp enough. It was probably somewhere around F2.8. The focus, ISO, WB, Shutter Speed, and lighting was fixed. I used an external video light to keep a constant light on the resolution chart. Since I had the light and faster lens I was able to hold the ISO to 160 the whole time even indoors.

    I wanted to know if increasing the Quant value would increase the bit rate. With the default firmware the bit rate was only 13.8 mb/sec for the 1080p resolution and 10.4 mb/sec for 720p. Interestingly the High and Low settings had the same bit rate for the default firmware across all resolutions with this relatively easy scene to process.

    As I increased the Quant value the bit rate also increased for each of the resolutions. However, the default firmware and the firmware with Quant = 0 had the same video bit rate even though the Quant = 0 setting had the bit rate value increased to 42 mb/sec. This is interesting because raising the bit rate value alone did not help at all with this relatively simple scene.

    Once I raised Quant to 1 the bit rate began to rise for all of the formats. For the 1080p High file it went from a low of 13.6(Quant = 0) through the following values 18.2(Quant = 1), 26.6(Quant = 2), 27.8(Quant = 3), 36.0(Quant = 4). All of the rest of the formats followed a similar pattern. The 1080p resolution always had the highest bit rate even though the 1080i resolution used the exact same settings with B-frames.

    However, I did notice one interesting thing. Once I got to the Quant value of 2(More to details) the 720p P frames took on an uneven cadence. They began to have one large P frame followed by one small P frame. This pattern continued all the way up to Quant = 4. None of the other resolutions exhibited this pattern but the other resolutions all use B-frames.

    I looked at all of the video files and I never could tell a difference in visual resolution at all. They all looked the same. I never expected it to affect resolution because even 12 mb/sec was probably plenty for this easy to process scene.

    In the end I settled on Quant = 4 for 1080p because I wanted to keep a very even bit rate across all scenes no matter what level of detail was in the scene. I choose Quant = 3 for 720p even though I had seen the uneven cadence for values of 2 or greater. I did this because I lowered the GOP to 12 for 720p and 1080i. After further testing I determined that this lowering of the GOP eliminated the uneven cadence. However, I have not determined if the uneven cadence is actually a bad thing. It may be that it was uneven but still higher.

    So in the end with a few simple changes I was able to get what I think is completely stable(even with a slow class 6 Eye-Fi card) video with extremely high detail and a near constant bit rate with an even cadence.

    I tested the 720p GOP = 12 by shaking the camera violently with a very detailed scene. It definitely broke the codec. Several scenes showed portions of the scene in perfect focus with no Mud while the lower parts of the frame showed sever Mud and blurring with Macro Blocks. However, I never shoot like this in real life so my settings did not attempt to eliminate this.

    Here is a sample 1080p Quant 4 video. This is straight out of the camera and you can download the original on Vimeo.



    Here is a nice little moon video I just shot as well.



    Please note that the settings file below also includes changes to the MJPEG settings. I raised the bit rate for 720p and 480p and I increased the resolution of 480p.
    720p Quant = 4.jpg
    1600 x 900 - 490K
    720p Quant = 1.jpg
    1600 x 900 - 481K
    720p Quant = 3 GOP = 12.jpg
    1600 x 900 - 503K
    Top Half OK bottom compression artifacts.png
    1280 x 720 - 2M
    Very high Detailed 1080p Quant 4 GOP 12.jpg
    1600 x 900 - 522K
    seth 42 mb-sec Quant 4 and 3.zip
    447B
    720p H Quant = 4.png
    1280 x 720 - 998K
    1080i H Quant = 4.png
    1920 x 1080 - 2M
    1080p H Default Firmware.png
    1920 x 1080 - 2M
    1080p H Quant = 4.png
    1920 x 1080 - 2M
  • @cbrandin
    I up the buffer 3x kept all other settings the same from previous post. 24H-66Mbps gop6. Camera didn't crash. There is a difference for the better. motion was better. I saw it more in 720p 42Mbps- AQ-0 GOP6. I know Not very helpful or scientific. I'll stick with the first observation.
    @stonebat
    Wow didn't even think to shoot 24L I have it at VK's suggested 35Mbps AQ-3.I'll shoot tomorrow then up to 44Mbps for comparison and maybe up 24H to GOP12.

    Thanks
    Luke
  • @cosimo_bullo My new favorite is 12 GOP on both 24p and 60p.

    @mpgxsvcd the uneven cadence happens at GOP3 and GOP6, too. It goes away at GOP12.

    @LukeV Based on my testing and @mpgxsvcd's testing, 44Mbps, GOP12, AQ4 for 24p, AQ3 for 60p seems to be good candidate for the baseline setting. I'm waiting for @cbrandin's feedback.
  • @stonebat

    Those sound good to me. Just curious, why use AQ3 for 720p and AQ4 for 1080p? Are you planning to raise the buffer settings too?

    Chris
  • @mpgxsvcd

    What do you mean by "uneven cadence" with the 720p settings? Are frames being displayed at an uneven interval? Nice report, by the way...

    Chris
  • It looks like the codec has parameters tuned to the default GOP's that we haven't found yet. These tests have illuminated several issues - that's a very good thing. For now, it seems sensible to not mess with GOP too much and concentrate on other things. Short GOP will probably have to wait, at least in this thread, for a later version of PTool.

    Chris
  • @cbrandin

    The uneven cadence is simply the high value P frame followed by the low value P frame. You can see it in the Stream parser file for the first attachment. The standard pattern that I have seen for P frames is a very consistent amplitude that gradually raises and lowers.

    I see no ill affects in the visual quality of the videos with this uneven cadence. It just seems like the bits alocated to the P frames goes up and down faster than normal. It may or may not be a good/bad thing. I am not sure. I just wanted to point out that it does happen.
  • Something occurred to me. The AQ setting for 1080 applies to all 1080 modes - 24H, 24L, FSH, and FS. There are calculations the camera does to change the various bitrates based on common settings. I suspect that if the bitrates for all 1080 modes are not increased in the same proportion things will go wrong. Therefore, I think that if you double the bitrate for 24H, for example, you have to also double the bitrates for all the other 1080 modes. Same for 720p modes, they also share a common AQ parameter. Actually, there are other common parameters as well, so I think this is a good idea for many reasons. Come to think of it, there are parameters shared by 1080 and 720 modes as well. Maybe it's a good idea to raise all bitrates in the same proportion.

    Chris
  • I had problems with "uneven cadence" as well. It's usually like this:

    Camera starts fine, with Big I-frames, followed by slightly smaller P-frames and smallest B-frames in between. Suddenly, the I-frames will get "flattened" and both I,P and B-frames get the same amplitude, or there will be saw-tooth pattern. While other didn't notice IQ-differences, I noticed strong pulsing in darker areas of detailed shots.

    After lengthy testing (probably about 20 re-flashes), I "solved" the problem of uneven cadence by increasing Frame Buffer, Muxer buffer and Video buffer.

    My findings so far:

    Video buffer seems to contain rendered file before being written to card. Thus it will not influence bitrate. It will only safeguard uneven transfer rate to card.

    "Uneven cadence" seems to happen when I-frames get so big that they cannot fit into buffer. The camera probably throws away some info to make it fit and resulting P-frames are smaller too as they are predicted from "maimed" I-frame. So you get macro-blocking, and funny looking GOP.

    After raising the FL, uneven cadence went away. I assume that uneven cadence happens when I-frames cannot fit into FL-value. Here are my settings:

    Video Bitrate 24H=52000000
    Video Bitrate 24L=52000000
    Video Bitrate FSH/SH=48000000
    Video Bitrate FH/H=42000000
    Auto Quantizer for 1080 modes=3 - Most to details
    Auto Quantizer for 720 modes=1 - Some to details
    Video buffer=0x3000000
    Video buffer 24p=0x3000000
    Muxer buffer for other modes=25165824
    1080p24 Frame Limit=15728640
    50fps Frame Limit=7549746


    P.S. When I enable B-frames for 720p, the "uneven cadence" problem will not manifest itself as easily. Unfortunately, that means "1080p-dance" before each shot. Otherwise, I found that B-framed 720p is superior to IP, even at lower bitrates.

  • @cbrandin That didn't fix it, but it's interesting that changing bitrates on other modes did change the pattern. Until this gets fixed, I will keep GOP12 setting.

    The irregular cadence bug gets the worst at GOP6. It almost goes away at AQ1. It gets worse as AQ goes higher.

    Interestingly the bug didn't happen at -2 EV setting. Also it didn't happen at 0 EV when pointing to the blue sky. BTW no color banding in the sky!!! Beautiful.
    irregular.jpg
    1194 x 200 - 73K
  • @cbrandin Why 24p AQ4 and 60p AQ3 as baseline? Good question. I don't know. I guess both can be AQ3 to keep it simple.

    Anyways... it seems this effort is in freeze until the bug gets fixed.
  • The cadence seems good with these settings.
    30 sec clip with good cadence all the way through.
    filmed on a bright sunny day, lots of detail foliage, tripod static and with pans and tilts.
    No lock ups on all settings, even stable in EXT.

    Used a Canon FD 50mm lens @ f22, iso 160, 1/50, smooth film mode, -2,0, 0,0
    Sandisk extreme class 10 card

    24H =110000000, AQ3, GOP3
    24L=66000000, AQ3,GOP3
    FSH=48000000, AQ3,GOP6
    FH=36000000, AQ3,GOP6

    load seth.ini fot more details
    SP 110.jpg
    5289 x 2799 - 3M
    seth.zip
    396B
  • You gotta go past 240th frame or the first 10 seconds to see the anomaly.
  • @stonebat Can you upload your latest settings ini?
  • I don't think that "irregular cadence" has to do with EV-settings or such. -2 EV will often force camera to use lower ISO, resulting in less grain in the picture. Picture will be easier to compress so I-frames won't hit the limit, and you get working GOP.


    The worst-case scenario I use is just jacking up the ISO really high, resulting in lot's of grain. It will force codec to hit it's bitrate limit trying to encode the noise. If there are "irregular cadence" problems, they will manifest themselves then.
  • @rigs

    Can you post a sample 20-30 second video to Vimeo with those settings? I would like to see that one myself. I can't change the firmware on my camera at the moment because we are leaving for a trip and I need the most stable settings I can get.
  • @Grunf I used same settings. The only difference was strength of ext light. I can't conclude anything out of it. But -2 EV didn't have the irregular cadence issue. Just more clue for Chris. That's all.
  • @rigs

    Your stream looks really good. Nice big I frames too. Like @mpgxsvcd, I'd like to see the clip. I'm guessing it is a detailed scene? Did you look later in the stream like @stonebat suggested?

    Chris
  • @cbrandin and @rigs

    The B-frames look big as well. Nearly 2 mb for a B-frame is a lot. There really isn't much compression going on in that file.
  • @rigs 24p GOP3 AQ3 at 0 EV... past the 240th frame. To be safe, expand it all the way to one minute. I'm seeing the anomaly consistently regardless of bitrates.

    image
  • Hi I'm looking for the settings that were used on this video but I'm unclear about if they are in this thread. It looks like what @rigs posted, but without assuming anything can you guys help direct me, this video looks incredible.



  • Sorry I jumped the gun.
    I just did some more test scenes and I'm now seeing the cadence anomaly.
    Tried to shoot under exposed but with no better results.
    SP 110 2.jpg
    2687 x 1396 - 1M
    SP 110 3.jpg
    2678 x 1389 - 1M
  • Vitaliy has acknowledged the low GOP problem and is working on it. I think that we might want to put off additional low GOP testing for now.

    I think I have come up with a simple way to test for better low level quality. Shoot a res chart (or some other fairly busy target) and start underexposing it until you can't see it any more. Is there a difference between settings as to how far you can go before the image is no longer visible? How does the image look when it's almost invisible - is it smooth or blotchy? These tests would be best done at ISO 160, as the camera loses dynamic range as ISO goes up and that may be the limiting factor rather than the codec.

    I have found that setting levels (I use Photoshop for this on framegrabs) to bring a dark image up to normal makes things very visible (it's ugly, but you can see what's going on).

    Chris
This topic is closed.
← All Discussions