View Full Version : KNLMeansCL: OpenCL NLMeans de-noising algorithm [2018-01-29]
videoh
26th November 2017, 13:40
The source file you linked is an MKV but your script shows you opening a VOB and you said you get issues with DGIndex but it cannot open MKV. So can't help you with this.
Sharc
26th November 2017, 15:34
I tried DGIndex but there were still some glitches, for example the luma frame changed as it should but the chroma frames remained the same. I got an ASUS 1050 2GB, the encoding time is now 8fps and for some reason the glitches disappeared also :)
What do you mean by glitches? Your source.mkv has badly blended even and odd fields. I doubt that you can get anything useful out of this ....
pcroland
26th November 2017, 20:58
The source file you linked is an MKV but your script shows you opening a VOB and you said you get issues with DGIndex but it cannot open MKV. So can't help you with this.
I used mkvtoolnix to cut out a 1min sample, sorry :D
What do you mean by glitches? Your source.mkv has badly blended even and odd fields. I doubt that you can get anything useful out of this ....
I know there's a terrible fieldblend, the glitches that I was talking about: in the encode.mkv file you can see frames flipping upside-down randomly in the first 5 sec. But now it's fixed, thanks for the help.
Khanattila
27th November 2017, 11:00
There are a bunch of potential culprits for the glitches. First and foremost, DirectShowSource is the worst choice for your source. Use DGIndex/DGDecode for VOB.
If that doesn't solve the glitch problem, test each of the filters/functions separately.
Yes, get a decent card (GTX1060/70/80).
Or a Vega card, when I can buy one.
lordsmurf
7th December 2017, 12:28
For me, any filter that cannot get about 1 fps is a unusable. I simply don't have multiple days to devote to any individual film or video. Life is full of "engineering trade-offs," and performance does matter.
This was my same conclusion. It has a lot of potential -- but in the next decade sometime, when CPU and/or GPU is faster. I've already been through this -- 90s filtering not usable until 2000s, 00s filter not until 10s. Right now, it's little more than a tease.
Goodbye KNLmeansCL, may we meet again! :)
TheFluff
7th December 2017, 12:35
it was a while since I used knlmeanscl but I believe last time I tried it, it was pushing somewhere around 25 fps, and that was on a computer that is now five years old (i5-3570k, gtx... 670? I think?)
you can be in the next decade right now if you want to, is what I'm sayin'
Groucho2004
7th December 2017, 12:46
it was a while since I used knlmeanscl but I believe last time I tried it, it was pushing somewhere around 25 fps, and that was on a computer that is now five years old (i5-3570k, gtx... 670? I think?)
you can be in the next decade right now if you want to, is what I'm sayin'
Talking about decades - Even my old GT240 which I bought almost a decade ago delivers reasonable speed with KNLMeansCL if the parameters are set to sane values.
If you're getting < 5fps you're either using unreasonable settings or you should consider updating your hardware. Otherwise just forget about GPU filters.
By the way - Intel integrated graphics are utterly useless for OpenCL.
Sharc
7th December 2017, 13:22
Those with a NVIDIA GPU may also want to try DGDenoise(), as an alternative to KNLmeansCL
lordsmurf
7th December 2017, 15:17
it was a while since I used knlmeanscl but I believe last time I tried it, it was pushing somewhere around 25 fps, and that was on a computer that is now five years old (i5-3570k, gtx... 670? I think?)
you can be in the next decade right now if you want to, is what I'm sayin'
You're not going to get 25fps from this:
SetFilterMTMode("DEFAULT_MT_MODE", 2)
AVISource("BadToonSample.avi")
ConvertToYV16(interlaced=true)
orig=last
ev=orig.assumetff().separatefields().selecteven()
od=orig.assumetff().separatefields().selectodd()
ev
ue_chroma = UToY(ev).blur(0,1.5).binomialblur(5).ttempsmooth(maxr=6,lthresh=150, strength=6).KNLMeansCL(d=3,
\ a=8, h=6, device_type = "GPU", device_id = 1, channels="Y")
ve_chroma = VToY(ev).blur(0,1.5).binomialblur(5).ttempsmooth(maxr=6,lthresh=150, strength=6).KNLMeansCL(d=3,
\ a=8, h=6, device_type = "GPU", device_id = 1, channels="Y")
YToUV(ue_chroma, ve_chroma)
MergeLuma(ev)
ev_filtered=last
od
uo_chroma = UToY(od).blur(0,1.5).binomialblur(5).ttempsmooth(maxr=6,lthresh=150, strength=6).KNLMeansCL(d=3,
\ a=8, h=6, device_type = "GPU", device_id = 1, channels="Y")
vo_chroma = VToY(od).blur(0,1.5).binomialblur(5).ttempsmooth(maxr=6,lthresh=150, strength=6).KNLMeansCL(d=3,
\ a=8, h=6, device_type = "GPU", device_id = 1, channels="Y")
YToUV(uo_chroma, vo_chroma)
MergeLuma(od)
od_filtered=last
interleave(ev_filtered,od_filtered)
assumefieldbased().assumetff().weave()
Prefetch(6)
KNLMeansCL will make the script crawl at about 1fps.
It's an ugly nth gen video with horrible chroma errors. I wrote a script that will suffice, with about 10fps, but the above is better -- but only in quality, not speed. The 1-hour video would take 165+ hours to process, which is not reasonable.
you should consider updating your hardware. Otherwise just forget about GPU filters.
My i7-6700K with 16gb RAM doesn't need updating. I'm not a gamer, and have no need for expensive graphics cards. Furthermore, all those cards do is add room heat, as well as fan noise.
I can borrow a card, but I don't think it's going to give a usable performance boost. This is just a slow filter, GPU or not.
Feel free to test the above script, share your fps results. :)
Can anything replace KNLmeansCL for the sake of speed?
Groucho2004
7th December 2017, 16:03
KNLMeansCL will make the script crawl at about 1fps.Hardly surprising with 4 calls to the filter and d=3, a=8. Even a GTX1080 would struggle.
Not to mention that you're running it in 6 threads which just consumes GPU memory and probably slows it down even further.
Groucho2004
7th December 2017, 16:10
Furthermore, all those cards do is add room heat, as well as fan noise.Do you think if you offload your filtering needs to the CPU it will create less heat?
lordsmurf
7th December 2017, 16:42
Hardly surprising with 4 calls to the filter and d=3, a=8. Even a GTX1080 would struggle.
Not to mention that you're running it in 6 threads which just consumes GPU memory and probably slows it down even further.
Correct. Sometimes filters need to be stacked to be useful. Doing so makes them unusable. Been there, done that. But time changes that, and eventually stacking is negligible. Been there, done that too.
I deal with videos that others consider impossible. But sometimes "impossible" is merely a temporary state.
Do you think if you offload your filtering needs to the CPU it will create less heat?
Since I'd rarely use the card's GPU, yes. The CPU isn't running 100% 24/7/365, as I'm not encoding constantly. But a video card would be on 24/7/365, thus heat and noise, neither of which are needed or wanted.
lansing
7th December 2017, 16:43
KNLMeansCL will make the script crawl at about 1fps.
It's an ugly nth gen video with horrible chroma errors. I wrote a script that will suffice, with about 10fps, but the above is better -- but only in quality, not speed. The 1-hour video would take 165+ hours to process, which is not reasonable.
You may look at my short tutorial (https://forum.doom9.org/showthread.php?p=1820984#post1820984) to how to tweak the settings. Your D and A settings are insane. Not even the dragon ball z level set need that high of an A.
Groucho2004
7th December 2017, 16:57
The CPU isn't running 100% 24/7/365, as I'm not encoding constantly. But a video card would be on 24/7/365, thus heat and noise, neither of which are needed or wanted.What do you mean by "a video card would be on 24/7/365"? What applies to the CPU also applies to the graphics card. If they're idle (at least with modern devices), they consume very little power. Your logic is flawed.
Khanattila
7th December 2017, 17:59
This was my same conclusion. It has a lot of potential -- but in the next decade sometime, when CPU and/or GPU is faster. I've already been through this -- 90s filtering not usable until 2000s, 00s filter not until 10s. Right now, it's little more than a tease.
Goodbye KNLmeansCL, may we meet again! :)
A. Buades, B. Coll and J.-M. Morel,
"A non-local algorithm for image denoising",
2005 IEEE Computer Society Conference on Computer Vision and Pattern Recognition.
johnmeyer
7th December 2017, 18:00
I agree that the D & A settings are a major contributor to the slow speed. I've done a lot of performance checks, and setting either of these much above the defaults will slow things to a crawl. Setting them both above the defaults, and you definitely are going to be taking the proverbial slow boat to China.
lordsmurf
7th December 2017, 18:25
What do you mean by "a video card would be on 24/7/365"? What applies to the CPU also applies to the graphics card. If they're idle (at least with modern devices), they consume very little power. Your logic is flawed.
The computer is on 24/7/365, thus so would be a graphics card.
I have no graphics card, and am using the Intel 530 HD graphics built into i7-6700 using Asrock motherboard.
The CPU is extremely cool when idle -- much lower than graphics cards. Right now, it has mild load, and is only at 25. I have a Noctua on it. I think the TDP of an average fancy graphics card is something like 2x-3x that of a CPU. At best, a graphics card would be in the 30s or 40s when "idle", maybe higher. And I put that in quotes because there's really no "idle" on graphics cards, compared to CPUs, it just gets hot or hotter.
It gets worse when you pay extra for a graphics card to heat the room, then pay again to have the AC cool the room, plus all the fan noise from BOTH the graphics card fan and the AC. When I built this rig, cooling and noise was the priority, with an i7-6700K being required for horsepower.
BTW: The Intel 530 does seem to use GPU on KNLmeansCL, even if the OpenCL must be 0 in the script. The GPU is still 3x faster than pure CPU with the above script. GPU is about 15% CPU on 4 threads, while 100% CPU on 8 threads is 3x slower.
You may look at my short tutorial (https://forum.doom9.org/showthread.php?p=1820984#post1820984) to how to tweak the settings. Your D and A settings are insane. Not even the dragon ball z level set need that high of an A.
Insane values for insanely bad nth gen VHS. That wasn't my script, but I'll continue to play with it. So far, trying to lower values would just disable the good it was doing on the video.
Not sure what the Dragonball reference is to.
Groucho2004
7th December 2017, 18:39
Right now, it has mild load, and is only at 25. I have a Noctua on it. I think the TDP of an average fancy graphics card is something like 2x-3x that of a CPU. At best, a graphics card would be in the 30s or 40s when "idle", maybe higher. And I put that in quotes because there's really no "idle" on graphics cards, compared to CPUs, it just gets hot or hotter.
TDP is mostly irrelevant for the idle/load power consumption, it just tells you how much the chip can handle.
Idle consumption of a 1060/70 for example is about 5-7 W, see here (https://www.techpowerup.com/reviews/EVGA/GTX_1070_Ti_FTW2/26.html).
Anyway, I give up. I suggest you try to gather some facts before posting.
lordsmurf
7th December 2017, 18:54
TDP is mostly irrelevant for the idle/load power consumption
I disagree. It's a pretty good guide for what temperatures you can expect, both at idle and 100%. Again, I get 25 from a CPU with mild load, but an "idle" GPU would easily be in the 30s-40s or more, at least doubling my system heat output. TDP suggested it. TDP of that CPU is about 90, while TDP of most fancy graphics cards are well into the 100s-200s.
Groucho2004
7th December 2017, 19:14
I disagree. It's a pretty good guide for what temperatures you can expect, both at idle and 100%. Again, I get 25 from a CPU with mild load, but an "idle" GPU would easily be in the 30s-40s or more, at least doubling my system heat output. TDP suggested it. TDP of that CPU is about 90, while TDP of most fancy graphics cards are well into the 100s-200s.
I can see that measurements and facts are not your thing. Good luck with your future endeavours.
lansing
7th December 2017, 20:00
The CPU is extremely cool when idle -- much lower than graphics cards. Right now, it has mild load, and is only at 25. I have a Noctua on it. I think the TDP of an average fancy graphics card is something like 2x-3x that of a CPU. At best, a graphics card would be in the 30s or 40s when "idle", maybe higher. And I put that in quotes because there's really no "idle" on graphics cards, compared to CPUs, it just gets hot or hotter.
It gets worse when you pay extra for a graphics card to heat the room, then pay again to have the AC cool the room, plus all the fan noise from BOTH the graphics card fan and the AC. When I built this rig, cooling and noise was the priority, with an i7-6700K being required for horsepower.
If your computer can cook a room so hot that you need an AC to counter it, there's something wrong with your cooling solution. My computer sits right next to my mouse-using hand and my hand was ice cold during winter time.
TDP are more correlated to watt usage, it has no relationship whatsoever as to temperature Celsius, your information is wrong. Running 100% of a 250 TDP graphic card does not mean the card goes to 250 degrees Celsius. Most modern cards stayed in the 70s on full loaded.
Insane values for insanely bad nth gen VHS. That wasn't my script, but I'll continue to play with it. So far, trying to lower values would just disable the good it was doing on the video.
Not sure what the Dragonball reference is to.
Something like this (https://i.imgur.com/rxFYf2M.png).
lordsmurf
7th December 2017, 20:18
If your computer can cook a room so hot that you need an AC to counter it, there's something wrong
You must not live in the south, where it's hot almost year round. It was 80 F just 2 days ago, and the AC started running (thermostat set to 79). When you have a computer pumping out heat, and heat outside, life is miserable. A computer does make the AC kick on, and run so much that it can seize. So the goal is to limit heat output as much as possible. A computer can make a room a good 5 degrees hotter minimum, and I've seen it as much as 10 in years past.
TDP are more correlated to watt usage, it has no relationship whatsoever as to temperature
Direct correlation, no. But indirect, yes, absolutely. TDP is a statement about thermal output. There is data to extrapolate there. It's not 100% divorced from heat output.
Running 100% of a 250 TDP graphic card does not mean the card goes to 250 degrees Celsius.
I never said it did.
Most modern cards stayed in the 70s on full loaded.
I've seen cards run well in the 80s or 90s.
I think you're missing my point: Whether it's 70 or even 35, it's more than 0, which is what the computer has now. And I'm better for it. The atypical GPU video filter won't sway me on iota into "upgrading". If really needed, I can borrow one from a gamer I know.
This filter looks great, but no amount of GPU will really give it a usable boost if the filter is being pushed beyond default minimums.
Something like this (https://i.imgur.com/rxFYf2M.png).
That video is absolutely flawless compared to the mess I'm working on.
2005 IEEE Computer Society Conference on Computer Vision and Pattern Recognition.
I refer to the Avisynth filter, not the algorithm. You've made a great filter, ahead of its time. But we lack the horsepower to really push it. Please take that as the compliment it is.
TheFluff
8th December 2017, 00:01
I disagree. It's a pretty good guide for what temperatures you can expect, both at idle and 100%. Again, I get 25 from a CPU with mild load, but an "idle" GPU would easily be in the 30s-40s or more, at least doubling my system heat output. TDP suggested it. TDP of that CPU is about 90, while TDP of most fancy graphics cards are well into the 100s-200s.
I realize that historically I have had absolutely zero success in convincing the various doom9 forums nutjobs I've encountered over the years of anything, but for the record... I currently have, in the computer right next to me, a top of the line graphics card powering my 4k monitor. It's 300mm long, it's got 8GB VRAM, it's got three big honking fans on it, and it'll clock up to somewhere north of 1.9GHz if it needs to. It's got more than twice the TDP of my CPU, at an impressive 180W. As you can see, this monster is turning the room into a sauna even when idling:
https://i.imgur.com/5a9i6t1.png
oh. uh. well.
The fan readout isn't bugged by the way, the card has a ginormous heatsink on it and the fans are intentionally stopped when the GPU is near idle.
Compare this to the old faithful i5 CPU which is actually using more power (almost a whole watt more! what a waste!) and running its fan at a few hundred RPM:
https://i.imgur.com/0MZCgaN.png
Also, lol at the idea of even trying to measure the heating effect the dissipation of these monstrous 30-ish watts of energy has on an entire room. An oldschool light bulb in a desk lamp would put out more heat! Even 300 watts is pretty much peanuts when it comes to space heating. It's an absolutely trivial amount of heat in relation to the thermal inertia of even a small apartment.
real.finder
8th December 2017, 00:20
what about new high-end laptops? it will not use the dedicated gpu and use the one in the cpu when idle or even using light things
lordsmurf
8th December 2017, 00:49
heating effect the dissipation of these monstrous 30-ish watts of energy has on an entire room. An oldschool light bulb in a desk lamp would put out more heat!
It's all additive. This is a main reason we keep lights off when possible, quiet ceiling fans on low/silent. The CFL are supposedly cooler, but some bulbs seem to output just as much heat. Replacing TVs with LCD in the past decade has helped.
After I built this Skylake, it was the first winter where the room actually got chilly a few times.
The 47-C vs 39-C somewhat illustrates my point. It's 20% hotter, even understanding the older Intels weren't all that cool (though AMD was worse). Additively speaking, it's 120% hotter, for both CPU and GPU. With no graphic cards, it'd be 50% cooler. Newer CPU would probably cool that even more, especially if using a Noctua.
TDP of that GPU = 180
TDP of that CPU = 77
Not direct correlation for heat output, but not unrelated. Give both mild load, and that GPU will be curve up far quicker than the CPU. At some point in the graph, it probably will run almost twice as hot.
GPUs would probably run a bit cooler at idle if fans didn't stop at idle, which I've never understood.
It's just a penalty of having a card. I don't need one. I don't need to upgrade for video encoding. Almost nothing takes advantage of GPU encoding, and never did, and has mostly been hype to date.
It is what it is.
what about new high-end laptops? it will not use the dedicated gpu and use the one in the cpu when idle or even using light things
I like stuff like this. There when needed, not when not. That's the future. We have V8s that cut off 4 cylinders (Chargers), and it'd be nice to see desktop have similar switching abilities. No idea how that'd be engineered.
Another neat item for next decade. :)
TheFluff
8th December 2017, 01:11
I don’t think you understand how any of this works. Thermodynamically speaking almost all the electrical energy going into the computer will be converted to thermal energy. If the GPU and the CPU are using the same amount of energy but one is hotter than the other because it’s not running its fans, then that means it’s actually transferring less energy to the surrounding air (and by extension, heating your room less). The temperature of the silicon really isn’t interesting at all here. An incandescent 40W light bulb has a wire heated to over 2000 degrees Kelvin in it, and yet it’s sure as heck not putting out more than 40W of heat. Physics!
Here’s a topical but completely pointless bit of trivia: an average human body dissipates an average of around 100W of energy as heat. Slow your metabolism and eat less to make your room less hot!
lordsmurf
8th December 2017, 01:52
You may look at my short tutorial (https://forum.doom9.org/showthread.php?p=1820984#post1820984) to how to tweak the settings. Your D and A settings are insane. Not even the dragon ball z level set need that high of an A.
Update: :D
So I pulled back KNLmeansCL settings as much as possible, attacking only the worst of the video. It still needs a lot of work, but I'm getting about 10fps using the Intel GPU with MT in x64 Avisynth+.
I can attack the remaining issues with faster filters. None are as good as the pure KNLmeansCL in terms of end result quality, but will suffice.
Thanks for the tips.
I don’t think you understand how any of this works. Thermodynamically speaking almost all the electrical energy going into the computer will be converted to thermal energy.
As far as TDP/heat/etc:
A 40W bulb also has no fan, but the heat emanates into the room. The computer has ventilation, the computer is a conductor, the card has ventilation, heat emanates out the card, thus into the room. Also science.
And you're still missing my point. Having no card = 0, any card = more than 0. The card will expel heat, be it passively or actively (fan). I want a compute to compute, not double as a room heater in the summer. Because it does raise a room by at least 5 degrees here, if not more. If you're in New York or Colorado or Canada or somewhere, you may not run into that problem.
Again, TDP isn't a direct measure of heat expelled by a given system. But it's also not a measurement of mere power consumption. For example, given the TDP numbers against your heat measurement, I have to wonder if the CPU heatsink is inadequate, or needs a re-seat/re-paste. That's what the numbers tell me. It also tells me to expect the GPU to run hotter, though probably not 2x hotter realistically. Those are why the numbers exist.
Anyway, whatever... I have encoding to do now. :)
yup
8th December 2017, 12:44
lordsmurf!
Some time ago I am spoken author about paper also. After some test and try I am found that for interlaced source (fields) better value for s=1, for s=2 (default value) filtered image will be more softer.
Decreasing s from 2 to 1 increasing speed. Also for color planes (not luma) can using easy setting.
yup.
pinterf
8th December 2017, 13:10
The 47-C vs 39-C somewhat illustrates my point. It's 20% hotter,
Never divide temperature values in Celsius, if necessary, do it in Kelvins. You'll get a 2,5% instead. (But what really counts, the excessive heat, it is the deltaT)
lordsmurf
8th December 2017, 16:13
lordsmurf!
Some time ago I am spoken author about paper also. After some test and try I am found that for interlaced source (fields) better value for s=1, for s=2 (default value) filtered image will be more softer.
Decreasing s from 2 to 1 increasing speed. Also for color planes (not luma) can using easy setting.
yup.
Thanks. I'll remember that.
Unfortunately, this time, it didn't make any noticeable difference on quality or speed. It may simply be due to this clip and the longer 4x call script.
Never divide temperature values in Celsius, if necessary, do it in Kelvins. You'll get a 2,5% instead. (But what really counts, the excessive heat, it is the deltaT)
:goodpost:
TheFluff
8th December 2017, 21:26
Again, TDP isn't a direct measure of heat expelled by a given system. But it's also not a measurement of mere power consumption. For example, given the TDP numbers against your heat measurement, I have to wonder if the CPU heatsink is inadequate, or needs a re-seat/re-paste. That's what the numbers tell me. It also tells me to expect the GPU to run hotter, though probably not 2x hotter realistically. Those are why the numbers exist.
That's not how TDP works. That's not how any of this works!
Clearly, it's time for
Thermodynamics 101
with T. Fluff, PhD
(I hold a doctorate in The Science of Telling People they are Wrong on the Internet)
Let's review the fundamentals first, yeah? This is all high school physics, so you should probably know this. The laws of thermodynamics tell us two important things relevant to this discussion, namely that
a) energy can never be created or destroyed (so if we put some energy into a system we must get the same amount of energy out), and
b) entropy tends to increase, so if you have two bodies with different temperatures in thermic contact with each other energy will flow from the hotter one to the colder one until they reach equilibrium.
Now on to what this means in practice. In a computer, we input electrical energy. Some of this energy is converted to kinetic energy (to spin harddrive platters and fans), and some is converted to electromagnetic radiation mainly in the form of visible light (in LED's and in the monitor), but the vast majority of it eventually decays to thermal energy after being used to push some electrons around through a bunch of transistors. This heat has to go somewhere, and that somewhere eventually ends up being the air of the room. In a moment, we will calculate the magnitude of this effect, but first we need to clear up a misconception.
The TDP of a processor is an estimated ballpark number of the amount of thermal energy it generates in a given fictive scenario that's supposed to represent a typical peak workload. In any other scenario (such as most scenarios you'll find in reality), the actual amount of heat generated is different - the TDP is only supposed to be a rough estimate of the maximum sustained heat generation possible. The TDP number has absolutely nothing to do with any of the following:
- amount of heat generated at idle
- amount of electrical power consumed at idle
- temperature of the silicon in any given situation
In practice, the amount of thermal energy generated by a processor is pretty much equivalent to its electrical power consumption because almost all of the electrical energy quickly decays to heat. The first law of thermodynamics also tells us that we cannot possibly get more thermal energy out of a processor than the amount of electrical energy we put into it. If you look at the processor's power consumption then, you will have a good idea of how much heat it's producing. Modern CPU's and GPU's are very good at clocking down (and more importantly, reducing the voltage) at idle and so you'll see a typical idle power consumption of 10-20 watts. The power consumption - and by extension, thermal energy generation - still doesn't have anything to do with the temperature of the chip, though. See, temperature is a measure of energy, but it's a measure of stored energy. Two chips consuming the same amount of electrical energy will heat your room exactly the same, even if one is twice as hot as the other. The only thing that's different in the hotter chip is that the energy stays in it for longer before dissipating into the room.
Speaking of energy storage, to calculate the heating effect of an idling CPU we first need to discuss specific heat capacity. Different substances can store different amounts of thermal energy, and the specific heat capacity is a measure of how much energy a substance can store per unit mass. Or, in more practical terms - heating one kilogram of water by one degree Kelvin takes about four times as much energy as heating one kilogram of air by one degree Kelvin. Many metals have very low specific heat capacity, meaning it takes little energy to heat them up, but conversely that also means they're bad at retaining that energy and they quickly cool down again. For example, copper (commonly used in heatsinks because of its excellent thermal conductivity) has a specific heat capacity of 0.385 J/gK (joules per gram kelvin difference - it takes 0.385 joules of energy to heat one gram of copper by one degree kelvin). Air at typical indoor conditions has a specific heat capacity of about 1.01 J/gK.
If we then assume a spherical CPU in a vacuum... uh, no, I mean, a small 30 square meter studio apartment with the minimum indoor ceiling height of 2.4 meters allowed by the building code in these parts, we can easily calculate that the 72 cubic meters of air inside weighs around 92 kilograms. Given the previously discussed specific heat capacity, heating 92 kilograms of air by one degree kelvin (or equivalently in this case, one degree celsius) takes 92.9 kilojoules of energy. Now, a watt is a joule per second, so an idling CPU consuming 10 watts of energy would take 9290 seconds (or close to 2 hours and 35 minutes) to heat the apartment by one degree kelvin. Do note though that this of course assumes completely unrealistic conditions, for example that the apartment is perfectly thermally insulated against the outside world, so it is of course necessary for there to be no ventilation whatsoever. The building code here demands that the ventilation of private dwellings should change the indoor air at least once every two hours, making the job of that idling CPU a Sisyphean task.
So, in conclusion, no, my heatsink isn't inadequately fastened, and the TDP has nothing to do with this at all. I could easily transfer the heat out of the CPU quicker and thereby making it cooler by running the CPU fan faster, but why on earth would I? There's absolutely no reason to.
cork_OS
8th December 2017, 22:10
In other words, TDP is just requirement for cooling system.
Note that modern CPUs (and GPUs) could easily exceed TDP index under heavy load (AVX-512 etc.), but integrated current/power meters and forced clock drop won't let them do so.
lordsmurf
9th December 2017, 10:38
And yet, you can't explain why a computer left on 24/7/365, using components with high TDP, will raise room ambient temperature by at least 5 degrees. Whereas components with low TDP will not do so, a mild 1 degree bump at most.
Please, Dr. Physics, explain that one.
TheFluff
9th December 2017, 14:38
And yet, you can't explain why a computer left on 24/7/365, using components with high TDP, will raise room ambient temperature by at least 5 degrees. Whereas components with low TDP will not do so, a mild 1 degree bump at most.
Please, Dr. Physics, explain that one.
lol
One weird trick, discovered by a Doom9 forums poster, lets you violate the laws of thermodynamics. Physicists HATE him!
f'in tdp's, how do they work???
lordsmurf
9th December 2017, 15:36
lol
One weird trick, discovered by a Doom9 forums poster, lets you violate the laws of thermodynamics. Physicists HATE him!
f'in tdp's, how do they work???
Yeah, I thought as much. No answer.
As I said, TDP has a very obvious correlation to actual heat output. TDP isn't a measure of it, but it must be closely related. Accumulated TDP can be a good guide to how hot your computer will be, specifically monitoring an increase in ambient temperature in the room.
If I can lower room temps by a few degrees, simply by NOT buying an expensive/fancy graphics card, I'm better for it. If watching the TDPs help me make smarter/cooler purchases, then that's what I'll do. So far, that's worked perfectly. Not everybody live in Canada or wherever, where years-round temps are measured in snowfall inches. We must pay close attention to how a computer heats the dwelling.
This is a thread about KNLmeansCL, not TDP.
I've stripped KNL down to base settings, am getting 10fps now, and have moved on. I suggest you do the same.
TheFluff
9th December 2017, 23:44
I'm amused how the "experts" of this Doom9 thread just won't let this go. It's a thread about KNLmeansCL. I've stripped it down to base settings, am getting 10fps now, and have moved. I suggest you do the same.
No dude, you don't get to pretend to be the bigger man here and move on while rolling your eyes at these silly "experts" with their "science". You went spouting off nonsense in an authoritative tone and now you're trying to weasel out of being dumb on the internet. I won't stand for it.
I'm not trying to hurt you, I'm not trying to sell you a GPU, I'm not trying to convince you to use KNLMeans, I'm not even trying to dispute your apartment temperature numbers. I only want you to understand why nothing you're saying makes any sense. I will not accept you claiming that you'd prefer to believe in literal magic because you don't understand basic physics. I also really doubt you've made the ambient temperature experiment under controlled conditions, so I really don't think you're getting much mileage out of "thinking for yourself".
As I said, TDP has a very obvious correlation to actual heat output. TDP isn't a measure of it, but it must be closely related. Accumulated TDP can be a good guide to how hot your computer will be, specifically monitoring an increase in ambient temperature in the room.
See, you're so close and yet you are a galaxy away. The TDP number is a quite good measure of the actual heat output! AT MAX LOAD, that is. Back in the bad old days with Pentium 4's and such things, it actually kinda did tell you something about idle power consumption (and therefore heat output - as I have previously shown, they are effectively the same) as well, because processors in those days were really bad at clocking down and if you were lucky they could cut their power consumption in half while idling, maybe. Today this is no longer the case and everything clocks down to use like 10-15 watts at idle. A high TDP processor has the potential to put out more heat, but at idle there's no difference - see my screenshots above that are showing the same power consumption (and therefore heat output) of two different chips where one has more than twice the TDP of the other.
You can plug in a watt meter into the wall socket and then plug the computer into that if you're actually curious about this. They're like 25 bucks on Amazon. You will then notice that your power consumption at idle is a lot more than just the CPU's idling power consumption (because there's other stuff using power in the computer as well, and the PSU is only about 80-90% efficient at converting wall socket AC to low voltage DC), but also that if you actually put your computer under load, power consumption will immediately increase significantly, and there's the difference between idle power and TDP. In practice you can see the computer as an electrical space heater; effectively all of the electrical energy it is using gets turned into thermal energy.
I think you're suffering from the misconception that the temperature of the components is interesting for some reason. It's not. It is true that a higher temperature difference between a hot thing and the ambient air increases the rate at which energy is transferred from one to the other, but in this case we're talking about a steady state situation: we're inputting a constant amount of energy per second into the chip, and it's transferring exactly that much energy into the surrounding air per second. If it was transferring less energy out than it was receiving, it would become hotter, because it would be storing more energy.
- If you can explain this, great! I'm all ears.
- If not, STFU.
Of course I can't explain the conditions in your apartment with your computer without any details about it. For all I know you might have turned off the CPU power saving features in the BIOS and are always running at full power consumption.
LigH
9th December 2017, 23:53
And yet, you can't explain why a computer left on 24/7/365, using components with high TDP, will raise room ambient temperature by at least 5 degrees. Whereas components with low TDP will not do so, a mild 1 degree bump at most.
Please, Dr. Physics, explain that one.
Maybe because the walls of the room cool it down faster than the PC can heat it up?
lordsmurf
9th December 2017, 23:54
now you're trying to weasel out of being dumb on the internet.
Sigh. No. I came to the KNLmeansCL threads to talk about the filter, not this BS. I've mostly resolved that encoding speed issue. You're the one that keeps harping on TDP, and my statement of not wanting a graphics card because it add 5 degrees of heat to the room.
Back in the bad old days with Pentium 4's and such things
TDP is somewhat gamed like megapixels in cameras, and has been for years. CPUs can get hotter than the TDP, and TDP doesn't reflect maximum heat output. But it is a gauge of heat nonetheless. And that heat goes somewhere (ie, the room with the computer). A hotter TDP item rarely outputs less heat than lower TDP item, even at idle.
your apartment
Not where I live. You're assuming too much.
you might have turned off the CPU power saving features in the BIOS and are always running at full power consumption.
More assumptions.
Maybe because the walls of the room cool it down faster than the PC can heat it up?
Huh?
LigH
9th December 2017, 23:58
Please, please, concentrate more on technical than personal topics.
Some of our moderators here are quite strict when it comes to violating the Netiquette.
lordsmurf
10th December 2017, 00:15
Please, please, concentrate more on technical than personal topics.
Gladly! :)
One thing I noticed when trying to cut down the KNL settings (for speed) was that adjusting A=2 to A=1 seems to massively cut down on it's effectiveness, yet encoding speed remained almost unchanged. I didn't see why that would happen.
Also, the s=1 syntax suggestion from default s=2 did nothing.
I'm partially assuming it's related to the 4x calls from the script, or the horrible video where it was used.
TheFluff
10th December 2017, 00:38
You're the one that keeps harping on TDP, and my statement of not wanting a graphics card because it add 5 degrees of heat to the room.
If you don't want a GPU, fine! I'm not a GPU salesman. I'm not trying to say it's wrong to not have a GPU. Claiming an idling GPU will add five degrees (are we even talking Celsius here or what?) to your room temperature is physically possible but I'd call it extremely goddamn unlikely to be true.
TDP is somewhat gamed like megapixels in cameras, and has been for years. CPUs can get hotter than the TDP, and TDP doesn't reflect maximum heat output. But it is a gauge of heat nonetheless. And that heat goes somewhere (ie, the room with the computer).
It's not "gamed" - it's an engineering classification, not an empirically measured number. Maximum heat output is exactly what it reflects, although again it's not an exact measurement but rather a nice round ballpark number intended for estimating how much cooler you'll need.
A hotter TDP item rarely outputs less heat than lower TDP item, even at idle.
This statement is exactly what I'm taking issue with. A processor will output not output even a milliwatt more thermal energy than the electrical energy it is consuming, and I've already shown you exact power consumption numbers at idle. This is fundamental thermodynamics. If you refuse to accept this you are rejecting physics as a whole and effectively believe in magic.
Please, please, concentrate more on technical than personal topics.
Some of our moderators here are quite strict when it comes to violating the Netiquette.
lol this forum is barely moderated at all
tebasuna51
10th December 2017, 11:18
lol this forum is barely moderated at all
Well, it is amusing that kind of discussions, seems you have enough time in your lifes.
BTW if Khanattila (thread owner) want I can delete some off topic posts (or create a new thread about temperature).
Khanattila
16th December 2017, 16:00
Well, it is amusing that kind of discussions, seems you have enough time in your lifes.
BTW if Khanattila (thread owner) want I can delete some off topic posts (or create a new thread about temperature).
I do not care.
Groucho2004
16th December 2017, 16:04
I can delete some off topic posts (or create a new thread about temperature).Either option would probably be appreciated by most users. Just my 2c.
real.finder
16th December 2017, 17:28
create a new thread about temperature is better in my opinion
Atak_Snajpera
17th December 2017, 18:42
Why does KNLMeansCL v1.1 throw this error (i'm using avisynth+MT)
http://i.cubeupload.com/7wHX3w.png
script
video=FFVideoSource("E:\_Video_Samples\mp4\Sony_4K_HDR_Camp.mp4") //420p10 source
video=ConvertToYUV444(video)
video=KNLMeansCL(video,d=1, a=2, s=4, h=4, device_type="CPU", device_id=0)
http://i.cubeupload.com/SDu15t.png
Khanattila
19th December 2017, 18:27
Another bug? Possible.
Khanattila
3rd January 2018, 17:56
First of all, happy new year :)
Good, let's get back to release updates.
Contrary to what I had planned the v1.1.* branch will have update (bugfixes) because the main changes that I would like to implement are really taking me longer than expected.
Let's make a list of known bugs:
- clc compile error with OCL 1.2 (fixed);
- Broken frame on first request (Bug don't happen when running with d=0, without rclip or inside MP_Pipeline);
- Low values of ref clip cause dimmed borders;
- Don't work with AMD RX Vega GPU;
- Wrong message with YUV444P10 input (fixed)(Atak_Snajpera)
- AviSynth+ YV24 native format bug (fixed)(MysteryX)
Khanattila
29th January 2018, 16:32
https://github.com/Khanattila/KNLMeansCL/releases/tag/v1.1.1
KNLMeansCL v1.1.1
* Added more check of rclip.
* Fixed build programm error in some circumstances.
* Fixed Avisynth YUV444P10 video format.
* Fixed Vapoursynth RGB30 video format.
* Fixed clip processing with higher resolution than 4K.
Enjoi.
tormento
29th January 2018, 17:58
KNLMeansCL v1.1.1
First of all, thanks.
I use it as prefilter with SMDegrain.
Any idea of why video output size changed?
From changelog, nothing gives hints. :confused:
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.