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 > Video Encoding > High Efficiency Video Coding (HEVC)

Reply
 
Thread Tools Search this Thread Display Modes
Old 7th November 2022, 10:01   #1  |  Link
A1
shortest name
 
Join Date: Sep 2022
Posts: 12
Suitable for quality coding -- aq-mode on the chroma plane

The usual way to solve the over-quantization of the chroma plane is to use the negative values ​​of the two parameters --cbqpoffs --crqpoffs,

However, this often uses an excessively large offset, which leads to a waste of code rate. To accurately set the value, you need to do a lot of tests manually. In addition, the compression speed of x265 is very slow, which is not suitable for multiple tests on computers with ordinary performance.

Therefore, there should be an aq-mode that automatically calculates the appropriate offset value and reasonably reduces the qp value of the chroma plane to ensure that the chroma plane is not over-quantized.

The inconsistency of the clarity of the luma plane and the chroma plane of different film sources is the root of the problem.

The clarity of the luma plane and the chroma plane of some film sources are similar, so it is suitable to use similar quantization values.

For some other sources, the clarity of the luma plane and the chroma plane is very different. When compressing with the same quantization value, the luma plane is still clear, but the chroma plane is blurred enough to be detected by the naked eye.

These differences can also be different in different time periods of the same source. The clarity of the luma plane and the chroma plane in the X time period is close, and the clarity of the luma plane and the chroma plane in the Y time period is very different.

It is not reasonable to use the same chromaqp offset in this case.

The best solution is to develop aq-mode that shifts the qp value of the chroma plane, using a smaller qp value for those time periods and regions where the chroma is very blurred relative to the luma plane.

I think if there is such aq-mode, it will be of great help for quality-oriented encoding.
A1 is offline   Reply With Quote
Old 7th November 2022, 13:39   #2  |  Link
rwill
Registered User
 
Join Date: Dec 2013
Posts: 343
I think x265 is still in "Patches Welcome" mode. Go ahead.
rwill is offline   Reply With Quote
Old 8th November 2022, 00:02   #3  |  Link
benwaggoner
Moderator
 
Join Date: Jan 2006
Location: Portland, OR
Posts: 4,752
Another potential approach would be to use a less coarse lambda table for chroma. It's been years since the last lambda table update.
__________________
Ben Waggoner
Principal Video Specialist, Amazon Prime Video

My Compression Book
benwaggoner is offline   Reply With Quote
Old 8th November 2022, 14:02   #4  |  Link
A1
shortest name
 
Join Date: Sep 2022
Posts: 12
Quote:
Originally Posted by benwaggoner View Post
Another potential approach would be to use a less coarse lambda table for chroma. It's been years since the last lambda table update.
Regarding the question of how reasonable the chromaticity plane is to be quantified, different people think that the answer is different, and it is difficult to come up with a standard answer.
It is better to make a parameter similar to --qcomp or --aq-strength, and let the user adjust the strength by himself.
A1 is offline   Reply With Quote
Old 8th November 2022, 21:52   #5  |  Link
benwaggoner
Moderator
 
Join Date: Jan 2006
Location: Portland, OR
Posts: 4,752
Quote:
Originally Posted by A1 View Post
Regarding the question of how reasonable the chromaticity plane is to be quantified, different people think that the answer is different, and it is difficult to come up with a standard answer.
It is better to make a parameter similar to --qcomp or --aq-strength, and let the user adjust the strength by himself.
Or simply add a better --aq-mode implementation for chroma. Adaptive Quantization is exactly supposed to adapt internal parameters to those optimal for the content. Better if x265 itself would reduce chroma QP when psychovisually appropriate, and save the bits otherwise.
__________________
Ben Waggoner
Principal Video Specialist, Amazon Prime Video

My Compression Book
benwaggoner is offline   Reply With Quote
Old 10th November 2022, 15:01   #6  |  Link
A1
shortest name
 
Join Date: Sep 2022
Posts: 12
Quote:
Originally Posted by benwaggoner View Post
Or simply add a better --aq-mode implementation for chroma. Adaptive Quantization is exactly supposed to adapt internal parameters to those optimal for the content.
If you want to add aq-mode about the chroma plane, then consider the problem of using multiple aq-modes at the same time.
The cost of using aq-mode that enhances the chroma plane cannot be the loss of other aq-mode benefits.
A1 is offline   Reply With Quote
Old 10th November 2022, 22:15   #7  |  Link
benwaggoner
Moderator
 
Join Date: Jan 2006
Location: Portland, OR
Posts: 4,752
Quote:
Originally Posted by A1 View Post
If you want to add aq-mode about the chroma plane, then consider the problem of using multiple aq-modes at the same time.
The cost of using aq-mode that enhances the chroma plane cannot be the loss of other aq-mode benefits.
Right. Chroma and luma adaptive quantization really ought to be implemented as a single tool picking optimal mode for each plane. Sometimes the chroma planes themselves can benefit from different qp offsets or other tuning.
__________________
Ben Waggoner
Principal Video Specialist, Amazon Prime Video

My Compression Book
benwaggoner is offline   Reply With Quote
Old 14th December 2022, 07:09   #8  |  Link
BlueSwordM
Registered User
 
BlueSwordM's Avatar
 
Join Date: Dec 2021
Location: Canada
Posts: 22
What you essentially want is the rav1e approach.
Essentially, with a proper study, you can find what's the best chroma offset for a certain colorspace in a certain setting.
BlueSwordM is offline   Reply With Quote
Old 22nd December 2022, 09:24   #9  |  Link
A1
shortest name
 
Join Date: Sep 2022
Posts: 12
Quote:
Originally Posted by BlueSwordM View Post
What you essentially want is the rav1e approach.
Essentially, with a proper study, you can find what's the best chroma offset for a certain colorspace in a certain setting.

Does "rav1e" mean "universal"?
I was looking for a "generic" approach,
Because I found that the time to study x265 is many times longer than the time to run it.
A1 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 10:03.


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