Accelerating MRI Reconstruction on TPUs

Tianjian Lu, Thibault Marin, Yue Zhuo, Yi-Fan Chen, Chao Ma

Introduction

Magnetic Resonance Imaging (MRI) is a cornerstone of clinical diagnostics, yet its utility is often constrained by slow acquisition times. To mitigate this, "Compressed Sensing" (CS) is employed to reconstruct high-quality images from undersampled data. However, the iterative optimization algorithms required for CS, such as the Alternating Direction Method of Multipliers (ADMM), are computationally intensive. While GPUs have provided significant acceleration, the massive data throughput of high-resolution 3D imaging remains a bottleneck. This paper explores the repurposing of Google’s Tensor Processing Units (TPUs)—originally designed for machine learning—to accelerate iterative MRI reconstruction.

Hardware and Algorithmic Framework

The authors implemented the ADMM algorithm using TensorFlow to leverage TPU v3 hardware. The core innovation lies in the "tensorization" of the underlying physics. Instead of traditional Fast Fourier Transforms (FFTs), the researchers formulated non-uniform Fourier transforms as large-scale matrix multiplications. This approach directly exploits the TPU’s Matrix Unit (MXU), which is optimized for high-throughput tensor contractions.

TPU hardware hierarchy from chip architecture to full Pod system.

Additionally, sparsifying transforms, such as finite differences used for image regularization, were implemented as 1D convolutions (tf.nn.conv1d), another operation natively accelerated by TPU hardware. To manage the trade-off between speed and numerical stability, the implementation utilizes a hybrid precision model: bfloat16 for high-speed arithmetic and float32 for accumulation and I/O.

Parallelization and Data Decomposition

A critical component of the acceleration is the distribution of workloads across the TPU's multi-core architecture. The raw k-space data is partitioned across multiple cores, allowing for simultaneous processing.

Parallelization strategy for distributing k-space data and image dimensions across multiple TPU cores.

The TPU’s high-speed interconnect—a 2D toroidal mesh—enables efficient communication between cores. Partial results are aggregated across the entire "Pod" using collective operations like tf.cross_replica_sum. This architecture allows the system to maintain near-linear scaling even when utilizing thousands of cores.

Experimental Setup and Datasets

The methodology was validated using data from a 3T Siemens MR scanner equipped with a 12-channel phased-array coil. Evaluations included:

  • Phantom Data: Used to establish a ground truth for reconstruction accuracy.
  • Sampling Strategy: A radial-trajectory k-space pattern was retrospectively undersampled by a factor of 8.
  • Scales: Performance was tested on grid sizes ranging from $128 \times 64$ to $1024 \times 512$.

Results and Performance

The TPU-based reconstruction achieved clinical-grade accuracy, with only a ~1% relative difference compared to high-precision CPU (float64) benchmarks. The performance gains were most pronounced at larger scales. For a $1024 \times 512$ image, the TPU (128 units) completed the reconstruction in 0.29 seconds, compared to 2.24 seconds on an Nvidia V100 GPU and approximately 140 seconds on a CPU.

The system demonstrated "strong scaling," where adding more TPU cores resulted in a proportional decrease in computation time. This suggests that TPUs are not merely for neural networks but serve as powerful scientific calculators for any physics problem reducible to tensor contractions.

Conclusion and Future Work

While the current matrix-multiplication approach is highly effective, future work aims to implement a TPU-optimized Non-Uniform Fast Fourier Transform (NUFFT) to further enhance efficiency for massive 3D and 4D datasets. Although TPU access is currently centralized in the cloud, the demonstrated 8x speedup over high-end GPUs suggests a significant shift in the potential for real-time, high-resolution clinical MRI.

Summary updated

BibTeX
@inproceedings{lu2020accelerating,
  author = {Tianjian Lu and Thibault Marin and Yue Zhuo and Yi-Fan Chen and Chao Ma},
  title = {{Accelerating MRI Reconstruction on TPUs}},
  booktitle = {HPEC},
  year = {2020},
  doi = {10.1109/hpec43674.2020.9286192},
}
Figure