Inspect the CPU to determine number of threads to use while processing
markolson opened this issue · 1 comments
markolson commented
Right now it's hardcoded as 8 ffmpeg processes to run in parallel so speed up the frame grabbing. Until ffmpeg is directly incorporated, I have to be more careful that the number of threads is below the number of cores on the CPU.
pachacamac commented
You could use one of these methods:
grep -Ec 'processor\s+\:' /proc/cpuinfo
nproc
lscpu -p | grep -Ecv '^#'
tested on Xubuntu Linux ...