Understanding Python: Multiprocessing

preview_player
Показать описание
In this video, I go over multiprocessing.
Included in the lesson is an introductory tutorial covering the basics, background, and some best practices of multiprocessing.
As always, if you have any questions or suggestions for future videos, please leave a comment down below.

Timelapse music: 失望した by Eva
Outro music: Elix by Synthness
Рекомендации по теме
Комментарии
Автор

I have a lingering doubt with respect to concurrency (more so with the threading library). The GIL. I cannot quite wrap my head around the internals that doesn't allow Python to achieve true parallelism via multi-threading. People often whip out multiprocessing in the name of GIL (I am sure that the ones who have this approach of thinking too are somewhat lacking in fundamentals here). You had clearly stated that we should use multiprocessing for CPU-bound tasks while we should go for threading for I/O-bound tasks. My question is: does this behaviour with respect to multiprocessing and threading carry over to other languages as well (say, Java)? And what exactly is this GIL and why does it hamper "true parallelism while threading" (when it... should not? At least that is what my understanding was)?
As always, have been loving your videos lately!

DiptonilRoy
Автор

Very informative and well structured. Learnt a few things.
And you have a perfect voice, fit for NatGeo type documentary narrations.
Cheers

nitinkapoor
Автор

thank you for this video! you deserve more likes and follows! people are missing out!

dragonkat
Автор

A lot of thanks for sharing your knowledge, dude! In the 2nd example when you're getting prime numbers I didn't know that way to test if a number is prime or not (what's its name?), so I coded the classical and academic definition of primes, and when I ran it, what a surprise, 20 min., 25 min., not finished, and I question myself WTF I'm doing wrong: so when I was washing my clothes, I realized it, the classical definition is making an absurd and vast amount of divisions when testing a number prime. I reviewed the code and looked for the best optimized prime testing until a video that explains a YouTube channel called GeeksForGeeks, which is exactly like yours but coded differently (your code is also testing negative numbers which is good), and finally I kept following your explanation and I was much glad to remember that feeling of getting stuck by a task and resolving with my own effort plus your video and the other sources. ¡Saludos desde México, estimado!

sergioernestotostadosanche
Автор

Continue with more video, u r awesome ... Thank u...
On threading, racing condition...
Celery worker, distributed computing....
Real-world production grade python coding practices etc etc...
I'm a quant

pyalgoGPT
Автор

hellos . how can i calculate overhead cost of multiprocessing

suaadali
join shbcf.ru