Hugging Face and Graphcore are making it significantly easier to run Transformer models on specialized AI hardware. The two companies have partnered to bring Optimum, Hugging Face’s open-source library for hardware acceleration, to Graphcore’s Intelligence Processing Units (IPUs). BERT is the first model optimized for this integration, with vision, speech, translation, and text generation models promised in the coming months.
The setup process involves configuring Graphcore’s Poplar SDK environment, installing PopTorch to bridge PyTorch models with IPU hardware, and then adding the Optimum Graphcore package. The workflow is straightforward for anyone already familiar with Python environments: source the Poplar and PopART enable scripts, create a virtual environment, install PopTorch, and pip install the Optimum Graphcore package. From there, developers clone the Optimum Graphcore repository and access ready-to-run examples.
A sample script fine-tunes BERT on the SQuAD1.1 question-answering dataset using a standard training configuration: 3 epochs, a learning rate of 6e-5, max sequence length of 384, and a batch size of 2. The script leverages Hugging Face’s Datasets library for data management, which brings git-based versioning to training data—a feature that makes reproducing experiments far less painful than the traditional approach of scattered CSV files and manual data splits.
What’s notable here is how little code actually changes. PopTorch is designed so PyTorch models can run on IPUs with minimal modification, and Optimum handles the translation layer between Transformers and the IPU runtime. Graphcore has been pushing hard to lower the barrier to entry for its hardware, and this partnership does exactly that. Whether the performance gains justify the hardware investment remains an open question for most teams, but the integration work is no longer the bottleneck it once was.