Concurrency and Process Modules
multiprocessing.dummy
Thread-backed version of much of the multiprocessing interface, useful when shared-memory threads suit the workload. Its Pool returns a ThreadPool rather than child processes, so process isolation and CPU parallelism assumptions do not carry over.
Formal Syntax & Structure
python syntaxpython
import multiprocessing.dummyReturn Value
module
Module namespace available through import; import is a statement, not a value-returning expression.
Working Example
Example Snippetpython
from multiprocessing.dummy import Poolwith Pool(2) as pool: print(pool.map(abs, [-2, 4]))