Example project showing how to create a SageMaker notebook instance with the fast.ai library and course notebooks installed.
The notebook is designed to work with either v 0.7 or v 1.0 of the fastai library. v 0.7 should be used if you are taking 2nd edition of Practical Deep Learning For Coders released online in early 2018. v 1.0 should be selected if you are taking the 3rd edition of Practical Deep Learning For Coders that will be released online to the general public early 2019.
Follow the instructions below to setup your IAM role, SageMaker Notebook Lifecycle Configuration, SNS Topic and SageMaker Notebook Instance.
We will use CloudFormation to create our resources via a template file. To do this,
- Click the Launch Template button in the table below selecting the region closest to you. It will open the AWS CloudFormation Web Console a create a new CloudFormation stack.
- There are a few parameters you will need to fill in including the instance type, fastai library version and email address. The default instance type is ml.p2.xlarge as this is required to train the fast.ai models quickly. The ml.t2.medium option is part of the AWS Free Tier. See the SageMaker pricing page for more details. Valid options are for the fast.ai library are 0.7 and 1.0. The default option is 1.0. You will need to enter your email address to receive a notification when the fastai environment has been installed correctly. Tick the option box to acknowledge that IAM resources will be created and then click the Create button to create the stack.
gi
You will now see a CloudFormation create stack screenshot like the one shown below:
Take note of the resources being created including:
- IAM service role allowing SageMaker access various AWS services
- SageMaker Notebook Lifecycle Config scripts that are run when the SageMaker Notebook is created and started.
- SageMaker Notebook Instance to run the fast.ai MOOC course notebooks.
- SNS Topic to receive an email notification when the notebook is setup correctly with the fastai library and dependencies.
About 5 minutes or so should pass then the CloudFormation stack should move to the state CREATE_COMPLETE like the screenshot below.
- You will need to confirm the subscription to the SNS topic by checking the inbox of the email address supplied. Click the Confirm subscription link in the email to receive the notification email later.
- Wait for up to 15 minutes to have all of the fastai libraries installed on the SageMaker notebook instance. When it has done you will receive an email with a link to the notebook instance as per the screenshot below.
- Click on the tinyurl.com based shortened link to open the Jupyter notebook web console.