My 3-year journey: From zero Python to Deep Learning competition master

The path I followed since starting to learn Python back in 2017 up to became a Kaggle competition master with a solo gold medal in middle 2019. A story to inspire you to pursue your goals and never give up.

Miguel Pinto
Towards Data Science

--

Photo by Mantas Hesthaven on Unsplash.

Table of contents

  • Why get started?
  • Learning Python
  • Learning practical Deep Learning
  • Competing in Kaggle
  • The path forward

Why get started?

Interest in Deep Learning and Artificial Intelligence (AI) has been growing exponentially over recent years. Not only it is an exiting topic that promises great progress but also a topic that raises significant concerns.

On the bright side:

  • AI applications will allow automating processes that otherwise would require many hours of repetitive human labour or it wouldn’t be possible at all on a large scale.
  • AI will make cars drive themselves and save millions of lives by reducing traffic accidents.
  • AI will assist doctors in evaluating the patient condition accurately.
  • AI will work together with artists to produce new forms of art.
  • AI will help scientist to make new advancements in science.

These are just a few examples of applications that make this topic so exciting. However, we need to be aware of the concerns too:

  • Automation can lead to more and more human workers to lose their jobs.
  • Mass surveillance using face recognition AI can be a big threat to freedom and democracy.
  • AI can be used to generate fake news, including video and audio, that can help to spread misinformation.
  • Bias in AI models can lead to an increase in polarization and discrimination against minority groups.

And again these are some examples of threats that need to be considered. For some of these problems such as bias in AI models, data scientists producing and training these models have a moral responsibility of evaluating and fighting such bias.

Keeping these important considerations in mind let’s move to the next topic — learning Python.

Learning Python

At the beginning of 2017, I realized that if I wanted to get into Deep Learning I would need to learn Python first. Back then I used Matlab for my research at University, this was the year before I applied for a PhD. My strategy for the transition to Python was to use Python in every new project that I start.

In the beginning, it was a little frustrating. I spent a lot of time trying to do things in Python that I knew how to do easily in Matlab. But after a few months, I started to work faster in Python and realizing all the potential it has. At the end of 2017, I wasn’t using Matlab anymore.

When people ask me how to get started in Python I give the same advice that worked for me — use it in every new project you start. However, if you don’t have any programming background, looking for some online lessons introducing programming with Python will probably be very helpful. And as always, practice makes perfect.

One additional tip that is extremely important is to look at other people code or ask for feedback on your code. Usually, there are several ways to code the same process and one of them is probably cleaner and simpler. Making the code clean and concise will help you to increase your productivity over time.

Learning practical Deep Learning

I tried several Deep Learning courses online such as the Nando de Freitas lessons on YouTube and Neural Networks and Deep Learning course by Andrew Ng. Those are very interesting and a good experience but the course that really made me move a big step forward was fast.ai Deep Learning for Coders. It was game-changing for me. The top-down teaching approach was great to help getting started fast and join Kaggle competitions right away. On top of that, fastai library provides out-of-the-box tools to solve several types of deep learning problems. You won’t win any competition with an out-of-the-box solution but it will get you started. Afterwards, incorporating the newest ideas into fastai setup is usually not difficult, particularly in fastai version 2.

If I was to start learning about Deep Learning today I would start by fastai course. Then as you move deeper into the concepts, you can search for other learning materials that can give you further technical insight. They are very helpful but you need the motivation first. And particularly if you are studying by yourself, like I did, having the practical knowledge to start making experiments is a great motivation. Later when you dive deeper into the concepts, you will also find the information more useful and easier to understand as you will already have the practical knowledge.

Competing in Kaggle

Competing in Kaggle is for me the best way to learn. The competitive spirit together with the discussion and sharing of ideas with other people is a good way to learn and improve fast. It’s not an easy ride. I remember when I first started on Kaggle I didn’t really know what I was doing. When I was able to get my first bronze medal on a competition (top 10% of the leaderboard) it felt like a milestone. This was at the end of 2018. At the beginning of 2019, I moved a step forward and got a silver medal (top 5%) in another competition after two months of hard work. Later in middle 2019 I finally got a gold medal (6th place) and became a Kaggle competition master.

The learning journey is not easy and straight-forward. Working in competitions can be frustrating as often you spend a long time trying new ideas that after all the effort don’t make any difference. Persistence is the key. If you keep trying every day without giving up, you will find what techniques work best on that particular competition. And even if at the end the result is not great, what matters most is the learning. The process of trying new ideas and evaluating the results is always good as a learning mechanism that will make you a skilled deep learning practitioner. I like to think that in Kaggle, the real winner is the one who learns the most.

After becoming a Kaggle competition master I’ve started to join teams for competitions. Discussing the ideas with other people is very fruitful and there is a lot to learn with team members. I also started to apply deep learning to my research on the University as well as for personal projects. I find that working on a problem you want to solve is a very fun experience and often it’s how you learn the most.

The take away from this topic is that if you are starting on Kaggle, learn from others and don’t worry about your score. There are usually good starter notebooks that can be a great learning resource. However, you should try to understand what is happening in the code so that you can improve it or apply it to other problems.

The path forward

It’s hard to predict the future. Who would have guessed that in 2020 we will be facing a pandemic? Nevertheless, I’m confident that Deep Learning will keep playing a growing role in society as technology keeps moving forward and new ideas never stop. As for me, I think I will keep to put more focus on personal projects and eventually in some Kaggle competitions if I find them exciting.

Working on personal projects is an interesting path to follow. Not only you will be working on something you are passionate about but you will also produce something unique that may have value to other people. And that may bring you to new opportunities.

Moving forward I will also keep writing often. I find that sharing the ideas I’m working on is a good way to track my progress and help others in their own projects. If you never tried writing a Medium story, give it a go!

Final remarks

I hope that my journey can inspire you to pursue a similar path if that’s what you are looking for! Deep learning is very exciting and even if you don’t want to be a deep learning practitioner, having some knowledge about it is very important nowadays and it will be even more in the future. That way when you read about face detection and artificial intelligence or any other news regarding AI, you will be able to understand better what is going on behind the scenes. It will allow you to have a more informed vision and opinion about the matter. And that matters. It is an extremely important skill to have today and in the foreseeable future.

--

--

PhD student (Remote sensing, Meteorology), ML/DL enthusiast, fastai student, competition master at Kaggle, pianist/composer