Amazon SageMaker
Developer Guide

Step 3.1: Create a Jupyter Notebook and Initialize Variables

In this section, you create a Jupyter notebook in your Amazon SageMaker notebook instance and initialize variables.

To create a Jupyter notebook

  1. Create the notebook.

    1. Sign in to the Amazon SageMaker console at https://console.aws.amazon.com/sagemaker/.

    2. Open the notebook instance, by choosing Open next to its name. The Jupyter notebook server page appears:

    3. To create a notebook, in the Files tab, choose New, and conda_python3. This pre-installed environment includes the default Anaconda installation and Python 3.

    4. Name the notebook.

  2. Copy the following Python code and paste it into your notebook. Add the name of the S3 bucket that you created in Step 1: Setting Up, and run the code. The get_execution_role function retrieves the IAM role you created at the time of creating your notebook instance.

    from sagemaker import get_execution_role role = get_execution_role() bucket = 'bucket-name' # Use the name of your s3 bucket here

Next Step

Step 3.2: Download, Explore, and Transform the Training Data

On this page: