Introducing FastPractice: exercises for each Fastai Lesson!

Hi everyone,

Want to practice what you studied in the lessons, but don’t know where to start ?

I ran a fastai study group in Lille (Northern France) for almost a year now, and there I quickly realised that after perusing the lessons, people didn’t know what to do to practice. I expected they would come up with some projects of their own. Alas, one or two people did that, but most people didn’t.

So I created a series of exercises for them. And right now I am updating those to be on track with the lessons.

Where can I find them ?

I created a repository here : https://github.com/bdubreu/fastpractice

What do I need to get started ?

A google account. You can run those notebooks on Google Colab for free, and I’ve provided in the github readme all the details you need to open the notebooks on Colab, and also get a link towards the exernal datasets I use for the lessons

What does the exercises look like ?

They are * very * similar to the lessons, but with another dataset. The main goal is to practice what you’ve learned, so you’ll get cells with code and some blanks to be filled. The goal is to test your recall (as opposed to simple recognition: “Yeah, I know that thing”, says everybody while scrolling down an entirely filled notebook; recall is much harder that recognition, so you are tested on that)

Where can I find help if the exercises are too hard ?

I provided a folder with the solutions. If you don’t get why the solution is this and not that, use the forums to ask. I might have left some mistakes in the notebooks / solutions . If this is the case, please create an issue on github, post here :slight_smile:

I hope you enjoy this content, as I have taken great pain to put it together. I will add more notebooks as the lessons continue to happen. In the meantime, I am open to any remark/suggestion ! ( and If you like the exercises, please let me know as well :wink: )

16 Likes

Hey this is really great stuff, thanks so much for putting this together. I’m sure it will be very valuable :slight_smile:

1 Like

It’s great @bdubreu . We have to practice to learn, not just looking for tutorial or copy/paste (it’s also a remind for me haha)

1 Like

Thank you guys ! I’ll post here when exercises for new lessons are available. In the meantime, please tell me if you have any suggestion, and if you find the exercises too hard / too easy :slight_smile:

1 Like

Hello everyone. I’ve just updated the repo with some new exercises for Lesson3 and 5 (Rachel’s lesson on bias, to be clear.).

The exercise on bias is the true story of a Kaggle competition whose outcome went wrong because of biased data. I believe it will be interesting !

If you are using the exercises, please consider sending me some feedback (are they too easy, too hard, do I give too many hints ?)

I’ll try to come up with an idea for lesson4 (Jeremy with MNIST) soon. If you have any idea, feel free to propose :slight_smile:

2 Likes

This is a great idea @bdubreu, I’m thinking about contribute to your project, teaching is a good way to learn and even motivate myself.

What do you think about put the hint in a folding cell after each exercise ? I mean to hide all the hints so that the learner is forced to think about what they need to do. I think that we will learn (or memorize) the best when we code by ourselves all from scratch. What do you think about this ?

Hi @dhoa,

I think that’s a good idea, but I’m not sure how to implement it. Problem is: folding cells require nbextensions if I am not mistaken, so some learners could have the “hint” directly unfolded before their eyes if they don’t have the correct setup… Do you know of a way to do it consistently across Colab/Jupyter without taking that risk ?

If you use Colab so I think the cells are collapsable automatically when you put heading (from 1 to 6 #).
Check this https://colab.research.google.com/notebooks/mlcc/creating_and_manipulating_tensors.ipynb?hl=en#scrollTo=7d1kfAx4QL17 . The author have Solutions cells hidden by putting ### Solution

For people that don’t use Colab so maybe we can make an environment.txt for conda or requirement.txt for pip ?

What do you think about putting a open in colab button on top of your notebook in github. You can find a tutorial for that here. https://github.com/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb