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 1st February 2021, 18:20   #41  |  Link
benwaggoner
Moderator
 
Join Date: Jan 2006
Location: Portland, OR
Posts: 4,490
Quote:
Originally Posted by quietvoid View Post
Keep in mind that x265 rarely saturates over 8 cores on its own, regardless of the settings or parallelism optimizations (such as --pme, --pmode, etc.)
With my 5900X, it barely uses over 60% of the CPU with preset slower.
Thread utilization is proportional to frame size. 4K can saturate 16 threads pretty easily with the right configurations. I've got a dual Xeon (2x18/36 cores) and generally use --pools to pin 4K or lower encodes to one or the other as the second socket rarely adds any perf. But for 8K, I'm able to get some value out of the second socket with default --frame-threads.

I've never had --pme give me material improvements, but haven't tried for a few years; it'd be most likely in low resolutions using --preset placebo or something. --pmode can definitely help in some configurations, but is slower in others. It's more helpful with slower presets, presumably because a lot more modes are being evaluated to parallelize.
__________________
Ben Waggoner
Principal Video Specialist, Amazon Prime Video

My Compression Book
benwaggoner is offline   Reply With Quote
Old 1st February 2021, 19:59   #42  |  Link
Atak_Snajpera
RipBot264 author
 
Atak_Snajpera's Avatar
 
Join Date: May 2006
Location: Poland
Posts: 7,764
Quote:
Originally Posted by quietvoid View Post
I doubt x265 will improve on this, so it's not temporary.
More cores is still better, you can see from your results that the 5900X is 45% faster, 15-20% might be the IPC improvement, the remaining 25% is probably the extra cores.

x265 just doesn't fully load the cores most of the time.
One way I've found that improves around 10% is to use a lower --merange and increase frame threads, but that doesn't improve the core saturation much.
CPU utilization is most likely reduced by default --ctu 64 value. Use --ctu 32 --merange 25
Atak_Snajpera is offline   Reply With Quote
Old 1st February 2021, 20:09   #43  |  Link
quietvoid
Registered User
 
Join Date: Jan 2019
Location: Canada
Posts: 545
Yes ctu 32 does increase usage, but it's also slightly lower quality.
It's a compromise.
quietvoid is offline   Reply With Quote
Old 1st February 2021, 20:13   #44  |  Link
microchip8
ffx264/ffhevc author
 
microchip8's Avatar
 
Join Date: May 2007
Location: Belgium
Posts: 1,782
Quote:
Originally Posted by quietvoid View Post
Yes ctu 32 does increase usage, but it's also slightly lower quality.
It's a compromise.
Slightly lower quality at 4K and up. The same quality at lower resolutions (FHD and lower)
__________________
TV: Samsung 50" QE50Q60T AVR: Yamaha RX-V481 5.1 CD Player: Yamaha CD-S300 DAB+ Tuner: Yamaha T-D500 BD Player: Samsung UBD-M8500 UHD Speakers: Klipsch 5.1 Reference Phono: Audio-Technica AT-LP120XUSB
microchip8 is offline   Reply With Quote
Old 1st February 2021, 20:27   #45  |  Link
Nico8583
Registered User
 
Join Date: Jan 2010
Location: France
Posts: 842
Thank you, I'm still hesitating to replace my 3700X by 3900X, 5800X or 5900X. The only real difference between all is only the encoding time ?
Nico8583 is offline   Reply With Quote
Old 1st February 2021, 20:56   #46  |  Link
microchip8
ffx264/ffhevc author
 
microchip8's Avatar
 
Join Date: May 2007
Location: Belgium
Posts: 1,782
Quote:
Originally Posted by Nico8583 View Post
Thank you, I'm still hesitating to replace my 3700X by 3900X, 5800X or 5900X. The only real difference between all is only the encoding time ?
If you use the same settings, yes. But if you get a Zen 3 CPU you can increase the settings for better compression/quality and comparable encoding time to Zen 2 CPUs
__________________
TV: Samsung 50" QE50Q60T AVR: Yamaha RX-V481 5.1 CD Player: Yamaha CD-S300 DAB+ Tuner: Yamaha T-D500 BD Player: Samsung UBD-M8500 UHD Speakers: Klipsch 5.1 Reference Phono: Audio-Technica AT-LP120XUSB
microchip8 is offline   Reply With Quote
Old 1st February 2021, 21:28   #47  |  Link
Nico8583
Registered User
 
Join Date: Jan 2010
Location: France
Posts: 842
Quote:
Originally Posted by microchip8 View Post
If you use the same settings, yes. But if you get a Zen 3 CPU you can increase the settings for better compression/quality and comparable encoding time to Zen 2 CPUs
Yes but I can increase settings with my Zen 2 also, the time will be perhaps 36 hours with Zen 2 instead of 24 hours with Zen 3 ? There is no setting I can use with Zen 3 and not with Zen 2 ?
Nico8583 is offline   Reply With Quote
Old 1st February 2021, 21:53   #48  |  Link
microchip8
ffx264/ffhevc author
 
microchip8's Avatar
 
Join Date: May 2007
Location: Belgium
Posts: 1,782
Quote:
Originally Posted by Nico8583 View Post
Yes but I can increase settings with my Zen 2 also, the time will be perhaps 36 hours with Zen 2 instead of 24 hours with Zen 3 ? There is no setting I can use with Zen 3 and not with Zen 2 ?
That's not what I was saying.

If you get 2 FPS with your Zen 2 CPU and current settings, when you get a Zen 3 CPU, you can increase the settings and get the same 2 FPS as the Zen 2 CPU, but with better compression/quality. If you increase the settings on your current Zen 2 CPU, you will get (much) lower FPS encoding.

In other words, Zen 3 allows you to get comparable FPS as Zen 2 but with increased settings. Of course you can increase the settings for your Zen 2 CPU, but the FPS will be much lower
__________________
TV: Samsung 50" QE50Q60T AVR: Yamaha RX-V481 5.1 CD Player: Yamaha CD-S300 DAB+ Tuner: Yamaha T-D500 BD Player: Samsung UBD-M8500 UHD Speakers: Klipsch 5.1 Reference Phono: Audio-Technica AT-LP120XUSB
microchip8 is offline   Reply With Quote
Old 1st February 2021, 22:33   #49  |  Link
Nico8583
Registered User
 
Join Date: Jan 2010
Location: France
Posts: 842
Quote:
Originally Posted by microchip8 View Post
That's not what I was saying.

If you get 2 FPS with your Zen 2 CPU and current settings, when you get a Zen 3 CPU, you can increase the settings and get the same 2 FPS as the Zen 2 CPU, but with better compression/quality. If you increase the settings on your current Zen 2 CPU, you will get (much) lower FPS encoding.

In other words, Zen 3 allows you to get comparable FPS as Zen 2 but with increased settings. Of course you can increase the settings for your Zen 2 CPU, but the FPS will be much lower
Thank you and don't worry, it was not an observation
Perhaps there is a setting too "high" to be used with Zen 2 (because of a lack of power or another reason), my question was in this sense
Nico8583 is offline   Reply With Quote
Old 2nd February 2021, 17:05   #50  |  Link
Boulder
Pig on the wing
 
Boulder's Avatar
 
Join Date: Mar 2002
Location: Finland
Posts: 5,610
If you can get any of those new Ryzens, definitely grab one. Encoding is cheaper since it's more computing power per watt. Otherwise a good option might be to buy a second hand 3900X on the cheap. The extra threads do give a nice boost.

CTU 64 is in my opinion a bad idea. There is something definitely wrong there because --limit-tu 0 --ctu 64 --rskip 2 is just totally broken. I don't trust it at all because of that observation.
https://forum.doom9.org/showthread.p...47#post1919347
__________________
And if the band you're in starts playing different tunes
I'll see you on the dark side of the Moon...
Boulder is offline   Reply With Quote
Old 2nd February 2021, 17:52   #51  |  Link
Nico8583
Registered User
 
Join Date: Jan 2010
Location: France
Posts: 842
Quote:
Originally Posted by Boulder View Post
If you can get any of those new Ryzens, definitely grab one. Encoding is cheaper since it's more computing power per watt. Otherwise a good option might be to buy a second hand 3900X on the cheap. The extra threads do give a nice boost.

CTU 64 is in my opinion a bad idea. There is something definitely wrong there because --limit-tu 0 --ctu 64 --rskip 2 is just totally broken. I don't trust it at all because of that observation.
https://forum.doom9.org/showthread.p...47#post1919347
What are the default values ? ctu=64, limit-tu=0 and rskip ?
Nico8583 is offline   Reply With Quote
Old 2nd February 2021, 18:11   #52  |  Link
benwaggoner
Moderator
 
Join Date: Jan 2006
Location: Portland, OR
Posts: 4,490
Quote:
Originally Posted by Boulder View Post
CTU 64 is in my opinion a bad idea. There is something definitely wrong there because --limit-tu 0 --ctu 64 --rskip 2 is just totally broken. I don't trust it at all because of that observation.
https://forum.doom9.org/showthread.p...47#post1919347
I use ctu 64 regularly without any issues. In the early days I did see some reproable quality issues with ctu 64 sometimes, but it's been years.
__________________
Ben Waggoner
Principal Video Specialist, Amazon Prime Video

My Compression Book
benwaggoner is offline   Reply With Quote
Old 2nd February 2021, 19:15   #53  |  Link
Boulder
Pig on the wing
 
Boulder's Avatar
 
Join Date: Mar 2002
Location: Finland
Posts: 5,610
Quote:
Originally Posted by benwaggoner View Post
I use ctu 64 regularly without any issues. In the early days I did see some reproable quality issues with ctu 64 sometimes, but it's been years.
That one is definitely reproducable with that sample clip of mine, and it's not so long ago. Actually when they implemented the new rskip options some time ago.
__________________
And if the band you're in starts playing different tunes
I'll see you on the dark side of the Moon...
Boulder is offline   Reply With Quote
Old 2nd February 2021, 19:16   #54  |  Link
Boulder
Pig on the wing
 
Boulder's Avatar
 
Join Date: Mar 2002
Location: Finland
Posts: 5,610
Quote:
Originally Posted by Nico8583 View Post
What are the default values ? ctu=64, limit-tu=0 and rskip ?
The default depends on the preset. --limit-tu is 4 or 0, ctu 64 and rskip 1.
__________________
And if the band you're in starts playing different tunes
I'll see you on the dark side of the Moon...
Boulder is offline   Reply With Quote
Old 2nd February 2021, 20:11   #55  |  Link
Nico8583
Registered User
 
Join Date: Jan 2010
Location: France
Posts: 842
Quote:
Originally Posted by Boulder View Post
The default depends on the preset. --limit-tu is 4 or 0, ctu 64 and rskip 1.
Thanks, I'm watching the preset values to compare
Nico8583 is offline   Reply With Quote
Old 2nd February 2021, 20:15   #56  |  Link
Nico8583
Registered User
 
Join Date: Jan 2010
Location: France
Posts: 842
A last question to be sure : if I use a 3700X (8 cores / 16 threads) with x265's default settings, just --preset slow (it's an example), it will produce an encoded file. If I use a 3900X (12 cores / 24 threads) with x265's default settings --preset slow, it will produce a different encoded file because core number is higher, right ?
Now if I use a 5800X (8 cores / 16 threads), is the produced file will be exactly the same than the 3700X encoded file ? Because there are both 8 cores 16 threads ?
Nico8583 is offline   Reply With Quote
Old 2nd February 2021, 21:01   #57  |  Link
DJATOM
Registered User
 
DJATOM's Avatar
 
Join Date: Sep 2010
Location: Ukraine, Bohuslav
Posts: 376
I'm not sure if results are deterministic at all... But yeah, bitrate should be the same in all cases.
__________________
Me on GitHub
PC Specs: Ryzen 5950X, 64 GB RAM, RTX 2070
DJATOM is offline   Reply With Quote
Old 2nd February 2021, 22:51   #58  |  Link
apophis906
Registered User
 
Join Date: Apr 2009
Posts: 26
Quote:
Originally Posted by Nico8583 View Post
A last question to be sure : if I use a 3700X (8 cores / 16 threads) with x265's default settings, just --preset slow (it's an example), it will produce an encoded file. If I use a 3900X (12 cores / 24 threads) with x265's default settings --preset slow, it will produce a different encoded file because core number is higher, right ?
Now if I use a 5800X (8 cores / 16 threads), is the produced file will be exactly the same than the 3700X encoded file ? Because there are both 8 cores 16 threads ?
The files will be the same as long as the settings are the same. I have tested on an i3-2700M, a i7-6700, and 3700x. The same test file with the same settings ends up the exact same output in bitrate and size. The difference is in the time it takes to encode it.
apophis906 is offline   Reply With Quote
Old 3rd February 2021, 05:49   #59  |  Link
Nico8583
Registered User
 
Join Date: Jan 2010
Location: France
Posts: 842
Thank you and you changed --frame-threads and --lookahead-threads values in your settings ?
Nico8583 is offline   Reply With Quote
Old 3rd February 2021, 07:22   #60  |  Link
apophis906
Registered User
 
Join Date: Apr 2009
Posts: 26
Quote:
Originally Posted by Nico8583 View Post
Thank you and you changed --frame-threads and --lookahead-threads values in your settings ?
No I left them on auto. So the i3 has 2 frame threads and 4 thread pool, the i7 has 3 frame threads and 8 thread pool, and of course the 3700x has 4 frame threads and 16 thread pool. From the testing I have tried it looks like the output is the same with more cores. The only time I have ever seen a different output was when trying out setting it to 1 frame thread, 2 and up give the same results. So I would think that a 16 core would produce the same output as an 8 core with the same settings.
apophis906 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 00:33.


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