TAC+: Optimizing Error-Bounded Lossy Compression for 3D AMR Simulations

Daoce Wang, Jesus Pulido, Pascal Grosset, Sian Jin, Jiannan Tian, Kai Zhao, James P. Ahrens, Dingwen Tao

Abstract

Adaptive Mesh Refinement (AMR) is a critical technique in high-performance computing (HPC) for managing multi-scale physical phenomena. However, the hierarchical and sparse nature of AMR data poses significant challenges for traditional error-bounded lossy compressors. We introduce TAC+, a novel compression framework that optimizes data pre-processing through adaptive partitioning and introduces Shared Huffman Encoding (SHE) to minimize metadata overhead. Our evaluation across diverse 3D AMR datasets demonstrates that TAC+ achieves up to a 4.9× higher compression ratio compared to state-of-the-art methods while preserving scientific accuracy and significantly improving throughput.

Introduction

Modern scientific simulations, such as those in cosmology and fluid dynamics, generate petabytes of data, necessitating efficient storage solutions. Adaptive Mesh Refinement (AMR) addresses this by applying high-resolution "fine" meshes only to regions of interest, while maintaining "coarse" meshes elsewhere. While AMR optimizes simulation performance, it complicates data compression.

Standard lossy compressors like SZ and ZFP are optimized for uniform grids. Applying them to AMR data typically involves two suboptimal approaches: flattening the hierarchy into a 1D array or upsampling to a uniform 3D grid. Flattening destroys spatial locality, hindering the compressor's ability to use neighboring values for prediction. Conversely, upsampling introduces massive redundancy by filling "empty" regions with placeholder values, leading to bloated datasets.

Comparison of 1D baseline flattening versus 2/3D baseline upsampling for AMR data levels.

The TAC+ Framework

To overcome these challenges, we propose Tensor-based AMR Compression (TAC) and its enhanced version, TAC+. The core philosophy of TAC+ is to treat each AMR level as a 3D object to leverage spatial predictors while minimizing the overhead of redundant data.

Adaptive Pre-processing

TAC+ employs three primary strategies based on the density of the data at each AMR level:

  1. Ghost-Shell Padding (GSP): For relatively dense levels, GSP fills empty regions with the average values of adjacent real data. This smoothing prevents artificial sharp gradients at boundaries, improving the prediction accuracy of the underlying compressor.
  2. Optimized Sparse Tensor (OpST): For sparse levels, OpST extracts non-empty data blocks to avoid processing redundant space.
  3. Adaptive k-d Tree (AKDTree): This strategy partitions sparse data into blocks of varying sizes, aiming to maximize the size of contiguous 3D blocks to preserve as much spatial context as possible.

Shared Huffman Encoding (SHE)

A major bottleneck in block-based compression is the metadata overhead. When a dataset is partitioned into thousands of small blocks, the Huffman trees (dictionaries) required for each block can collectively exceed the size of the compressed data itself. TAC+ introduces Shared Huffman Encoding (SHE), which allows blocks to be predicted individually but encoded using a single, globally optimized Huffman tree. This "Plus" feature drastically reduces metadata while maintaining the benefits of fine-grained partitioning.

The TAC+ architectural pipeline, illustrating the pre-processing modules and the integration of Shared Huffman Encoding.

Experimental Evaluation

We evaluated TAC+ using ten datasets from three major HPC frameworks: Nyx (cosmology), WarpX (plasma physics), and IAMR (fluid dynamics).

Key Results

  • Compression Efficiency: TAC+ outperformed the state-of-the-art zMesh compressor by up to 4.9× under identical error constraints.
  • Throughput: On highly sparse datasets, TAC+ achieved up to 75× higher throughput than standard 3D baselines by bypassing the processing of redundant upsampled regions.
  • Fidelity and Accuracy: By using GSP, TAC+ significantly improved Peak Signal-to-Noise Ratio (PSNR) compared to simple zero-filling. Furthermore, in domain-specific analyses like "Halo Finding" in Nyx simulations, TAC+ maintained higher structural accuracy than standard 3D compression.

Conclusion

TAC+ effectively bridges the gap between the hierarchical complexity of AMR simulations and the requirements of modern lossy compressors. By intelligently managing spatial locality and metadata overhead through SHE, it provides a scalable solution for exascale data management. Future work will focus on parallelizing partitioning strategies for multi-core and GPU architectures to enable real-time in-situ compression.

Summary updated

BibTeX
@article{wang2024tac,
  author = {Daoce Wang and Jesus Pulido and Pascal Grosset and Sian Jin and Jiannan Tian and Kai Zhao and James P. Ahrens and Dingwen Tao},
  title = {{TAC+: Optimizing Error-Bounded Lossy Compression for 3D AMR Simulations}},
  journal = {IEEE Trans. Parallel Distributed Syst.},
  year = {2024},
  doi = {10.1109/tpds.2023.3339474},
}
Figure