Speeding-up ProbLog's Parameter Learning

Francisco H. O. V. de Faria, Arthur C. Gusmão, Fábio Gagliardi Cozman, Denis Deratani MauáarXiv 2017

TL;DR

This paper tackles the slow parameter learning in ProbLog, a probabilistic logic programming system. By analyzing the inefficiencies of its EM-based learning algorithm, the authors propose a new approach that directly maximizes the log-likelihood, leading to orders-of-magnitude speedups for complete datasets. This work is crucial for making probabilistic logic programming more practical for real-world applications.

What Problem Does This Paper Address?

Probabilistic logic programming (PLP) systems, like ProbLog, combine the expressiveness of logic programming with the ability to handle uncertainty. A key task in PLP is parameter learning, where the probabilities associated with logical rules and facts are learned from data. ProbLog uses a variant of the Expectation-Maximization (EM) algorithm for this purpose, often employing Binary Decision Diagrams (BDDs) to speed up inference. However, even for relatively simple, complete datasets (where all relevant information is present), ProbLog's parameter learning is found to be surprisingly slow. This inefficiency hinders the adoption of PLP in scenarios requiring rapid learning or dealing with large datasets. The authors aim to understand and resolve this performance bottleneck.

Methods

The core of the paper's contribution lies in identifying the inefficiency of ProbLog's existing EM-based approach and proposing a direct, optimized method for parameter learning when data is complete.

  • Analysis of Existing EM: The authors pinpoint that ProbLog's EM algorithm, even with BDDs, introduces auxiliary (latent) atoms for each probabilistic rule. This, they argue, complicates the maximization step without necessarily improving learning effectiveness, especially when the input data is complete.
  • Direct Log-Likelihood Maximization: The proposed solution bypasses the EM algorithm altogether for complete data. Instead, it directly maximizes the log-likelihood function.
  • Closed-Form Solutions: A key insight is that for many common patterns of probabilistic rules (e.g., multiple rules with the same head), the log-likelihood maximization can be solved analytically in closed-form. This avoids iterative numerical optimization.
  • Gradient-Based Optimization: When closed-form solutions are not feasible, the authors propose using a fast gradient-based algorithm to find the maximum of the log-likelihood locally.

Datasets

The paper does not introduce new datasets. Instead, it uses existing examples to demonstrate the effectiveness of their proposed method:

  • A propositional program: An acyclic propositional program encoding the energy plant of a ship, involving 16 propositions, 17 probabilistic rules, and 7 probabilistic facts.
  • A short relational program: A program with probabilistic rules and facts involving predicates like fire, burglary, neighbor, and alarm, with a varying number of constants representing people in a city.

Key Insights and Ideas

  • Auxiliary atoms are not always helpful: The paper's central insight is that introducing auxiliary atoms for probabilistic rules in the EM algorithm, while a common technique, can actually slow down parameter learning for complete data by unnecessarily complicating the maximization step.
  • Direct maximization is faster: For complete data, directly maximizing the log-likelihood function is significantly more efficient than using an iterative EM approach.
  • Closed-form solutions are powerful: The existence of analytical, closed-form solutions for many common rule patterns is a critical finding that enables drastic speedups. This highlights the importance of understanding the specific structure of probabilistic programs.
  • Gradient descent as a fallback: When analytical solutions aren't available, a well-chosen numerical optimization method (like gradient descent) can still provide substantial speed improvements over the original EM.

Key Results

The paper demonstrates significant speed improvements in parameter learning:

  • Propositional Program: For a propositional dataset with 50 observations, the original ProbLog took 5498.06 seconds to reach a log-likelihood of -176.65. The proposed algorithm achieved a similar log-likelihood (-176.60) in just 2.02 seconds.
  • Relational Program: For a relational dataset with 25 constants, the original ProbLog required 1863.03 seconds to reach a log-likelihood of -523.11. The proposed algorithm achieved the same log-likelihood in a mere 0.69 seconds.
  • These results represent orders-of-magnitude speedups, as visually depicted in Figure 1 of the paper.

Limitations and Future Work

  • Focus on Complete Data: The proposed optimizations are specifically for scenarios where the input data is complete. The paper does not address improvements for learning with missing data, which would still likely require an EM-like approach.
  • Limited Rule Patterns: The implementation covers combinations of at most three rules entailing the same predicate for closed-form solutions. While this covers many common cases, more complex rule interactions might still rely on gradient-based methods.
  • Future Work: The authors suggest that these insights are crucial for future work in probabilistic logic programming, particularly for handling missing data and for rule learning (where parameter learning is a component). The focus on efficient parameter learning is seen as a key step towards making PLP more applicable in real-world settings.

Summary updated

BibTeX
@misc{faria2017speeding,
  author = {Francisco H. O. V. de Faria and Arthur C. Gusmão and Fábio Gagliardi Cozman and Denis Deratani Mauá},
  title = {{Speeding-up ProbLog's Parameter Learning}},
  year = {2017},
  eprint = {1707.08151},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/1707.08151},
}
Figure