Mit Sammlungen den Überblick behalten
Sie können Inhalte basierend auf Ihren Einstellungen speichern und kategorisieren.
Der erste Schritt bei der Analyse Ihrer Videodaten mit einer Anwendung besteht darin, eine Pipeline für den kontinuierlichen Datenfluss zu erstellen.
Streams bietet die Möglichkeit, Videodaten in Echtzeit aufzunehmen, die dann als Eingabe für Modelle verwendet oder in einem Warehouse gespeichert werden können.
Stream erstellen
Damit Sie Videodaten streamen können, müssen Sie zuerst einen Stream erstellen.
Wenn Sie zum ersten Mal einen Stream in einem neuen Projekt erstellen, kann das einige Zeit dauern.
Das dauert etwa 30 Minuten. Dieser Zeitaufwand ist darauf zurückzuführen, dass das System einen Compute-Cluster für nachfolgende Berechnungen initialisieren muss.
Console
Erstellen Sie einen Stream in der Google Cloud Console.
Öffnen Sie den Tab Streams im Vertex AI Vision-Dashboard.
Geben Sie den Streamnamen ein und wählen Sie eine Region aus. Sie können auf Zeile hinzufügen klicken, um mehrere Streams gleichzeitig zu registrieren.
Klicken Sie auf die Schaltfläche Registrieren, um einen oder mehrere Streams zu erstellen.
Videos aufnehmen
Nachdem Sie einen Stream erstellt haben, können Sie damit Daten aufnehmen.
Für aufgenommene Videos gelten einige Einschränkungen und Hinweise:
Die Eingabevideoquelle muss die folgenden Spezifikationen erfüllen:
Wenn das Video diese Spezifikationen nicht erfüllt, kann Vertex AI Vision die Eingabe möglicherweise nicht richtig verarbeiten.
Audio wird während der Datenaufnahme entfernt.
Wenn der Stream Teil einer App ist, die mit einem Warehouse verbunden ist, müssen die Videoparameter (z. B. Framerate oder Auflösung) für den gesamten Stream gleich sein. Abweichungen bei den RTSP-Videodatenparametern oder den lokalen Videodatenparametern werden nicht unterstützt.
Aufgrund der Latenz beim Starten des Modells fehlen bei aufgenommenen Videos möglicherweise die ersten Sekunden des Inhalts. Das kann bis zu 15 Sekunden dauern.
Die Datenaufnahme kann nach einer langen Verbindung beendet werden (durchschnittlich etwa 5 Stunden). Es gibt keine Möglichkeit, über das vaictl-Tool eine neue Verbindung herzustellen. Nutzer müssen die Verbindung manuell herstellen.
vaictl ist zwar ein nützliches Tool für die Datenaufnahme von Videos, es kann aber nicht automatisch nach Netzwerkfehlern wiederhergestellt werden. Diese Fehler können entweder auf Datenquellen- oder auf Cloud-Aufnahmeseite auftreten. Es liegt in der Verantwortung des Nutzers, ein Neustart-Script zum Umgang mit unerwarteten vaictl-Vorgangsbeendigung zu erstellen.
LOCAL_FILE.EXT: Der Dateiname einer lokalen Videodatei. Beispiel: my-video.mp4
STREAM_ID: Die Stream-ID, die Sie im Cluster erstellt haben, z. B. input-1.
RTSP_ADDRESS: Die Adresse deines RTSP-Feeds (Real Time Streaming Protocol). Beispiel: rtsp://my-ip-camera
Lokale Videodaten:
# This command streams a video file to a stream. Streaming ends when the video ends.
vaictl -p PROJECT_ID \
-l LOCATION_ID \
-c application-cluster-0 \
--service-endpoint visionai.googleapis.com \
send video-file to streams STREAM_ID --file-path LOCAL_FILE.EXT
Lokale Videodaten (Loop):
# This command streams a video file to a stream. Video is looped into the stream until you stop the command.
vaictl -p PROJECT_ID \
-l LOCATION_ID \
-c application-cluster-0 \
--service-endpoint visionai.googleapis.com \
send video-file to streams STREAM_ID --file-path LOCAL_FILE.EXT--loop
RTSP-Feeddaten (Real Time Streaming Protocol):
# This command will send an RTSP feed into the stream.# This command has to run in the network that has direct access to the RTSP feed.
vaictl-pPROJECT_ID\-lLOCATION_ID\-capplication-cluster-0\--service-endpointvisionai.googleapis.com\
sendrtsptostreamsSTREAM_ID--rtsp-uriRTSP_ADDRESS
Aufgenommene Videos abspielen
Nachdem Sie einen Stream erstellt und Videoinhalte an den Stream gesendet haben, können Sie die Videoinhalte abspielen.
Wenn Sie den Tab „Streamansicht“ länger als eine Stunde geöffnet lassen, müssen Sie die Seite aktualisieren, damit Videoinhalte weiter geladen werden.
Console
Abgespeicherte Videos in der Google Cloud Konsole abspielen
Öffnen Sie den Tab Streams im Vertex AI Vision-Dashboard.
[[["Leicht verständlich","easyToUnderstand","thumb-up"],["Mein Problem wurde gelöst","solvedMyProblem","thumb-up"],["Sonstiges","otherUp","thumb-up"]],[["Schwer verständlich","hardToUnderstand","thumb-down"],["Informationen oder Beispielcode falsch","incorrectInformationOrSampleCode","thumb-down"],["Benötigte Informationen/Beispiele nicht gefunden","missingTheInformationSamplesINeed","thumb-down"],["Problem mit der Übersetzung","translationIssue","thumb-down"],["Sonstiges","otherDown","thumb-down"]],["Zuletzt aktualisiert: 2025-08-11 (UTC)."],[],[],null,["# Create streams and ingest data\n\nThe first step in analyzing your video data with an application is\ncreating a pipeline for the continuous flow of data.\nStreams offers the ability to ingest real-time video data, which then\ncan be used as input for models or stored in a Warehouse.\n\nCreate a Stream\n---------------\n\nTo be able to stream video data you must first create a stream.\n\n\nThe first time you create a stream in a new project it can take some time to create the stream.\nThis time is around 30 minutes. This time is due to the system needing to initialize a\ncomputation cluster for subsequent computations.\n\n\u003cbr /\u003e\n\n### Console\n\nCreate a stream in the Google Cloud console.\n\n1. Open the **Streams** tab of the Vertex AI Vision dashboard.\n\n [Go to the Streams tab](https://console.cloud.google.com/ai/vision-ai/video-streams)\n2. Click add**Register**.\n\n3. Enter the stream name and select a region. You can click **Add Row** to\n register multiple streams at the same time.\n\n4. Click the **Register** button to create one or more streams.\n\nIngest videos\n-------------\n\nAfter you have created a stream you can begin to ingest data using that stream.\n\n\nSome limitations and considerations apply to ingested video:\n\n- The input video source must have the following specifications:\n - [H.264 encoding](https://en.wikipedia.org/wiki/Advanced_Video_Coding)\n - \\\u003c= 1080p resolution\n - \\~25\n\n If the video doesn't meet these specifications Vertex AI Vision may not\n process the input well.\n- Audio is dropped during ingestion.\n- If the stream is part of an app connected to a warehouse, video parameters (such as FPS or resolution) must be the same for the whole stream ; variations in RTSP video data parameters or local video data parameters are not supported.\n- Due to model startup latency, ingested videos may have the first few seconds of content missing. This amount of time can reach up to fifteen seconds.\n- Ingestion termination can happen after long connection (\\~5 hours, on average). There's no reconnection capability from the `vaictl` tool ; users must manually reconnect.\n- While `vaictl` is a useful tool for ingesting video data, the tool does not automatically handle recovery from network errors. These errors may either come from the data-source side or the Cloud-ingestion side. It's the user's responsibility to create a restart script to handle unexpected `vaictl` operation terminations.\n\n\u003cbr /\u003e\n\n### Vertex AI Vision SDK\n\nTo send a request to ingest video data using an existing stream you must\n[install the Vertex AI Vision SDK](/vision-ai/docs/cloud-environment#install_the_streams_sdk).\n\n\n| **Note** : You may need to establish user access credentials by running the following command: `gcloud auth application-default login`. For more information about this command, see the [Vertex AI Vision SDK\n| reference documentation](/sdk/gcloud/reference/auth/application-default/login).\n\n\u003cbr /\u003e\n\nMake the following variable substitutions:\n\n- \u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e: Your Google Cloud project ID.\n- \u003cvar translate=\"no\"\u003eLOCATION_ID\u003c/var\u003e: Your location ID. For example, `us-central1`. [More information](/about/locations). [Supported regions](/vision-ai/docs/warehouse-supported-regions).\n- \u003cvar translate=\"no\"\u003eLOCAL_FILE.EXT\u003c/var\u003e: The filename of a local video file. For example, `my-video.mp4`.\n- \u003cvar translate=\"no\"\u003eSTREAM_ID\u003c/var\u003e: The stream ID that you created in the cluster For example, `input-1`.\n- \u003cvar translate=\"no\"\u003eRTSP_ADDRESS\u003c/var\u003e: The address of your Real Time Streaming Protocol ([RTSP](https://en.wikipedia.org/wiki/Real_Time_Streaming_Protocol)) feed. For example, `rtsp://my-ip-camera`.\n\n**Local video data:** \n\n # This command streams a video file to a stream. Streaming ends when the video ends.\n vaictl -p \u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e \\\n -l \u003cvar translate=\"no\"\u003eLOCATION_ID\u003c/var\u003e \\\n -c application-cluster-0 \\\n --service-endpoint visionai.googleapis.com \\\n send video-file to streams \u003cvar translate=\"no\"\u003eSTREAM_ID\u003c/var\u003e --file-path \u003cvar translate=\"no\"\u003eLOCAL_FILE.EXT\u003c/var\u003e\n\n**Local video data (looped):** \n\n # This command streams a video file to a stream. Video is looped into the stream until you stop the command.\n vaictl -p \u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e \\\n -l \u003cvar translate=\"no\"\u003eLOCATION_ID\u003c/var\u003e \\\n -c application-cluster-0 \\\n --service-endpoint visionai.googleapis.com \\\n send video-file to streams \u003cvar translate=\"no\"\u003eSTREAM_ID\u003c/var\u003e --file-path \u003cvar translate=\"no\"\u003eLOCAL_FILE.EXT\u003c/var\u003e --loop\n\n**Real Time Streaming Protocol (RTSP) feed data:** \n\n # This command will send an RTSP feed into the stream.\n # This command has to run in the network that has direct access to the RTSP feed.\n vaictl -p \u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e \\\n -l \u003cvar translate=\"no\"\u003eLOCATION_ID\u003c/var\u003e \\\n -c application-cluster-0 \\\n --service-endpoint visionai.googleapis.com \\\n send rtsp to streams \u003cvar translate=\"no\"\u003eSTREAM_ID\u003c/var\u003e --rtsp-uri \u003cvar translate=\"no\"\u003eRTSP_ADDRESS\u003c/var\u003e\n\nPlay ingested videos\n--------------------\n\nAfter you have created a stream and sent video content to the stream you can\nplay the video content.\n\nIf you leave the stream view tab open for more than one hour, you must\nrefresh the page to continue to load video contents. \n\n### Console\n\nPlay ingested video in the Google Cloud console.\n\n1. Open the **Streams** tab of the Vertex AI Vision dashboard.\n\n [Go to the Streams tab](https://console.cloud.google.com/ai/vision-ai/video-streams)\n2. Click on the stream name from the streams list.\n\n3. In the video stream detail page the ingested video live view\n automatically loads."]]