Season 02 - Introduction to Python Programming
Multi Threading & Multi Processing! ( Conceptual & Coding - In Demo)
Aspect | Multi Threading | Multi Processing |
---|---|---|
Execution Model | Multiple threads within a single process | Multiple processes, each with its own memory |
Memory Sharing | Shared memory space | Separate memory spaces |
Overhead | Lower | Higher |
Communication | Easier (shared memory) | More complex (inter-process communication) |
Use Case | I/O-bound tasks | CPU-bound tasks |
Stability | Less Stable ( shared memory risks ) | More Stable (isolated processes) |
Performance | Efficient for tasks requiring shared data | Efficient for parallel processing tasks |
- Scraping 100 websites in one go!
- Computing square-root for 10000000000 numbers!
:)