Closed mozfreddyb closed 4 years ago
@mozfreddyb You are correct. Actually, it has to do with the constant polling of the xinput
.
You may reduce the cycle time to lessen CPU load. (I already did but for some machines, this may not be enough.)
Maybe there is a much better way to go about the whole program logic which does not task the CPU that much. But right now I do not know any better.
cycle time? This is the time.sleep(0.1)
in line 168, I suppose?
Yes. Just use 1
as an argument and see how it affects the CPU load.
Maybe you could make the value depending on settings, which would allow it to become more easily
adjusted. Perhaps even by command line argument.
I'll give it a try, thanks!
Closing this in favour of a more actionable isssue: #14
I sometimes observe very high CPU load on the python script, but have no way so far to debug or reproduce. I'll consider this issue an "early warning" and will fill in with more information as it becomes available.
@bfelder, can you give me any suggestions what I can do to turn this issue into something more actionable?