Member-only story
A Guide to Python Good Practices
Revisiting some of the best practices in Python by touching points from project structuring to code formatting to some good old code management tips
This article is a chapter taken from my ongoing (and still only partially complete) book on Data science titled, “A Lazy Guide to Data Science”. To read similar articles, refer to my blog or my medium page. Don't forget to say hi on LinkedIn and/or Twitter. 🖖
Introduction
Writing code that works now is easy. Writing code that will work tomorrow is hard. Writing code that will work tomorrow and is intuitive enough for anyone to understand and follow — well now we have hit the super hard stuff 😀. Observing several ML engineers and Data scientists working with me, I have noticed nearly all of them have their own unique style of coding. Well, don't get me wrong, subjectively is a good thing and I think it is what leads to innovations. That said while working in a team or even in open source collaboration, it helps to agree to a certain set of rules. And that's the idea behind this article, to provide python practitioners with a set of curated guidelines, from which they can pick and choose. With that, let’s cover some of the good practices, which will not only help us to create a working…