I am having hard time understanding concepts about software engineering in Part 2 . Being from non-CS background, I needed some starting point. So I simply asked question about where to start from on forum and got overwhelming response. This is what I love about fastai community.
I thought, it would be good idea to gather all responses about my software engineering question at one place so everyone will have easy access to it.
How do you think, why GoF is a bad choice? Is it kind of obsolete now, or do they describe too āidealā scenarios that are far away from real-world development?
Iām not Jeremy but in my opinion itās because people only remember a single design pattern, Singleton, which is actually an anti-pattern in most cases. Just like people only remember bubble sort from an algorithms class.
iām a great fan of Gof and see those patterns in so much work today. However it was create in the c++ days. There must be a more up to date version out there. Maybe the refactoring book of martin fowler talks about the same pattern. He certainly has written about those patterns for java
The answer is simple, coding in 2019 is quite different than in the 90s. Nowadays you can find patterns implemented in very large frameworks. But, at the end of the day, you learn how to use such frameworks rather than how they were built or designed.
BTW, to be a good software engineering study algorithms and look to open source projects especially from Apache foundation or Google. Moreover, create a group of friends to code together
A lot of the patterns are quite specific to particular types of language, and simply arenāt needed or useful for Python. And even for languages where they are relevant, I found them far too abstract to be helpful for my way of thinking - and they donāt solve problems which I find particularly hard to solve thru simply tests and iterative refactoring.
I would personally recommend staying away from all of those resources (at least within the context of FastAI or Data Science). Those books are primarily aimed at people who:
Are using a full-on Object Oriented Language
Writing code that will be maintained for (at least) years
It sounds like youāre having trouble following the callbacks/hooks/partial functions portions of the lessons. This makes sense because these portions are quite a bit different than most of the code that was introduced in Part 1 of the course.
Iād recommend using the same strategies that likely got you through Part 1 (Itās been easy to forget these techniques because thereās much less āhomeworkā in Part 2):
Step through the notebooks very carefully while making edits to see what happens. Take care to make sure you understand whatās going on in each cell.
At some point you may get confused or lost. Simply ask for clarification on the forums. I find that drafting a question will force me to clarify my thoughts and many times end up answering my own question before Iāve even posted it.
Once you understand how something works within the context of the notebooks, try using it on the full FastAI library. For example, once I understood how callbacks worked within the notebooks, I used callbacks to visualize activations of a ResNet.
This approach can be frustrating at times, but Iām confident that itās the fastest way for you to get up to speed on the software engineer approaches used in the FastAI library. Reading those books will not get you much closer to understanding the specific techniques used in FastAI.
I would say that the books about Software Engineering help to at least structure your coding thinking a bit. During my career, Iāve seen lots of Python/JS/C# code which was hardly readable because was written in a pretty obscure way, with too many commentaries between the lines of code, using global state too much, using god objects, or totally ignoring languageās OOP capabilities, etc. So it means that these people who wrote the code were not familiar with even these simple principles which seems to be obvious. Like, you probably canāt study Linear Algebra without understanding how to add numbers.
The fastai library is structured pretty well though. It decouples models, learners and training loop from each other. It uses callbacks to decouple the specific functionality from the ācoreā. It also includes lots of tests and proper documentation where it is required. So it actually follows many of these fancy things like SOLID and DRY. Of course, this knowledge comes with experience. You get this experience after many years of coding, or can simplify your journey a bit reading some books
Sure enough, each book has its limitations and should be treated with a grain of salt. At the end of the day, critical thinking is always a good thing.
Do you guys try to remember by heart the syntax while coding ? I mean, I am always struggling to remember even many commands that I use everyday. For example: delete a local git branch or remote branch. Where is axis 0 and 1 in numpy ⦠And I think I lost so much of time researching these things
I think practicing is the key to become a better software engineer (even more important than your intelligence). And remembering syntax make me practicing faster. Recently, I tried to use Anki to note every commands that I need to review but I found it is quite limited.
What do you think about this ? I am thinking about develop an application that help people review very short information or can check easily by our phone. I know that the best way to remember thing is really do it, but we donāt always stay with our computer, right ?