All Products
Search
Document Center

PAI DSW

Last Updated: Jul 21, 2019

Overview

Data Science Workshop (DSW) is a deep learning development environment provided on the cloud for algorithm developers to write and run code. DSW uses the TensorFlow framework that is deeply optimized by the Machine Learning Platform for AI team. You can open the DSW terminal to install third-party libraries.

The following figure shows the user interface of DSW:

dsw

The user interface contains the files section on the left side, the code editing section in the middle, and the resource search section on the right side.

Create an instance

  1. Log on to Machine Learning Platform for AI and select DSW in the left-side navigation pane.

dsw

  1. Select a region. Currently, only the China (Shanghai) and China (Beijing) regions are supported. The underlying GPU servers used by DSW and their prices vary depending on the region. For more information, see DSW pricing

  2. Click Create Instance.

Enter the instance name, and select a resource type. For more information, see DSW pricing.

dsw

  1. Resource type descriptions

The system provides 5 GB of free storage space for each created instance. If you want to mount an NAS file system to the instance, purchase an NAS file system and enter the NAS file system ID into the field as shown in the following figure. You must click “Authorize” to authorize the NAS file system before you bind the NAS file system to the instance.

NAS: https://www.aliyun.com/product/nas

dsw

  1. Open the created instance to log on to DSW.

(https://img.alicdn.com/tfs/TB1hOz3iNnaK1RjSZFtXXbC2VXa-1193-125.png)

Download demos

For new users, we recommend that you use the built-in demos to get familiar with DSW. In the left-side navigation pane, click Demos, select the demo that you want to download, and click Download.

dsw

You can view and use the downloaded demo in the File Browser.

Install third-party libraries

Third-party libraries are required for code development in a Python environment. Machine Learning Platform for AI allows you to install third-party libraries. The installed third-party libraries are saved to the environment for further usage.

To install third-party libraries, open the terminal.

dsw

Install third-party libraries for Python 3:

  1. pip install --user xxx

Install third-party libraries for Python 2:

  1. source activate python2
  2. pip install --user xxx

Authorize RAM user accounts

If you want to use a RAM user account to create a DSW instance and use it, you must first log on to Resource Access Management (RAM) to authorize the RAM user account.

RAM: https://www.aliyun.com/product/ram

Log on to the RAM console, click Policies in the left-side navigation pane, click the Custom Policy tab, and select Create Authorization Policy.dsw

dsw

Select Blank Template, enter a policy name, and add the following content to the policy:

  1. {
  2. "Statement": [
  3. {
  4. "Action": [
  5. "notebook:CreateInstance",
  6. "notebook:StartInstance",
  7. "notebook:StopInstance",
  8. "notebook:EditInstance"
  9. ],
  10. "Effect": "Allow",
  11. "Resource": "*"
  12. }
  13. ],
  14. "Version": "1"
  15. }

dsw

Click Users in the left-side navigation pane.

dsw

Authorize the RAM user account.

dsw

Mount NAS file systems

You must make sure that the NAS file system is purchased in the same region as DSW. To purchase NAS file systems, click https://www.aliyun.com/product/nas

Log on to the NAS console and follow the steps shown in the following figure:

  1. Create an NAS file system and set mount points.

dsw

Notes:

  • When you create the NAS file system, do not set the protocol type to NASPlus. Set the protocol type to NFS.

dsw

  1. Authorize the NAS file system

Skip this step if your NAS file system is already authorized.

Click the following link to go to the authorization page and then click Confirm Authorization Policy: NAS file system read permission authorization

dsw

Record the NAS file system ID. This ID is used to mount the NAS file system to the DSW instance.