
Going knee-deep into the internals of Python
Going knee-deep into the internals of Python
I show toy implementations of Python decorator patterns that may be useful for Data Scientists.
Do you want to write concise, readable, and efficient code? Well, python decorators may help you on your journey.
Analyze, test, and re-use your code with little more than an @ symbol
Python decorators are a useful but flawed language feature. Intended to make source code easier to write, and a little more readable, they neglect to address another use case: that of the programmer who will be calling the decorated code. If you’re a Python programmer, the following post will show you why decorators exist, and how to compensate for their limitations. And even if you’re not a Python a programmer, I hope to demonstrate the importance of keeping in mind all of the different audiences for the code you write.