Build Machine Learning Models with Amazon SageMaker
If your data science team needs to implement machine learning models for their business needs. In this lab, you use Amazon SageMaker to set up a development environment and run a basic linear regression model.
Steps:
- Navigate the SageMaker domain.
- Create a SageMaker space.
- Launch SageMaker studio.
- Clone a repository.
- Run a linear regression model.
Task 1: Navigate SageMaker Domain
- At the top of the AWS Management Console, in the search bar, search for and choose Amazon SageMaker AI.
- In the left navigation pane, under Admin configurations, choose Domains.
- Choose create Domain.
- Choose setup for organization
- In the Domain details page, explore the following:
- Domain settings
- User profiles
- Environment
Note: A domain enables you to manage multiple users working in isolated environments.
Task 2: Create a SageMaker space
Create a collaborative space for your development work. Spaces in SageMaker Studio enable data scientists to share resources and collaborate on machine learning projects.
- In the left navigation pane, under Applications and IDEs, choose Studio.
- Choose Open studio.
- Wait for SageMaker Studio to launch.
Note: After launching SageMaker Studio, a welcome pop-up window may appear. Choose Skip Tour for now to proceed with next steps.
- Locate the Applications pane on the left side.
- From the Applications pane, choose JupyterLab.
- Choose + Create JupyterLab space.
- In the Create JupyterLab space window, configure:
- For Name, enter ml-regression-lab.
- Select Share with my domain.
- Choose Create space.
Note: Wait for the Status to change to Stopped, which typically takes 1-2 minutes.
Task 3: Launch JupyterLab environment
Start and access your JupyterLab environment. JupyterLab provides an interactive development environment for writing and executing machine learning code.
- After the space creation completes, choose Run space.
Note: Wait for the Status to change to Running, which typically takes 1-2 minutes.
- Choose Open JupyterLab.
- A new browser tab opens to the JuypterLab workspaces interface.
Note: The JupyterLab workspaces interface takes 1–2 minutes to load for the first time.
Task 4: Clone repository
Clone the lab repository containing the machine learning notebook.
- In the left menu bar, choose the Git icon.
- Choose Clone a Repository.
- For Git repository URL, paste the Url for repo of your code.
- Choose Clone.
Task 5: Run linear regression
Implement a basic linear regression model using the provided notebook.
- In the left navigation pane, open the notebook that has linear regression code with extension ipyb.
- In the Set up notebook environment window, choose Select.
Note: Wait for the kernel gateway to start, which typically takes 2-3 minutes.
- Carefully advance through the notebook. Run each code cell and view its output by selecting within the cell and pressing Shift+Enter or choosing the Run button at the top of the page.
Conclusion
You have successfully:
- Navigated the SageMaker domain.
- Created a space for development.
- Launched SageMaker studio.
- Cloned a repository.
- Ran a linear regression model.
Top comments (0)