Parameter Learning of Bayesian Network Classifiers Under Computational Constraints

Sebastian Tschiatschek, Franz Pernkopf

Abstract

Bayesian Network Classifiers (BNCs) are powerful tools for probabilistic reasoning, but their deployment on resource-constrained edge devices is often limited by the lack of floating-point units. While inference in reduced precision is well-studied, online learning remains challenging due to quantization noise in standard optimization projections. This paper presents a novel approach to BNC parameter learning using integer-counting mechanisms and lookup tables, bypassing the need for high-precision arithmetic. We demonstrate that these "no-projection" algorithms maintain high classification accuracy across diverse datasets while being significantly more hardware-efficient.

Introduction

The proliferation of "edge" computing—ranging from hearing aids to satellites—demands machine learning models that can operate within strict power and silicon area budgets. While many models are trained on high-performance clusters using double-precision floating-point arithmetic, deploying them on hardware without floating-point units (FPUs) necessitates reduced-precision implementations. This paper addresses the specific challenge of not just running, but learning Bayesian Network Classifiers (BNCs) entirely within a reduced-precision, fixed-point regime.

The Challenge of Low-Precision Learning

Most online learning techniques for BNCs involve gradient-based optimization. A critical step in these algorithms is the "projection" onto a probability simplex to ensure that the learned parameters represent valid probabilities (i.e., they sum to one). In low-precision environments, the noise introduced by rounding during this projection step is often large enough to prevent the model from converging or learning useful patterns.

Taxonomy of training and testing precision scenarios. This research focuses on the 'reduced-precision' training and testing quadrant, enabling on-device adaptation.

Proposed Methodology: A "No-Projection" Approach

To overcome the limitations of gradient projections, we propose a shift to count-based learning. This approach is inherently compatible with fixed-point integers.

Integer-Based Generative Learning

For Maximum Likelihood (ML) learning, the algorithm maintains integer counts ($m$) of event occurrences. To prevent overflow in finite bit-width registers, we implement a counter-halving mechanism. When any counter reaches a predefined maximum value ($M$), all counters in the associated table are right-shifted (divided by two). This preserves the relative proportions of the counts while freeing up dynamic range, effectively acting as a "forgetting factor" for older data.

Discriminative Learning with Perceptrons

For Maximum Margin (MM) learning, we employ a perceptron-like update rule. When a sample is misclassified or falls below a certain confidence margin, the algorithm increments the counts for the correct class features and decrements them for the strongest competing class. This "pushes" the decision boundary without requiring complex continuous optimization.

Inference via Lookup Tables

To maintain speed and precision during inference, integer counts are converted to log-probabilities using pre-computed lookup tables. This ensures that the entire pipeline—from learning to classification—remains within the fixed-point domain.

Experimental Evaluation

We evaluated our reduced-precision algorithms (using 10-bit counters) against standard double-precision versions. The benchmarks included over 20 datasets from the UCI repository, as well as the USPS and MNIST handwritten digit datasets. We tested two common BNC structures: Naive Bayes (NB) and Tree Augmented Networks (TAN).

Results and Discussion

The experiments demonstrated that the proposed reduced-precision algorithms suffer minimal accuracy loss. For instance, on the USPS dataset using a TAN structure, the reduced-precision model achieved an accuracy of 90.05%, compared to 91.39% for the double-precision version.

Key findings include:

  • Robustness to Quantization: The primary bottleneck in low-precision learning is the projection step, not the weight resolution itself. By avoiding projections, our method remains robust.
  • Efficiency: The reliance on additions, bit-shifts, and lookup tables makes these algorithms highly suitable for hardware implementation, avoiding costly divisions or transcendental functions.
  • Viability of Discriminative Learning: The MM approach consistently outperformed ML, showing that discriminative training is feasible even under extreme constraints.

Conclusion

This work provides a framework for enabling online adaptation of BNCs on resource-constrained hardware. By replacing floating-point optimization with integer counting and lookup tables, we bridge the gap between high-level probabilistic modeling and low-level hardware constraints. Future work will explore learning the network structure itself under similar constraints and optimizing hyper-parameter tuning for embedded environments.

Summary updated

BibTeX
@inproceedings{tschiatschek2015parameter,
  author = {Sebastian Tschiatschek and Franz Pernkopf},
  title = {{Parameter Learning of Bayesian Network Classifiers Under Computational Constraints}},
  booktitle = {ECML/PKDD},
  year = {2015},
  doi = {10.1007/978-3-319-23528-8\_6},
}
Figure