Skip to content

kirkdotcam/py-multiprocess-experiments

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 

Repository files navigation

threading vs multiprocessing in python

  • threading in python is slower due to the GIL
  • threading is better for IO-bound (waiting for input, such as a database or network call) applications
  • multiprocessing is better for CPU-bound applications (single-core is slow)
  • thradeoff for multiprocessing is that you need MUCH more ram to hold multiple copies of your data
  • consider turning off swapiness if disk IO becomes a limitation

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages