A High-Performance Implementation of Bayesian Matrix Factorization with Limited Communication

Tom Vander Aa, Xiangju Qin, Paul Blomstedt, Roel Wuyts, Wilfried Verachtert, Samuel Kaski

Introduction

Bayesian Matrix Factorization (BMF) is widely regarded as the "gold standard" for recommender systems and drug discovery due to its ability to provide uncertainty estimates and avoid overfitting. However, BMF is computationally intensive, typically relying on sequential Gibbs sampling. This has historically limited its application to smaller datasets, while faster but less robust methods like Stochastic Gradient Descent (SGD) are used for web-scale data.

Researchers from imec and Aalto University have proposed a high-performance implementation that combines algorithmic innovation with massive distributed computing to scale BMF to datasets with hundreds of millions of entries.

Methodology: Two-Level Parallelization

The core of the proposed framework is a "two-level" parallelization strategy designed to overcome the "communication wall"—a common bottleneck where distributed nodes spend more time communicating than calculating.

Level 1: Posterior Propagation (PP)

The global data matrix is partitioned into a grid of blocks. The algorithm proceeds in phases (e.g., Phase A, B, and C). Blocks within the same phase are processed in parallel with zero communication between them. The results from one phase are passed as "priors" to the next, maintaining model consistency and identifiability while enabling massive parallelism.

Posterior Propagation (PP) partitioning of the data matrix into blocks for phased parallel processing.

Level 2: Distributed BMF

Within each individual block, the implementation utilizes a distributed approach. Rather than relying on a single CPU, the block's rows and columns are further divided across multiple nodes using asynchronous communication via the Message Passing Interface (MPI). This nested parallelism allows the system to engage thousands of processors simultaneously without the typical overhead associated with large-scale distribution.

Experimental Setup and Datasets

The implementation was evaluated on four classic web-scale benchmarks, ranging from 20 million to over 260 million ratings. These datasets represent various challenges, including extreme sparsity and high row counts.

Characteristics of the web-scale benchmark datasets used in the study.

Key Insights and Results

  • The "Square Block" Rule: The researchers found that blocks in the PP grid should be approximately square to optimize the ratio of information (area) to communication overhead (circumference).
  • Synergy of Scale: Accuracy actually improves when parallelized blocks are larger. By using distributed computing inside the blocks, the researchers can afford larger block sizes, enhancing both speed and model quality.
  • Computational Performance: On the Netflix dataset, the team achieved a 68x speedup compared to a single-block implementation. The system demonstrated scalability up to 16,000 nodes on supercomputing clusters.
  • Accuracy: The combined D-BMF+PP method maintained the high accuracy (RMSE) characteristic of traditional BMF, frequently outperforming non-Bayesian competitors like NOMAD and FPSGD.

Limitations and Future Work

While the performance gains are significant, the method is resource-intensive, requiring substantial hardware for peak scaling. Future research will focus on improving Gibbs sampling efficiency—potentially by reducing samples in later phases—and exploring alternative communication protocols like GASPI (Global Address Space Programming Interface) to further optimize asynchronous updates.

Summary updated

BibTeX
@inproceedings{aa2020high,
  author = {Tom Vander Aa and Xiangju Qin and Paul Blomstedt and Roel Wuyts and Wilfried Verachtert and Samuel Kaski},
  title = {{A High-Performance Implementation of Bayesian Matrix Factorization with Limited Communication}},
  booktitle = {ICCS},
  year = {2020},
  doi = {10.1007/978-3-030-50433-5\_1},
}
Figure