Wednesday, July 24, 2019

Get Started with Machine & Deep Learning Models & Frameworks Quickly with Oracle GPU Instances

In this post, we will learn how quickly we can set up Oracle Cloud Infrastructure GPU Instances, Get access to NVIDIA GPU Cloud - Container registery and spin up TensorFlow and various other Machine & Deep Learning Frameworks.

Oracle Cloud Infrastructure GPU Instances uses NVIDIA Machine Images. These images have preconfigured NVIDIA GPU CLOUD (NGC) set up. What this means is, we can have access to NGC Container Registry and run any of the Framework Containers & Models availble on NGC  -  https://ngc.nvidia.com/catalog/containers



Lets Get Started.

First we would need to Spin Up GPU Instance in Oracle Cloud Account.

Let us jump straight to OCI Console and Create a GPU Instance. We gave it a name AlphaGPUDemo


Next step is to Select a Shape. For GPU Instances, we will select NVIDIA GPU Cloud Machine Image from Oracle Images. This image is Ubuntu based.



Next Step is to select Shape. Can select any GPU Shape from your options. Here we have selected VM.GPU3.1 here.




Add the public key for the instance.



Click Create and new Compute GPU instance with NVIDIA Image will be created and started. Just a note, do add the instance to Internet Facing VCN. If there is no VCN, there is option to create a default VCN with Internet access when you create GPU Instance in above screen.




Ok, So instance is all set, up and running.

Now next step is to create account at NVIDIA NGC. Log on to https://ngc.nvidia.com/ and create a new account.


Once the account is ready, login and Click on Set up on the left navigation bar.


Select Generate API Key.





Make a note of new generated API Key. This will be used to authenticate against NGC from new Compute GPU Instance. For security reasons, this is being masked.


Now grab public IP of GPU Compute Instance and login using ssh. Use the username as Ubuntu. It asks for NGC API Key. Paste the key which was generated in the previous step.


Login will be successful.


Now go to https://ngc.nvidia.com/catalog/containers and select the framework you need to use for running your Machnie Learning Models. There are large number of popular frameworks in NGC Registry all availble to run as Container.

We will download and run the popular TensorFlow for this example. Select TensorFlow and copy the pull command and run it in the shell.


The command will download TensorFlow Container Image from NGC registry. 



Now run the container using below command. Container will get started and we will get access to it, since we are running container in foreground.


Now we can use TensorFlow for any of our analysis.

We will run the sample MNIST example. Go to the below path.


And run # python mnist_with_summaries.py

And here we go, TensorFlow in Action.



19 comments:

  1. The article is so appealing. You should read this article before choosing the Big data solutions companies you want to learn.

    ReplyDelete

  2. Hey Nice Blog!!! Thank you for sharing the information. Wonderful blog & good post.Its really helpful for me, waiting for a more new post. Keep Blogging!!!

    SEO Expert

    ReplyDelete
  3. This article is awesome. meanwhile I have also written one article on Monitors and technology. So if you want to check it out then you can Click here for more information related to Monitors

    ReplyDelete
  4. Hey this is awesome, you are spreading very informative blog, I am very happy to read this. Keep sharing
    Switzerland VPS Hosting

    ReplyDelete
  5. My name is Samuel, I was in love with my wife and we were married for eight years with a son his is Liam,I loved my wife so much she had access to all my bank account and even my cash app which my accountant agreed to and said it was a great idea, then it took my wife and my accountant two month to get hold of all my properties,all accounts but I had a cash app which they knew nothing about,I was thrown out of my own house was sleeping in a hotel for weeks she also took possession of my son could only see him once a week then I found out she was in love with my accountant all these while so I went online and I came across a private investigator who help me get all my properties and my accounts back even my company back how he did these I don’t know but I gave all the information he asked for and followed all his instructions and now I’m happy my life’s better now.
    Thanks to premiumhackservices@gmail.com
    I just said I should share my own story here
    Thank you

    ReplyDelete
  6. Thanks For sharing. Very Informative.


    Timesheet Management Software Development in Bangalore

    Zenetial Provides you the best timesheet management software in Bangalore. It is an easy-to-use, easy-to-track employees data, and automated payroll software.

    ReplyDelete
  7. Hey thank you!!! I was seeking for the particular information for long time. Good Luck ?

    BCA Time Table

    ReplyDelete
  8. Get the import export data for India Import Export Data at Importglobals. India mostly export iron and steel products, industrial machinery, and automobiles and more. Visit our website for more information in details.
    India Export Data

    ReplyDelete
  9. Thanks for sharing this information. AyurHarsha is the Best Ayurvedic Hospital for Piles Treatment. The Piles Treatment in Ayurvedic Hospital AyurHarsha can be administered with several herbs and oils to cure Piles

    ReplyDelete