Outputting the number of CPU cores in both Python 3 and 2 is the same flow. However, I don't really know when to use it ...
>>> import multiprocessing
>>> multiprocessing.cpu_count()
8
The above example is when trying with a 4-core CPU (Intel Core i7-3740QM) equipped with HTT.
Recommended Posts