MGARD: A multigrid framework for high-performance, error-controlled data compression and refactoring

Qian Gong, Jieyang Chen, Ben Whitney, Xin Liang, Viktor Reshniak, Tania Banerjee, Jaemoon Lee, Anand Rangarajan, Lipeng Wan, Nicolas Vidal, Qing Liu, Ana Gainaru, Norbert Podhorszki, Richard Archibald, Sanjay Ranka, Scott KlaskyarXiv 2024 · DOI

TL;DR

MGARD (MultiGrid Adaptive Reduction for Data) is a high-performance software framework that uses multigrid decomposition to compress and refactor massive scientific datasets. Unlike standard compressors, it provides mathematically guaranteed error control for both raw data and derived scientific quantities, significantly accelerating I/O while running seamlessly across diverse CPU and GPU architectures.

What Problem Does This Paper Address?

Modern scientific simulations and instruments are drowning in data. For example, the Square Kilometer Array (SKA) telescope is expected to generate 600 Petabytes of data annually. Current network and storage speeds simply cannot keep up with this "data deluge."

While lossless compression (like ZIP) works for text, it is notoriously ineffective for floating-point scientific data because the "random" nature of trailing mantissa bits limits compression ratios. Lossy compression is the only viable path forward, but scientists are often hesitant to use it because they need to ensure that the "noise" introduced by compression doesn't invalidate their scientific results. Existing tools often lack support for unstructured grids, struggle with GPU memory limits, or fail to provide precise error bounds for specific scientific metrics (Quantities of Interest).

Methods

MGARD tackles these issues through a hierarchical approach. The core idea is multilevel decomposition, where data is recursively broken down into a sequence of approximations at different resolution levels.

Figure 1: The software pipeline overview illustrating the two primary functionalities of MGARD – compression and refactoring, both with precision error control.

The framework offers two main paths:

  1. Compression: The multilevel coefficients are linearly quantized (turned into integers) and then losslessly encoded. This is optimized for maximum storage reduction.
  2. Refactoring: Data is encoded into "precision segments" using bitplane encoding. This allows for progressive retrieval, where a user can download a coarse version of the data first and then incrementally add more detail/precision as needed.

Crucially, MGARD uses finite element theory to provide mathematical guarantees on error bounds. It doesn't just control the maximum error in a single pixel; it can be tuned to preserve specific Quantities of Interest (QoIs), such as the average temperature or density in a sub-region of a simulation.

Datasets

The authors evaluated MGARD across several high-impact scientific domains:

  • XGC: A fusion physics code simulating plasma dynamics (5D particle distribution functions).
  • NYX: A cosmological hydrodynamics simulation used to study the early universe.
  • E3SM: The Department of Energy’s flagship Earth system (climate) model.
  • SKA: Data from the world's largest radio telescope arrays.

Key Insights and Ideas

  • QoI-Aware Compression: One of the most significant "aha" moments is that you don't need to preserve every bit of raw data perfectly to get perfect scientific results. By using Lagrange multipliers to optimize for specific derived quantities, MGARD can achieve much higher compression ratios than "blind" compressors while keeping scientific errors near zero.
  • Hardware Agnostic by Design: MGARD is built with a modular architecture that uses device abstractions. This means the same high-level code can run on NVIDIA (CUDA), AMD (HIP), or Intel (SYCL) GPUs, as well as various CPUs.
  • Out-of-Core Processing: To handle datasets larger than a GPU's memory, MGARD includes a manager that automatically tiles data and handles host-to-device transfers, removing a major headache for researchers working with massive arrays.
Figure 2: Software architecture of MGARD

Key Results

  • Massive Reduction: In XGC plasma simulations, MGARD achieved 200x to 290x data reduction while keeping relative errors in derived quantities (like density and temperature) below $10^{-8}$. Without these optimizations, standard compression at the same ratio resulted in much higher errors ($10^{-2}$).
  • High Throughput: On the Summit supercomputer, MGARD's GPU implementation outperformed other state-of-the-art compressors like cuSZ and ZFP-CUDA in both compression and decompression speeds.
  • Scientific Accuracy: In climate modeling (E3SM), using MGARD-compressed hourly data allowed for more accurate tropical cyclone tracking than using uncompressed 6-hourly data, despite using only 1/4 of the storage.

Limitations and Future Work

While MGARD is highly versatile, the paper notes that ongoing work is required to integrate it more deeply into specific domain-specific I/O pipelines, such as the Casacore Table Data System used in radio astronomy. Additionally, while it supports unstructured grids, the performance auto-tuning for these more complex topologies is an area of continuous refinement. The paper primarily focuses on the framework's capabilities and performance rather than exploring the theoretical limits of the underlying multigrid algorithms.

Summary updated

BibTeX
@misc{gong2024mgard,
  author = {Qian Gong and Jieyang Chen and Ben Whitney and Xin Liang and Viktor Reshniak and Tania Banerjee and Jaemoon Lee and Anand Rangarajan and Lipeng Wan and Nicolas Vidal and Qing Liu and Ana Gainaru and Norbert Podhorszki and Richard Archibald and Sanjay Ranka and Scott Klasky},
  title = {{MGARD: A multigrid framework for high-performance, error-controlled data compression and refactoring}},
  year = {2024},
  eprint = {2401.05994},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2401.05994},
}
Figure