🔍 Read the full analysis: A Walkthrough Of PyTorch’s Approach To Training AI on ThorstenMeyerAI.com
Get the latest gadgets delivered free with Prime
- Fast, free delivery on millions of items
- Prime Video, Amazon Music and more included
- Member-only deals all year
TL;DR
A November 22 explainer from ThorstenMeyerAI.com walks through how PyTorch trains neural networks, from tensors and automatic differentiation to accelerators and the training loop. It also describes a new effort by Google and Meta to run PyTorch on Google TPUs, while noting that hardware changes can still require code adjustments.
ThorstenMeyerAI.com published a walkthrough of PyTorch on November 22, explaining how the open-source Python library turns model data and calculations into neural-network training. The report comes as Google and Meta have presented TorchTPU, a way to run PyTorch natively on Google’s AI chips, and AWS’s native PyTorch backend for Trainium, TorchNeuron, entered public beta on October 20. The developments matter because PyTorch sits between AI teams’ code and the chips used to train models, though moving code between chip types may still require changes.
The explainer organizes PyTorch training around five parts: tensors store data and model weights; autograd tracks calculations and determines gradients; accelerators such as GPUs perform heavy computation; the training loop applies those gradients to update a model; and torch.compile can optimize code execution. PyTorch’s central design choice is eager execution: Python runs operations as it reaches them, building the calculation graph during execution. The project’s documentation describes this principle as “what you run is what you differentiate.”
In the explainer’s account, a training loop repeatedly sends batches of examples through a model, measures the difference between its output and the expected answer, and uses gradients to adjust weights. A tensor can represent anything from a single value to a batch of images; its shape, data type and device determine how it is stored and handled. The report says most of PyTorch is written in C++ for performance, while Python provides the interface used by many developers.
The piece also situates PyTorch alongside JAX and TensorFlow, describing different programming approaches rather than naming a best framework. It says PyTorch is eager by default with optional compilation, JAX uses composable function transformations, and TensorFlow 2 is eager by default while allowing functions to be converted into graphs with tf.function. PyTorch 2.15, released October 28, is reported to include 3,117 commits from 583 contributors since version 2.14 and to support Python 3.11 through 3.15.
Why Chip Support Matters
For AI developers and organizations, a framework choice shapes how models are built, how teams hire, and which hardware they can use without rewriting their systems. Native PyTorch support on more chip platforms could make it easier for companies to evaluate alternatives to their current accelerators. That flexibility matters as chip suppliers compete to attract users whose models and staff already depend on PyTorch.
But the announced backends do not establish that switching hardware is effortless or that every model will perform equally well. The explainer says the stated TorchTPU goal is to make a basic port as simple as changing a device name from “cuda” to “tpu.” It also reports that TorchTPU’s authors cautioned that peak performance can still require code changes. The distinction is practical: initial compatibility may reduce the work needed to test a chip, while tuning a production workload may involve additional engineering.
Popular right now

KitchenAid Artisan 5-Quart Tilt-Head Stand Mixer, Almond Cream

Apple AirPods Pro (2nd Generation) Wireless Earbuds with USB-C MagSafe Charging Case

Hisense 85U6SF Pro 85-Inch U6 Pro Mini-LED 4K UHD Smart Fire TV
As an affiliate, we earn on qualifying purchases.
From Meta Project to Foundation
PyTorch began in 2016, and its first public release followed in January 2017, according to the research paper cited by ThorstenMeyerAI.com. That 2019 paper described the library as an imperative, high-performance deep-learning tool in which users’ programs remain regular Python programs. On September 12, 2022, governance moved to the PyTorch Foundation, a project of the Linux Foundation. The source says technical decisions remain with individual maintainers, while the foundation provides a vendor-neutral home for the project.
The foundation’s first governing board included representatives from AMD, AWS, Google Cloud, Meta, Microsoft Azure and Nvidia, according to the explainer. It also notes that Meta remained PyTorch’s largest contributor at the time of the move. The library is distributed under a permissive BSD-style license, allowing use, modification and redistribution subject to its stated conditions. These details help explain how a project that began with major Meta involvement came to be supported and governed across a wider group of companies.
The October 20 announcements extend that cross-company picture: Google and Meta presented TorchTPU for Google hardware, while TorchNeuron for AWS Trainium entered public beta on the same day. The source frames both as efforts to meet developers where their existing code is, rather than asking them to adopt a chip maker’s preferred framework. These are distinct backend efforts; the material does not say they share a single implementation or maturity level.
“What you run is what you differentiate.”
— PyTorch documentation, as quoted by ThorstenMeyerAI.com
Limits of Cross-Chip Compatibility
The source does not provide independent performance tests comparing TorchTPU or TorchNeuron with other hardware backends, nor does it establish how broadly either backend supports models and PyTorch features. TorchNeuron is identified as being in public beta; the material gives no equivalent maturity details for TorchTPU beyond its presentation on October 20. It is also not clear how much code adaptation typical teams will need for particular models, or how results will vary by workload. The one-line device change is presented as a goal, not proof that every model can be moved or run at peak speed without further work.
Testing the New Backends
The next practical measure will be how the announced backends work across real models, workloads and software environments. Teams considering them will need to check model compatibility, performance, reliability and the engineering effort required to tune code. The source does not name a specific release date or testing milestone for TorchTPU, and it does not say when TorchNeuron will leave public beta. For now, PyTorch 2.15 is the latest version identified in the report, and the hardware-porting claims remain subject to hands-on validation.
Key Questions
What is PyTorch used for?
PyTorch is an open-source Python library used to build and train neural networks. It supplies tools for handling data, calculating gradients and running model computations on CPUs and supported accelerators.
What are tensors in PyTorch?
Tensors are multidimensional arrays whose elements share a data type. They can represent model weights, individual values, tables or larger collections such as image batches.
What is TorchTPU?
TorchTPU is an effort presented by Google and Meta to run PyTorch natively on Google’s TPU chips. The source reports a goal of making basic porting require only a device-name change, but says peak performance may still require code modifications.
Is it now easy to move every PyTorch model between chips?
The available information does not establish that. Native backends may lower the barrier to testing other hardware, but model compatibility and performance can depend on the workload and may require further engineering.
Source: ThorstenMeyerAI.com
