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 19th August 2016, 12:19   #1  |  Link
damjeux
Registered User
 
Join Date: Apr 2015
Posts: 7
HEVC multi-rate encoding for adaptive HTTP streaming

I haven't seen much talk about multi-rate encoding with HEVC. Basically, a single system which encodes one video at different bitrates to target adaptive bitrate streaming. The different bitrates can be achieved by encoding at different spatial resolutions, different signal qualities or different frame rates. Sharing information between the individual encoder processes can lead to an overall computational complexity reduction.

I have recently implemented a multi-rate encoding method for x265 based on a CU structure reuse from a high-quality encoding to speed-up lower quality encodings.
I have also posted some results in a blog post. Depending on the configuration, the x265 multi-rate encoder can for example achieve an overall complexity reduction of 10% with no rate-distortion loss (even a very small improvement on average). Or achieve 20% complexity reduction with an average bitrate increase of 0.9%.

Multicoreware has the so-called UHDkit https://x265.com/uhdkit-hevc-encoding-library/

There is also a white paper from Vanguard on the topic http://vanguardvideo.com/wp-content/...Whitepaper.pdf

All in all, not so much details about the technical solutions. Is there some more open-source work on multi-rate out there? Do you know some other sources of information about the topic? My guess is that all major streaming providers are implementing such methods...
damjeux is offline   Reply With Quote
Old 23rd August 2016, 03:18   #2  |  Link
Motenai Yoda
Registered User
 
Motenai Yoda's Avatar
 
Join Date: Jan 2010
Posts: 709
I'm not sure but how is it different from the analysis-mode of x265?

Quote:
--analysis-mode <string|int>

Specify whether analysis information of each frame is output by encoder or input for reuse. By reading the analysis data writen by an earlier encode of the same sequence, substantial redundant work may be avoided.

The following data may be stored and reused: I frames - split decisions and luma intra directions of all CUs. P/B frames - motion vectors are dumped at each depth for all CUs.

Values: off(0), save(1): dump analysis data, load(2): read analysis data
__________________
powered by Google Translator
Motenai Yoda is offline   Reply With Quote
Old 23rd August 2016, 21:47   #3  |  Link
benwaggoner
Moderator
 
Join Date: Jan 2006
Location: Portland, OR
Posts: 4,752
Analysis-mode allows much faster encoding for the same frame size at different bitrates, yes.


Sent from my iPad using Tapatalk
__________________
Ben Waggoner
Principal Video Specialist, Amazon Prime Video

My Compression Book
benwaggoner is offline   Reply With Quote
Old 25th August 2016, 13:34   #4  |  Link
damjeux
Registered User
 
Join Date: Apr 2015
Posts: 7
Yes, the implemented method is very similar to analysis-mode. The main difference is that the the reuse of the data stored in analysis-mode is not targeted at different representations, that is, different bitrates/different qualities.

As an example, I tried analysis-mode 1 on an encoding at QP 22, then analysis-mode 2 on encodings at QP 27, 32, and 37. The result is an increased bitrate (on average 5.8% at a given PSNR), and an overall encoding time decreased by 23%, compared to the same four representations without analysis-mode.

On the contrary, if I use the implemented method, e.g. mr-mode 1 on QP 22, then mr-mode 2 on QPs 27, 32, and 37, I get for example 0.0% increased bitrate on average at a given PSNR and an overall encoding time decrease of 10%.

Or if I use mr-mode 1 on CRF 22, then mr-mode 2 on CRF 27, 32, and 37, I get 0.9% average increase in bitrate and an overall encoding time reduction of 19%.
These results are detailed in the blog post I mentioned earlier.

So the benefit of the implement method is that the rate-distortion performance is better than with analysis-mode (in this specific scenario of having multiple representations at different qualities).
damjeux is offline   Reply With Quote
Old 25th August 2016, 19:11   #5  |  Link
x265_Project
Guest
 
Posts: n/a
Hi Damjeux,
I'm sorry I didn't reply when you first informed us of your work on our development mailing list. We have a team that is also working on improving analysis save/load/refine, for a variety of interesting applications (not just multi-bitrate encoding). We would be interested in evaluating your contributions for possible inclusion in x265, but we would first need you to sign our Contributor License Agreement.

If you would like to collaborate directly with our team, we would be happy to arrange a phone call to discuss.

Thanks,
Tom
  Reply With Quote
Old 26th August 2016, 11:58   #6  |  Link
damjeux
Registered User
 
Join Date: Apr 2015
Posts: 7
Thanks for the reply. I've sent you an email.
damjeux is offline   Reply With Quote
Old 12th September 2016, 21:07   #7  |  Link
kabelbrand
Compression mode: Lousy
 
kabelbrand's Avatar
 
Join Date: Mar 2009
Location: Hamburg, Germany
Posts: 72
Quote:
Originally Posted by benwaggoner View Post
Analysis-mode allows much faster encoding for the same frame size at different bitrates, yes.
What about different frame sizes? With x264 I'd run a first pass in 1080 and then a second pass in multiple resolutions using the log from the 1080 first pass.
Does that work with x265 as well?
kabelbrand is offline   Reply With Quote
Old 13th September 2016, 07:57   #8  |  Link
benwaggoner
Moderator
 
Join Date: Jan 2006
Location: Portland, OR
Posts: 4,752
Quote:
Originally Posted by kabelbrand View Post
What about different frame sizes? With x264 I'd run a first pass in 1080 and then a second pass in multiple resolutions using the log from the 1080 first pass.
Does that work with x265 as well?
I believe that can work. However, the bigger the delta in frame size for the second pass (in x264 when I've tried this, certainly), the bigger the quality loss in the second pass. If you have a broad range of frame sizes, I've not found that to be a useful technique on net.

Variants of the same frame size have a much smaller quality hit, more than made up for being able to boost up the --preset a notch due to perf savings.
__________________
Ben Waggoner
Principal Video Specialist, Amazon Prime Video

My Compression Book
benwaggoner is offline   Reply With Quote
Reply

Tags
adaptive http streaming, multi-rate

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 08:20.


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