The maximum parallel processes can you run on computer is based on the number of processors or cores in your computer. To find number of processors or cores in your computer, cpu_count() function is used.
import multiprocessing as mp
print("Number of processors: ", mp.cpu_count())
import multiprocessing as mp
print("Number of processors: ", mp.cpu_count())
No comments:
Post a Comment