Setting up an Azure VM for Deep learning
So I just started with the course at http://course.fast.ai/ called Practical Deep Learning For Coders. The basic infrastructure that you need is a GPU enabled PC so that you can train your models on the images quickly. The Author has described how to do it in AWS , but the problem with AWS GPU instances are that is still in some sort of preview and we need to contact Amazon Support for unlocking their P2 Instances.
Microsoft Azure on the other hand already has GPU enabled VMs which came out of preview on 1st of December 2016. You can see the promo page here . Its now out of preview and anyone can access it without going through the hassle of contacting support. You can see the pricing here . The NC6 Machines that we are gonna use costs 0.90$ per hour.
If you are new to Azure, I hope the screenshots will help you. Login to https://ms.portal.azure.com with your Microsoft/Live account. The click on the + sign to add a VM
Search for Ubuntu Server 16.04 LTS as above.
Make sure you choose the Vm disk type as HDD instead of SSD as otherwise it will not show you the NC6 option . Also the location has to be East US.
By default it shows recommended VMs, click on all and scroll down to NC6.
You should see the above message once it is successful
Once it is ready, click on connect and you will be able to see the IP.
Once you ssh into the machine.Start running the following commands from your home folder . I have made a gist as seen below. Please run the commands one by one as in the blog.
Run step 1 from this gist. You might see an error like the one below
So we have to re run the last 4 lines from the install-gpu-azure script. So Run step 2 from the gist.
No we are almost ready to start with out jupyter notebook. So please execute step3_from_your_local in your local system. So this will tunnel traffic from your localhost:8000 to the VM 8888 port. replace the Ip with your own ip
Now run step 4 form the gist and get all the resources you need.
Now we open the notebook and navigate lesson1. And start executing each of the commands
You should get this error. We need cv2 . Please run Step 5 from the gist and you should be good.
Everything should be fine and dandy now :) . Happy deep Learning!