# ---
# jupyter:
#   jupytext:
#     text_representation:
#       extension: .py
#       format_name: light
#       format_version: '1.5'
#       jupytext_version: 1.14.4
# ---

# > Below is a template for designing a dpv2 sample notebook. Text in black is a proposed template for preparing the notebook. You can basically keep it as is, or adapt the wording to your needs. Text in blockquote are guidelines or questions to help you fill the template.

# # Title
#
# > pick your own title, try to use some of the words from the learning objectives (see below)
#
#
# > In **requirements** below, try to answer the following questions:
# >- What is the prior knowledge or know-how required to enter this learning  unit?
# >- What background do we expected participants to have ?
# >- What tools do participants need to have access to ? (if there's a required subscription, give instructions on how to create/use, if need to install something, link to some tutorial)
# >- Do they need to have completed some other course before?
#
# **Requirements** - In order to benefit from this tutorial, you will need to:
# - ...
# - ...
# - ...
#
# > In **Learning Objectives** below, what should participants expects to know how to do after going through that learning unit?
# > Here's a few recommendation for writing learning objectives:
# > - imagine the right objective from the user's perspective, not the developer (what should they expect to learn, not what you want to teach)
# > - pick your verbs from [the Bloom's Taxonomy](https://lccfestivaloflearning2012.files.wordpress.com/2012/10/support-document-13-blooms-taxonomy-teacher-planning-kit.jpg)
#
# **Learning Objectives** - By the end of this tutorial, you should be able to:
# - ...
# - ...
#
# > Under **Motivations**, write a short paragraph here, answering some of those questions:
# > - Why is that learning unit important?
# > - Why should it matter to the participants?
# > - Why should it matter considering their background?
#
# **Motivations** - Some text here.

# # 1. First section of the notebook
#
# > Each section, subsection, cell, should be introduced with a short paragraph (or more) explaining what's going to happen and why we need to achieve this (goals + motivation).
#
# ## 1.1. Sub section of the notebook
#
# > Then follows steps, or notebook cells. If using steps, use numbering. If using notebook cells, use a short sentence to explain what the user is supposed to look at, or modify, and what they should expect the result to be.

# +
from azureml.core.workspace import Workspace
from azureml.core.workspace import UserErrorException
import logging
import traceback

try:
    ws = Workspace.from_config()

    print(
        "Connected to Workspace",
        "-- name: " + ws.name,
        "-- Azure region: " + ws.location,
        "-- Resource group: " + ws.resource_group,
        sep="\n",
    )

except UserErrorException:
    logging.critical(
        """Could not connect using the local config.
        - if you're running locally, use the notebook to Connect to your workspace
        - if you're running from AzureML... this should not happen
        {}""".format(
            traceback.format_exc()
        )
    )
# -

# # Next Steps
#
# > In this section, if tutorial is in a sequence, add links to the next notebook. Also, add any relevant links (not too many) on the same topic of this tutorial.
#
# You can now go the next tutorial:
# - Title of the next tutorial with link
#
# Also, on the same topic:
# - link to notebook / docs

#

StarcoderdataJupyterScriptsDedupFiltered