Navigating the Databricks Workspace
Navigate the workspace
A Databricks workspace is an environment for accessing all of your Databricks assets. The workspace organizes objects such as notebooks, libraries, experiments, queries, and dashboards into folders, and provides access to data and computational resources such as clusters and jobs.
Use the sidebar
By default, the sidebar appears in a collapsed state and only the icons are visible. Move cursor over the sidebar to expand to the full view.
To change the persona, click the icon below the Databricks logo
, and select a persona.
To pin a persona so that it appears the next time you log in, click
next to the persona. Click it again to remove the pin.
Use Menu options at the bottom of the sidebar to set the sidebar mode to Auto (default behavior), Expand, or Collapse.
When you open a machine learning-related page, the persona automatically switches to Machine Learning.
Switch to a different workspace
If you have access to more than one workspace in the same account, you can quickly switch among them.
Click the workspace name in the top bar of the Databricks workspace.
Select a workspace from the drop down to switch to it.
- Attach a notebook to a cluster - Deploying a cluster can take several minutes. A solid green circle will appear to the left of the cluster name once resources have been deployed. If your cluster has an empty gray circle to the left, you will need to follow instructions to start a cluster. (Refer chapter 1 )
- Execute a cell in a notebook - Notebooks provide cell-by-cell execution of code. Multiple languages can be mixed in a notebook. Users can add plots, images, and markdown text to enhance their code.
- Set the language for a notebook - The cell above executes a Python command, because our current default language for the notebook is set to Python. Databricks notebooks support Python, SQL, Scala, and R. A language can be selected when a notebook is created, but this can be changed at any time.
- Describe and use magic commands - A single percent (%) symbol at the start of a cell identifies a magic command, these are specific to the Databricks notebooks. The magic command %md allows us to render Markdown in a cell. Language magic commands allow for the execution of code in languages other than the notebook's default eg %sql %python
- Export a Databricks notebook - Steps:
- Click the File option to the right of the cluster selection at the top of the notebook
- From the menu that appears, hover over Export and then select Source File
- Export a collection of Databricks notebooks - Steps:
- Click the
Repos on the left sidebar
- This should give you a preview of the parent directories for this notebook
- On the left side of the directory preview around the middle of the screen, there should be a left arrow. Click this to move up in your file hierarchy.
- You should see a directory called Data Engineering with Databricks. Click the the down arrow/chevron to bring up a menu
- From the menu, hover over Export and select DBC Archive
- Click the
Comments
Post a Comment