啟用具有 GPU 的預設執行階段

如需預先發布版的支援服務,請傳送電子郵件至 vertex-notebooks-previews-external@google.com

本文說明如何為專案中的 Colab Enterprise 使用者啟用 GPU 的預設執行階段。啟用含 GPU 的預設執行階段後,使用者只要在筆記本中按一下按鈕,即可從一般預設執行階段切換至含 GPU 的預設執行階段。

本文件適用於 Colab Enterprise 管理員,他們希望為組織中的其他使用者啟用預設執行階段和 GPU。本教學課程假設您具備下列知識:

  • 如何管理 Colab Enterprise 執行階段和執行階段範本。
  • 如何使用 Identity and Access Management (IAM) 控管存取權。

總覽

如要讓使用者切換至含 GPU 的預設執行階段,管理員 (roles/aiplatform.colabEnterpriseAdmin) 或具備 aiplatform.notebookRuntimeTemplates.create 權限的使用者帳戶必須先建立含 GPU 的預設執行階段。

第一次建立具有 GPU 的預設執行階段時,Colab Enterprise 會建立新的預設執行階段範本,其規格中包含 GPU。原始的預設執行階段不會受到影響,並會持續存在,直到到期或遭到刪除為止。建立含有 GPU 的新預設執行階段範本後,任何擁有專案 aiplatform.notebookRuntimes.assign 權限和執行階段範本 aiplatform.notebookRuntimeTemplates.apply 權限的使用者,都可以建立及使用含有 GPU 的預設執行階段。這些權限包含在 Colab Enterprise 使用者 (roles/aiplatform.colabEnterpriseUser) 角色中。

規格

含 GPU 的預設執行階段規格與原始預設執行階段不同。可用的機器類型、GPU 和資料磁碟類型會因地區而異,因此某些規格可能與原始的預設執行階段不同。

下表說明預設 GPU 執行階段的規格,依據的是預設執行階段的區域。

地區說明 預設執行階段規格
支援 L4 GPU 的地區
  • 機器類型g2-standard-4
  • 加速器:1 個 NVIDIA_L4 加速器
  • 資料磁碟:100 GB pd-balanced
不支援 L4 GPU 但支援 T4 GPU 的地區
  • 機器類型n1-standard-4
  • 加速器:1 個 NVIDIA_TESLA_T4 加速器
  • 資料磁碟:100 GB pd-standard
不支援 L4 或 T4 GPU 的地區 不支援含 GPU 的預設執行階段。

加速器適用範圍

Colab Enterprise 支援下列加速器類型的預設執行階段:

  • L4
  • T4

如要瞭解這些加速器的區域供應情形,請參閱「使用加速器」。

事前準備

  1. Sign in to your Google Cloud account. If you're new to Google Cloud, create an account to evaluate how our products perform in real-world scenarios. New customers also get $300 in free credits to run, test, and deploy workloads.
  2. In the Google Cloud console, on the project selector page, select or create a Google Cloud project.

    Go to project selector

  3. Make sure that billing is enabled for your Google Cloud project.

  4. Enable the Vertex AI, Dataform, and Compute Engine APIs.

    Enable the APIs

  5. In the Google Cloud console, on the project selector page, select or create a Google Cloud project.

    Go to project selector

  6. Make sure that billing is enabled for your Google Cloud project.

  7. Enable the Vertex AI, Dataform, and Compute Engine APIs.

    Enable the APIs

  8. 必要的角色

    為確保您的使用者帳戶具備必要權限,可在 Colab Enterprise 中啟用內含 GPU 的預設執行階段,請要求管理員將 Colab Enterprise 管理員 (roles/aiplatform.colabEnterpriseAdmin) IAM role on the project. ) 角色授予您的使用者帳戶。

    For more information about granting roles, see Manage access to projects, folders, and organizations.

    Your administrator might also be able to give your user account the required permissions through custom roles or other predefined roles.

    Enable GPUs for default runtimes

    To enable GPUs for default runtimes, do the following:

    1. In the Google Cloud console, go to the Colab Enterprise My notebooks page.

      Go to My notebooks

    2. In the Region menu, select the region that contains your notebook.

    3. Click the notebook that you want to open. If you haven't created a notebook yet, create a notebook.

    4. In your notebook, click Connect.

    5. After Colab Enterprise connects to the default runtime, in the top right corner of your notebook, click the button to switch to a default runtime with GPUs. For example, if your notebook is in a region that supports L4 accelerators, click Switch to L4.

    Colab Enterprise creates a new default runtime that has GPUs, and then connects to the runtime. The ability to switch to a default runtime with GPUs is enabled for other users in the project.

    Turn off GPUs for default runtimes

    To turn off the ability to switch to a default runtime with GPUs, you must delete the runtime template named Default with GPU. See Delete a runtime template.

    Limitations

    • Default runtimes with GPUs are only available in regions that support specific accelerator availability. See Accelerator availability.

    • You must first connect a notebook to a default runtime to be able to switch to a default runtime with GPUs.

    What's next