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 3rd January 2020, 21:19   #7301  |  Link
benwaggoner
Moderator
 
Join Date: Jan 2006
Location: Portland, OR
Posts: 4,829
Quote:
Originally Posted by Greenhorn View Post
Oddly, enabling ssim-rd by itself will disable psy-rd, but if you manually specify both they'll both be used.
Have you confirmed they are both operating, or is it possible one overrides the other?

If psy-rd + ssim-rd looks different than just psy-rd OR ssim-rd, than they are doing something together. But it wouldn't be surprising if different rd modes can't operate simultaneously. Although, algorithmically, I could see these being able to function simultaneously.
__________________
Ben Waggoner
Principal Video Specialist, Amazon Prime Video

My Compression Book
benwaggoner is offline   Reply With Quote
Old 4th January 2020, 08:07   #7302  |  Link
Greenhorn
Registered User
 
Join Date: Apr 2018
Posts: 61
Woops

Quote:
Originally Posted by benwaggoner View Post
Have you confirmed they are both operating, or is it possible one overrides the other?

If psy-rd + ssim-rd looks different than just psy-rd OR ssim-rd, than they are doing something together. But it wouldn't be surprising if different rd modes can't operate simultaneously. Although, algorithmically, I could see these being able to function simultaneously.
That was an embarrasing mistake on my part. While the x265 CLI output will imply that both psy-rd and ssim-rd are enabled if you specify psy-rd after ssim-rd, it produces bit-identical output to not having ssim-rd enabled.

Similarly, enabling ssim-rd without doing anything to psy-rd is identical to manually disabling psy-rd. The encoder is clear about this, though, so hopefully I didn't manage to confuse anyone reading about that.
Greenhorn is offline   Reply With Quote
Old 6th January 2020, 17:26   #7303  |  Link
jlpsvk
Registered User
 
Join Date: Dec 2014
Posts: 240
what's better? ssim-rd or psy-rd?
__________________
AMD Ryzen 9 5950X, 32GB DDR4-3200 CL16, RTX 3060, 2TB NVMe PCIE4.0, NAS with 8x16TB HDD
jlpsvk is offline   Reply With Quote
Old 6th January 2020, 17:32   #7304  |  Link
microchip8
ffx264/ffhevc author
 
microchip8's Avatar
 
Join Date: May 2007
Location: /dev/video0
Posts: 1,846
Quote:
Originally Posted by jlpsvk View Post
what's better? ssim-rd or psy-rd?
psy-rd... again, from my own testing ssim-rd produces visual distortions in some samples I tested long ago. ssim-rd is optimized to get the best SSIM metric values. While SSIM is (much) better than PSNR, it isn't perfect. psy-rd biases towards the energy of the source and will give, at higher values, a more subjectively looking better quality

There's also dynamic-rd but it needs vbv-bufsize and vbv-maxrate *and* you need to be hitting those for dynamic-rd to optimally do its thing
__________________
ffx264 || ffhevc || ffxvid || microenc

Last edited by microchip8; 6th January 2020 at 17:42.
microchip8 is offline   Reply With Quote
Old 6th January 2020, 23:05   #7305  |  Link
benwaggoner
Moderator
 
Join Date: Jan 2006
Location: Portland, OR
Posts: 4,829
Quote:
Originally Posted by froggy1 View Post
There's also dynamic-rd but it needs vbv-bufsize and vbv-maxrate *and* you need to be hitting those for dynamic-rd to optimally do its thing
--dynamic-rd is really a speed/quality tradeoff option, orthogonal to the style of RD actually being applied. dynamic-rd changes the --rd parameter when the VBV buffer is hit, so a faster, lower quality setting can be used for easier sections of the video.
__________________
Ben Waggoner
Principal Video Specialist, Amazon Prime Video

My Compression Book
benwaggoner is offline   Reply With Quote
Old 7th January 2020, 00:18   #7306  |  Link
benwaggoner
Moderator
 
Join Date: Jan 2006
Location: Portland, OR
Posts: 4,829
Say, is anyone making Windows binaries with AVX-512 support somewhere? I wanted to do some tests.
__________________
Ben Waggoner
Principal Video Specialist, Amazon Prime Video

My Compression Book
benwaggoner is offline   Reply With Quote
Old 7th January 2020, 01:06   #7307  |  Link
jlpsvk
Registered User
 
Join Date: Dec 2014
Posts: 240
Quote:
Originally Posted by benwaggoner View Post
Say, is anyone making Windows binaries with AVX-512 support somewhere? I wanted to do some tests.
just use --asm avx512

__________________
AMD Ryzen 9 5950X, 32GB DDR4-3200 CL16, RTX 3060, 2TB NVMe PCIE4.0, NAS with 8x16TB HDD
jlpsvk is offline   Reply With Quote
Old 7th January 2020, 02:24   #7308  |  Link
Magik Mark
Registered User
 
Join Date: Dec 2014
Posts: 666
Quote:
Originally Posted by benwaggoner View Post
--dynamic-rd is really a speed/quality tradeoff option, orthogonal to the style of RD actually being applied. dynamic-rd changes the --rd parameter when the VBV buffer is hit, so a faster, lower quality setting can be used for easier sections of the video.


What values would you suggest for vbv buffer when encoding 1080p and 2160p in 2 pass. Maybe a guide or a table. Thanks alot


Sent from my iPhone using Tapatalk
__________________
Asus ProArt Z790 - 13th Gen Intel i9 - RTX 3080 - DDR5 64GB Predator - LG OLED C9 - Yamaha A3030 - Windows 11 x64 - PotPlayerr - Lav - MadVR
Magik Mark is offline   Reply With Quote
Old 7th January 2020, 04:36   #7309  |  Link
Blue_MiSfit
Derek Prestegard IRL
 
Blue_MiSfit's Avatar
 
Join Date: Nov 2003
Location: Los Angeles
Posts: 5,991
If you're encoding for streaming, I'd start with maxrate = 1.1x - 1.5x bitrate and bufsize = 2x bitrate.

Else set them to the profile maximums
Blue_MiSfit is offline   Reply With Quote
Old 7th January 2020, 05:12   #7310  |  Link
Magik Mark
Registered User
 
Join Date: Dec 2014
Posts: 666
Quote:
Originally Posted by Blue_MiSfit View Post
If you're encoding for streaming, I'd start with maxrate = 1.1x - 1.5x bitrate and bufsize = 2x bitrate.

Else set them to the profile maximums


Oh I see. Can you refer me to the table detailing max buffer for every profile? Thanks


Sent from my iPhone using Tapatalk
__________________
Asus ProArt Z790 - 13th Gen Intel i9 - RTX 3080 - DDR5 64GB Predator - LG OLED C9 - Yamaha A3030 - Windows 11 x64 - PotPlayerr - Lav - MadVR
Magik Mark is offline   Reply With Quote
Old 7th January 2020, 08:33   #7311  |  Link
l00t
Where's my loot?
 
Join Date: May 2019
Posts: 63
Quote:
Originally Posted by benwaggoner View Post
Say, is anyone making Windows binaries with AVX-512 support somewhere? I wanted to do some tests.
Unfortunately, according to my experiences, it won't do any good, because the CPU's clock speed will be significantly lower and will compensate the speed boost from using AVX512 (or at least this was the case for a Xeon Gold 6152).
l00t is offline   Reply With Quote
Old 7th January 2020, 09:17   #7312  |  Link
jlpsvk
Registered User
 
Join Date: Dec 2014
Posts: 240
Quote:
Originally Posted by l00t View Post
Unfortunately, according to my experiences, it won't do any good, because the CPU's clock speed will be significantly lower and will compensate the speed boost from using AVX512 (or at least this was the case for a Xeon Gold 6152).
yeah... avx512 produces much more heat... so probably safety issue...
__________________
AMD Ryzen 9 5950X, 32GB DDR4-3200 CL16, RTX 3060, 2TB NVMe PCIE4.0, NAS with 8x16TB HDD
jlpsvk is offline   Reply With Quote
Old 7th January 2020, 14:35   #7313  |  Link
LazyNcoder
Registered User
 
Join Date: Feb 2015
Posts: 33
Hello guys,

Any good, accurate and easy way to convert h265 HDR bt2020 to SDR bt709 using Avisynth/Vapoursynth (maybe via Staxrip)?
Something like what madVR is doing, without all the troubles.
LazyNcoder is offline   Reply With Quote
Old 7th January 2020, 15:30   #7314  |  Link
redbtn
Registered User
 
redbtn's Avatar
 
Join Date: Jan 2019
Location: Russia
Posts: 105
Quote:
Originally Posted by LazyNcoder View Post
Hello guys,

Any good, accurate and easy way to convert h265 HDR bt2020 to SDR bt709 using Avisynth/Vapoursynth (maybe via Staxrip)?
Something like what madVR is doing, without all the troubles.
Easy, no. You can try HDR to SDR conversion, but you have to adjust settings to every movie.
redbtn is offline   Reply With Quote
Old 7th January 2020, 16:05   #7315  |  Link
LazyNcoder
Registered User
 
Join Date: Feb 2015
Posts: 33
Quote:
Originally Posted by redbtn View Post
Easy, no. You can try HDR to SDR conversion, but you have to adjust settings to every movie.
Eh, thanks?

Any tutorials/tools for doing that?
I can search I know. But you could save a lot of time being wasted for me or other people reading your reply. After all, that's why we are all here. Thank you
LazyNcoder is offline   Reply With Quote
Old 7th January 2020, 19:00   #7316  |  Link
redbtn
Registered User
 
redbtn's Avatar
 
Join Date: Jan 2019
Location: Russia
Posts: 105
Quote:
Originally Posted by LazyNcoder View Post
Any tutorials/tools for doing that?
I don't have any tutorials, but some links can help you.

http://forum.doom9.org/showthread.php?p=1847425

http://forum.doom9.org/showthread.php?p=1888974

http://forum.doom9.org/showthread.php?p=1880345

http://forum.doom9.org/showthread.php?p=1800667
redbtn is offline   Reply With Quote
Old 7th January 2020, 19:16   #7317  |  Link
Atak_Snajpera
RipBot264 author
 
Atak_Snajpera's Avatar
 
Join Date: May 2006
Location: Poland
Posts: 7,870
Quote:
Originally Posted by LazyNcoder View Post
Hello guys,

Any good, accurate and easy way to convert h265 HDR bt2020 to SDR bt709 using Avisynth/Vapoursynth (maybe via Staxrip)?
Something like what madVR is doing, without all the troubles.
https://forum.doom9.org/showthread.p...84#post1893684
Atak_Snajpera is offline   Reply With Quote
Old 7th January 2020, 21:13   #7318  |  Link
Majorlag
Registered User
 
Join Date: Jul 2016
Posts: 19
Quote:
Originally Posted by Magik Mark View Post
Oh I see. Can you refer me to the table detailing max buffer for every profile? Thanks


Sent from my iPhone using Tapatalk
For x264 look at https://en.wikipedia.org/wiki/Advanced_Video_Coding under Levels

For x265 look at https://en.wikipedia.org/wiki/High_E...y_Video_Coding or for a more detailed deep dive at https://en.wikipedia.org/wiki/High_E...ers_and_levels

For my encodes I use 1080p:--vbv-bufsize 20000 --vbv-maxrate 20000 and for 2160p:--vbv-bufsize 25000 --vbv-maxrate 25000, so that I make sure to meet DXVA requirements for some older finicky set top boxes.
Majorlag is offline   Reply With Quote
Old 7th January 2020, 22:25   #7319  |  Link
benwaggoner
Moderator
 
Join Date: Jan 2006
Location: Portland, OR
Posts: 4,829
Quote:
Originally Posted by Magik Mark View Post
What values would you suggest for vbv buffer when encoding 1080p and 2160p in 2 pass. Maybe a guide or a table. Thanks alot


Sent from my iPhone using Tapatalk
By default I'll use the maximum values defined by the Profile, Tier, and Level. Wikipedia's HEVC article has a very nice table.

Sent from my SM-T837V using Tapatalk
__________________
Ben Waggoner
Principal Video Specialist, Amazon Prime Video

My Compression Book
benwaggoner is offline   Reply With Quote
Old 7th January 2020, 22:29   #7320  |  Link
benwaggoner
Moderator
 
Join Date: Jan 2006
Location: Portland, OR
Posts: 4,829
Quote:
Originally Posted by LazyNcoder View Post
Hello guys,

Any good, accurate and easy way to convert h265 HDR bt2020 to SDR bt709 using Avisynth/Vapoursynth (maybe via Staxrip)?
Something like what madVR is doing, without all the troubles.
There is no "accurate" way to do this. HDR and SDR masters are actually done as seperate creative passes, emphasizing different visual elements. They get approved seperately by the creatives before release.

If you want 709, best to start with the 709 source. There is almost no HDR content that isn't also available in SDR.

Sent from my SM-T837V using Tapatalk
__________________
Ben Waggoner
Principal Video Specialist, Amazon Prime Video

My Compression Book
benwaggoner 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 03:57.


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