How to use only one core when encoding #54
-
Hi, I'm a bit new to the Python language, so I would like to know if when coding in a .heif/heic image I can use a single core/thread of my CPU, because I don't want my processor to be at 100% in a task like this. Thanks and sorry for my bad English. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
@LePistole-glitch im = Image.open("input.png")
im.save("output.heic", enc_params={"x265:pools": "0"}) Note: Since Starting with version |
Beta Was this translation helpful? Give feedback.
@LePistole-glitch
Hi, of course you can pass encoding options to
.heif/.heic
for thex265
encoder. I don't think it's all tested, I'm doing some small autotests on it, but this is the first question about encoder options.So if something doesn't work, ask in this repository and we'll see what's wrong.
Here is a thread control option i found: option-pools
Note: Since
x265
is a video encoder and we are working with images, we are always working with one frame.Starting with version
0.9.0
I will add simpler options for this and for managing number of decode threads, stay tuned.