GPU (Graphics Processing Unit)
Originally built to render pixels for games, GPUs are general-purpose parallel processors. They contain thousands of small cores that can each do simple math operations simultaneously — great for matrix multiplication, which is exactly what neural networks are built on.
Key traits:
Flexible — runs almost any workload (graphics, ML, scientific computing, crypto mining)
Wide software support (CUDA, ROCm, works with PyTorch/TensorFlow out of the box)
Available from many vendors (NVIDIA, AMD, Intel)
You can rent one on almost any cloud, or buy one for your desk
TPU (Tensor Processing Unit)
TPUs are Google's custom-built chips, designed from the ground up for one thing: tensor operations (the math behind deep learning — matrix multiplies and convolutions). Nothing else. No graphics rendering, no general compute.
Key traits:
ASIC (Application-Specific Integrated Circuit) — hardware built for a narrow job, not a flexible one
Extremely fast and power-efficient specifically for large-scale matrix math
Only available through Google Cloud (you can't buy one to put in your PC)
Tightly coupled with TensorFlow/JAX; PyTorch support exists but is less mature
The Core Difference in One Line
A GPU is a powerful generalist. A TPU is a specialist that gave up flexibility to become brutally efficient at one job: tensor math for deep learning.
When to Use Which
SituationBetter ChoiceTraining massive models at Google-scaleTPULocal development, mixed workloads, wide framework supportGPUYou need CUDA-specific librariesGPUYou're already deep in the Google Cloud / TensorFlow / JAX ecosystemTPUYou want hardware you can actually ownGPU
Bottom Line
Think of it like tools in a workshop. A GPU is a high-end multi-tool — it does a lot of things well. A TPU is a machine built for exactly one task on an assembly line — unbeatable at that task, useless for anything else. Most engineers outside of Google's own infrastructure will reach for GPUs simply because of ecosystem maturity and flexibility, even though TPUs can win on raw efficiency for massive training runs.
