~/talk

Redlining Your CPU for Fun and Profit: Threading and Multiprocessing in Python

Talkat PyOhio 2021 · on Saturday, 2021-07-31· [python, concurrency]
slides:none on file

Shows how to swap a simple for loop for concurrent.futures and get real parallelism using ProcessPoolExecutor for CPU‑bound primes (two lines changed to .map) and ThreadPoolExecutor for IO using .submit and futures.as_completed. Explains future.result blocking semantics, default worker counts and context manager usage, and when to prefer processes vs threads or a hybrid. Demonstrations claim noticeable speedups and drive CPU to near 100%.

AI-written summary · about

~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.