Mantenha tudo organizado com as coleções
Salve e categorize o conteúdo com base nas suas preferências.
Nesta página, você verá informações básicas sobre como as GPUs funcionam com o Dataflow, incluindo informações sobre pré-requisitos e tipos de GPU compatíveis.
O uso de GPUs em jobs do Dataflow permite acelerar algumas tarefas de processamento de dados. As GPUs podem executar determinados cálculos mais rapidamente do que as CPUs. Esses cálculos geralmente são álgebra numérica ou linear, geralmente usados em casos de uso de processamento de imagem e machine learning. A
extensão da melhoria de desempenho varia de acordo com o caso de uso, o tipo de computação
e a quantidade de dados processados.
Pré-requisitos para usar GPUs no Dataflow
Para usar GPUs com o job do Dataflow, use o Runner v2.
O Dataflow executa o código do usuário nas VMs do worker dentro de um contêiner do Docker.
Essas VMs de worker executam o Container-Optimized OS.
Para que os jobs do Dataflow usem GPUs, você precisa dos seguintes pré-requisitos:
Os drivers de GPU são instalados em VMs do worker e acessíveis ao contêiner
do Docker. Para mais informações, consulte Instalar drivers de GPU.
A tabela a seguir fornece recomendações de qual tipo de GPU usar em diferentes cargas de trabalho. Os exemplos na tabela são apenas sugestões. Você
precisa testar no seu ambiente para determinar o tipo de GPU apropriado para
a carga de trabalho.
Para informações mais detalhadas sobre o tamanho da memória da GPU, a disponibilidade de recursos e
os tipos de carga de trabalho ideais para diferentes modelos de GPU, consulte a
tabela geral de comparação
na página de plataformas de GPU.
[[["Fácil de entender","easyToUnderstand","thumb-up"],["Meu problema foi resolvido","solvedMyProblem","thumb-up"],["Outro","otherUp","thumb-up"]],[["Difícil de entender","hardToUnderstand","thumb-down"],["Informações incorretas ou exemplo de código","incorrectInformationOrSampleCode","thumb-down"],["Não contém as informações/amostras de que eu preciso","missingTheInformationSamplesINeed","thumb-down"],["Problema na tradução","translationIssue","thumb-down"],["Outro","otherDown","thumb-down"]],["Última atualização 2025-08-18 UTC."],[[["\u003cp\u003eDataflow jobs using GPUs can accelerate data processing, especially for numeric or linear algebra computations like those in image processing and machine learning.\u003c/p\u003e\n"],["\u003cp\u003eUsing GPUs in Dataflow requires Dataflow Runner v2 and incurs charges detailed on the Dataflow pricing page.\u003c/p\u003e\n"],["\u003cp\u003ePrerequisites for GPU usage include having GPU drivers installed on worker VMs and GPU libraries installed in the custom container image.\u003c/p\u003e\n"],["\u003cp\u003eDataflow supports several NVIDIA GPU types, including L4, A100 (40 GB and 80 GB), Tesla T4, P4, V100, and P100, each suited for different workload sizes and types.\u003c/p\u003e\n"],["\u003cp\u003eThe boot disk size for GPU containers should be increased to at least 50 gigabytes to prevent running out of disk space, due to the large nature of these containers.\u003c/p\u003e\n"]]],[],null,["# Dataflow support for GPUs\n\n\u003cbr /\u003e\n\n| **Note:** The following considerations apply to this GA offering:\n|\n| - Jobs that use GPUs incur charges as specified in the Dataflow [pricing page](/dataflow/pricing).\n| - To use GPUs, your Dataflow job must use [Dataflow Runner v2](/dataflow/docs/runner-v2).\n\n\u003cbr /\u003e\n\nThis page provides background information on how GPUs work with\nDataflow, including information about prerequisites and supported\nGPU types.\n\nUsing GPUs in Dataflow jobs lets you accelerate\nsome data processing tasks. GPUs can perform certain computations faster\nthan CPUs. These computations are usually numeric or linear algebra,\noften used in image processing and machine learning use cases. The\nextent of performance improvement varies by the use case, type of computation,\nand amount of data processed.\n\nPrerequisites for using GPUs in Dataflow\n----------------------------------------\n\n\n- To use GPUs with your Dataflow job, you must use Runner v2.\n- Dataflow runs user code in worker VMs inside a Docker container. These worker VMs run [Container-Optimized OS](/container-optimized-os/docs). For Dataflow jobs to use GPUs, you need the following prerequisites:\n - GPU drivers are installed on worker VMs and accessible to the Docker container. For more information, see [Install GPU drivers](/dataflow/docs/gpu/use-gpus#drivers).\n - GPU libraries required by your pipeline, such as [NVIDIA CUDA-X libraries](https://developer.nvidia.com/gpu-accelerated-libraries) or the [NVIDIA CUDA Toolkit](https://developer.nvidia.com/cuda-toolkit), are installed in the custom container image. For more information, see [Configure your container image](/dataflow/docs/gpu/use-gpus#container-image).\n- Because GPU containers are typically large, to avoid [running out of disk space](/dataflow/docs/guides/common-errors#no-space-left), increase the default [boot disk size](/dataflow/docs/reference/pipeline-options#worker-level_options) to 50 gigabytes or more.\n\n\u003cbr /\u003e\n\nPricing\n-------\n\nJobs using GPUs incur charges as specified in the Dataflow\n[pricing page](/dataflow/pricing).\n\nAvailability\n------------\n\nThe following GPU types are supported with Dataflow:\n\nFor more information about each GPU type, including performance data, see\n[Compute Engine GPU platforms](/compute/docs/gpus).\n\nFor information about available regions and zones for GPUs, see\n[GPU regions and zones availability](/compute/docs/gpus/gpu-regions-zones)\nin the Compute Engine documentation.\n\n### Recommended workloads\n\nThe following table provides recommendations for which type of GPU to use for\ndifferent workloads. The examples in the table are suggestions only, and you\nneed to test in your own environment to determine the appropriate GPU type for\nyour workload.\n\nFor more detailed information about GPU memory size, feature availability, and\nideal workload types for different GPU models, see the\n[General comparison chart](/compute/docs/gpus#general_comparison_chart)\non the GPU platforms page.\n\nWhat's next\n-----------\n\n- See an example of a [developer workflow for building pipelines that use GPUs](/dataflow/docs/gpu/develop-with-gpus).\n- Learn how to [run an Apache Beam pipeline on Dataflow with GPUs](/dataflow/docs/gpu/use-gpus).\n- Work through [Processing Landsat satellite images with GPUs](/dataflow/docs/samples/satellite-images-gpus)."]]