In dieser Anleitung werden Sie durch die erforderlichen Schritte zum Trainieren und Abrufen von Vorhersagen aus Ihrem tabellarischen Datenmodell in der Google Cloud -Konsole geführt.
Wenn Sie das Vertex AI SDK für Python verwenden möchten, muss das Dienstkonto, das den Client initialisiert, die IAM-Rolle Dienst-Agent von Vertex AI (roles/aiplatform.serviceAgent
) haben.
In diesem Teil der Anleitung richten Sie Ihr Google Cloud -Projekt für die Verwendung von Vertex AI und einen Cloud Storage-Bucket ein, der die Dokumente zum Trainieren Ihres AutoML-Modells enthält.
Projekt und Umgebung einrichten
-
In the Google Cloud console, go to the project selector page.
-
Select or create a Google Cloud project.
-
Verify that billing is enabled for your Google Cloud project.
- Öffnen Sie Cloud Shell. Cloud Shell ist eine interaktive Shell-Umgebung für Google Cloud , mit der Sie Projekte und Ressourcen über Ihren Webbrowser verwalten können. Zu Cloud Shell
- Legen Sie in Cloud Shell das aktuelle Projekt auf Ihre Projekt-ID Google Cloudfest und speichern Sie es in der Shell-Variablen
projectid
: Ersetzen Sie PROJECT_ID durch Ihre Projekt-ID. Sie finden Ihre Projekt-ID in der Google Cloud -Console. Weitere Informationen finden Sie unter Projekt-ID ermitteln.gcloud config set project PROJECT_ID && projectid=PROJECT_ID && echo $projectid
-
Enable the IAM, Compute Engine, Notebooks, Cloud Storage, and Vertex AI APIs.
-
Make sure that you have the following role or roles on the project: roles/aiplatform.user, roles/storage.admin
Check for the roles
-
In the Google Cloud console, go to the IAM page.
Go to IAM - Select the project.
-
In the Principal column, find all rows that identify you or a group that you're included in. To learn which groups you're included in, contact your administrator.
- For all rows that specify or include you, check the Role column to see whether the list of roles includes the required roles.
Grant the roles
-
In the Google Cloud console, go to the IAM page.
Zu IAM - Wählen Sie das Projekt aus.
- Klicken Sie auf Zugriff erlauben.
-
Geben Sie im Feld Neue Hauptkonten Ihre Nutzer-ID ein. Dies ist in der Regel die E-Mail-Adresse eines Google-Kontos.
- Wählen Sie in der Liste Rolle auswählen eine Rolle aus.
- Wenn Sie weitere Rollen hinzufügen möchten, klicken Sie auf Weitere Rolle hinzufügen und fügen Sie weitere Rollen hinzu.
- Klicken Sie auf Speichern.
Die IAM-Rolle „Vertex AI-Nutzer“ (
roles/aiplatform.user
) bietet Zugriff auf alle Ressourcen in Vertex AI. Mit der Rolle Storage-Administrator (roles/storage.admin
) können Sie das Trainings-Dataset des Dokuments in Cloud Storage speichern.Nächste Schritte
Folgen Sie der nächsten Seite dieser Anleitung, um ein tabellarisches Dataset zu erstellen und ein Klassifizierungsmodell zu trainieren.
-