Abstract
Structured prediction models, such as Conditional Random Fields (CRFs), are essential for modeling complex dependencies in natural language processing and computer vision. However, training these models typically requires global inference to compute normalization constants, which becomes computationally intractable for complex or loopy graphs. We present Piecewise Training (PW), a method that decomposes a complex factor graph into independent components for training, thereby bypassing the global bottleneck. Empirical results on several NLP benchmarks demonstrate that PW is significantly faster than standard Maximum Likelihood Estimation (MLE) and often more accurate than traditional local methods like Pseudolikelihood (PL).
Introduction
The "Gold Standard" for training structured models is Maximum Likelihood Estimation (MLE). However, MLE requires calculating the partition function—a sum over all possible global configurations—at every step of the optimization process. For simple linear chains, the Forward-Backward algorithm makes this efficient. However, for "loopy" graphs, such as those used in image labeling or skip-chain CRFs for information extraction, exact inference is intractable.
Researchers often turn to Besag’s Pseudolikelihood (PL), which conditions each variable on its Markov blanket (its neighbors). While computationally efficient, PL often ignores the strong sequential interactions that make structured prediction useful, leading to poor performance on real-world tasks where local dependencies are paramount.
Methods: The Piecewise Approach
The core contribution of this work is the introduction of two primary techniques: Piecewise Training (PW) and Piecewise Pseudolikelihood (PWPL).
Piecewise Training (PW)
The fundamental idea behind PW is "node-splitting." The original factor graph is transformed by creating a copy of each variable for every factor it participates in. This transformation breaks a complex, connected graph into a collection of isolated "pieces," typically individual factors.
Each piece is then trained independently to maximize its local likelihood. At test time, the learned weights are plugged back into the original global model for inference. This approach ensures that the model captures local factor interactions without the need for global normalization during the training phase.
Piecewise Pseudolikelihood (PWPL)
Even local pieces can be computationally expensive if the number of possible labels (cardinality) is large, as the complexity of PW is quadratic in the number of labels. PWPL is a hybrid method that applies node-splitting and then uses a pseudolikelihood objective within each piece. This modification makes the training time linear in the number of labels, allowing the method to scale to tasks with large tag sets.
Experimental Results
The authors evaluated their methods on four classic NLP benchmarks: Named-Entity Recognition (NER), Part-of-Speech (POS) Tagging, Noun-Phrase Chunking, and Information Extraction from seminar announcements.
Performance and Efficiency
On the CoNLL 2003 NER task, Piecewise training achieved an F1 score of 91.2, actually outperforming exact MLE (90.6) and significantly surpassing standard Pseudolikelihood (84.7).
The speed advantages were even more pronounced. For POS tagging, PWPL was 8.6x faster than MLE. For noun-phrase chunking, it achieved a 32x speedup. In complex "skip-chain" models where exact training is impossible, Piecewise training performed comparably to approximate training using loopy Belief Propagation, while being much easier to implement and more stable to optimize.
Key Insights
Data Efficiency and Convergence
A significant finding is that while MLE or PL might be asymptotically superior given infinite data, PWPL often converges to its limit much faster. On smaller datasets, PWPL is frequently the superior choice because it avoids the high variance associated with global normalization on limited samples.
Implicit Regularization
By training pieces independently, the model is discouraged from relying on long-distance "coincidences" in the training data. This acts as a form of implicit regularization that improves generalization. Furthermore, the "node-splitting" approach overcounts variables that appear in multiple factors; while this introduces a bias, the authors demonstrate that this bias is often harmless or even beneficial for discriminative tasks.
Conclusion
Piecewise training provides a simple yet effective framework for training structured models without the computational headache of global inference. By decomposing complex graphs into manageable pieces, it enables the use of sophisticated models on large-scale datasets where traditional MLE would be impractical. Future work may extend this approach to models with latent variables or explore the use of larger tractable subgraphs, such as trees, as the fundamental "pieces" for training.
Summary updated