The Primer on Asyncio that I Wish I Had
Parallelism and concurrency aren’t the same things. In some cases, concurrency is much more powerful.
Python is an easy language to pick up, but mastering it requires understanding a lot of concepts.
In my last post, I talked about using a multiprocessing module to do parallel processing. Python also offers users the power to work with concurrency using the Asyncio module from version 3.4 forward.
For people who come from a JavaScript background, this concept might not be new, but for people coming from Python 2.7 (yes, that’s me), Asyncio may prove to be hard to understand, as does the difference between concurrency and parallelism. Due to its growing popularity, though, it has really become an important concept to master.
In this post, I want to mitigate some of the confusion around Asyncio, explaining it in the simplest terms possible.
Keep reading with a 7-day free trial
Subscribe to MLWhiz | AI Unwrapped to keep reading this post and get 7 days of free access to the full post archives.