Production-quality Tools for Adaptive Mesh Refinement Visualization

Table of Contents

Introduction


Figure 1: AMR hierarchy consisting of 4 patches in 3 hierarchy levels.

Adaptive Mesh Refinement (AMR) techniques combine the compact, implicitly specified structure of regular, rectilinear with the adaptivity to changes in scale of unstructured grids, see Figure 1. Handling AMR data for visualization is challenging, since coarser information in regions covered by finer patches is superseded and replaced with information from these finer patches. During visualization it becomes necessary to manage selection of which resolutions are being used. Furthermore, it is difficult to avoid discontinuities at level boundaries, which, if not properly handled, lead to visible artifacts in visualizations. Due to these difficulties, AMR support as first class data type in production visualization tools has been lacking despite the growing popularity of AMR simulations.

AMR Support in VisIt


Figure 2: Production-quality visualization of an AMR simulation of a hydrogen flame (h2swirl). The left panel shows a pseudocolor plot restricted to three axis-perpendicular slices. The right panel shows a volume rendered image of the same data. (Click on images to view a larger version.)

VisIt is an open source visualization tool that accommodates AMR as first class data type. VisIt handles AMR data as a special case of “ghost data,” i.e., data that is used to make computations more efficient, but which is not considered to be part of the simulation result. VisIt tags cells in coarse patches that are available at finer resolution as “ghost” cells, allowing AMR patches to retain their highly efficient native format as rectilinear grids. VisIt offers a rich set of production-quality functions, such as pseuodcolor and volume rendering plots (Figure 2), for visualization and analysis of massive scale data sets, making it an ideal candidate to replace specialized AMR visualization tools.

VisIt Enhancements

The majority of our work focused on implementing a set of essential debugging features offered by ChomboVis in VisIt. These efforts improve VisIt's handling of AMR data, both in terms of interface and performance, and will allow the Applied Partial Differential Equations Software Infrastructure Center (APDEC) to replace the ChomboVis tool with VisIt.

Interface Enhancements


Figure 3: Spreadsheet plots are an important tool for debugging AMR codes. They support direct viewing of numerical data in patch cells. VisIt labels selected cells both in Spreadsheet and 3D visualizations allowing users to recognize correspondences quickly and effectively. (Click on image to view a larger version.)

ChomboVis provides spreadsheet ”plots“ that support direct viewing of numerical values on a particular slice of a patch. This function is essential for debugging and used by AMR code development teams on a daily basis. We added these spreadsheets to VisIt, see Figure 3, and connected them to VisIt's ”pick cell“ feature, allowing users to ”link“ them to other plots. We further added a capability to create new buttons in the VisIt interface. This matches a capability that APDEC users valued in ChomboVis and allows new users to quickly navigate the tool. We also modified the VisIt selection routines to better support AMR data, allowing users to specify selections in terms of cell indices in a particular AMR level.

Performance Enhancements

We optimized handling of AMR grids in VisIt. These optimizations can save on memory by a factor of ten and also support more efficient rendering. Additional performance and memory optimizations improve efficiency for the important use case of rendering patch boundaries. VisIt previously used a very general algorithm that was unnecessarily slow. Our new, specialized algorithm is an order of magnitude faster and more memory efficient.

Further Reading and References

Acknowledgements

This work was performed by the LBNL Visualization Group as part of the Visualization and Analytics Center for Enabling Technologies (VACET). It includes significant contributions from other VACET sites, most notably the VisIt development teams from the Lawrence Livermore National Laboratory and the Oak Ridge National Laboratory.