Pratham Prasoon
Pratham Prasoon

@PrasoonPratham

11 Tweets 8 reads Sep 05, 2021
I get this question a lot: "I don't have a good PC, can I still train machine learning models?"
Yes you can and here's how 🧵
Machine learning, more specifically deep learning is a very demanding task and requires something called a 'GPU' if you want to do it quickly.
These specialised chips are helpful in gaming and graphics related tasks but they are also incredibly fast for deep learning ones.
It's a physical component that you have to add to your computer and are very expensive right now due to the semconductor shortage.
For example my workstation has an RTX 3070, fairly high end GPU that I am fortunate enough to own.
I know not everyone has to money to buy these so I'll explain how you can use something even better.
S̶t̶a̶r̶t̶ ̶p̶l̶a̶n̶t̶i̶n̶g̶ ̶t̶o̶m̶a̶t̶o̶e̶s̶
Google has a service called Collab, which is basically a Jupyter notebook instance hosted in the cloud with a GPU.
It's free to use and it comes with all the drivers and libraries pre-installed, so you don't have to do any setup.
Besides you even get insane network speeds so downloading datasets will take no time and your code is saved in the cloud so don't have to worry about losing it.
Now as amazing as Google collab is, there are certain limitations.
For example using webcams, uploading photos, mounting storage folders etc requires a bit work arounds that you will have to get used to and there is 24 hour limit on each session.
🔗 colab.research.google.com
If for some reason you don't like collab, kaggle also provides their own cloud hosted notebook solution.
Both give you access to extremely fast server grade GPUs.
kaggle.com
If you want more horsepower and are willing to pay then AWS has Sagemaker, Lambda has GPU cloud etc.
For most people collab and kaggle notebooks are more than enough.
On my old laptop with an i7-5500U and integrated graphics, training a basic CNN like the one you see below took over 30 minutes.
On Collab it was less than 3 minutes, huge difference! 🤯
To be very clear this isn't an endorsement for any of the aforementioned products.
When I tried machine learning in 2019 I didn't know about them so I just want others to not make the mistake I did.
If you liked this thread then make sure to follow @PrasoonPratham and we'll figure this machine learning thing together.

Loading suggestions...