On Optimal Partitioning For Sparse Matrices In Variable Block Row Format

Willow Ahrens, Erik G. Boman
5/25/2020
10 citations
cs.DS

Official code: willow-ahrens/ChainPartitioners.jl (2 stars, Julia, MIT, last commit 2023-11-15). 1 more implementation below.

Abstract

The Variable Block Row (VBR) format is an influential blocked sparse matrix format designed for matrices with shared sparsity structure between adjacent rows and columns. VBR groups adjacent rows and columns, storing the resulting blocks that contain nonzeros in a dense format.

Show full abstract

This reduces the memory footprint and enables optimizations such as register blocking and instruction-level parallelism. Existing approaches use heuristics to determine which rows and columns should be grouped together. We show that finding the optimal grouping of rows and columns for VBR is NP-hard under several reasonable cost models. In light of this finding, we propose a 1-dimensional variant of VBR, called 1D-VBR, which achieves better performance than VBR by only grouping rows. We describe detailed cost models for runtime and memory consumption. Then, we describe a linear time dynamic programming solution for optimally grouping the rows for 1D-VBR format. We extend our algorithm to produce a heuristic VBR partitioner which alternates between optimally partitioning rows and columns, assuming the columns or rows to be fixed, respectively. Our alternating heuristic produces VBR matrices with the smallest memory footprint of any partitioner we tested.

View on arXivView PDF

Code Implementations(2)

Code implementations of this paper
RepositoryTypeStarsLanguageLicenseLast commit
willow-ahrens/ChainPartitioners.jlOfficial2JuliaMIT2023-11-15
willow-ahrens/SparseMatrixVBCs.jlOfficial0JuliaMIT2023-11-15
MIT

Contiguous sparse matrix partitioners

21Julia, ShellNov 6, 20203 years agoMIT
MIT
01JuliaJan 29, 20203 years agoMIT

Similar Papers

Cite this paper

@article{ahrens2020optimal,
  title  = {On Optimal Partitioning For Sparse Matrices In Variable Block Row Format},
  author = {Willow Ahrens and Erik G. Boman},
  year   = {2020},
  eprint = {2005.12414},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/abs/2005.12414}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2005.12414.svg)](https://codeofpaper.com/paper/2005.12414)

Discussion