Improving Random Forests by Smoothing
Ziyi Liu, Phuc Luong, Mario Boley, Daniel F. Schmidt
TL;DR
This work presents a post-learning kernel smoothing framework for piecewise-constant predictors to fuse the local adaptivity of trees with smooth uncertainty modeling. By convolving a learned predictor with a kernel and calibrating its output, the method yields differentiable predictions with an explicit uncertainty term that accounts for leaf-boundary variability; extended to random forests, the approach provides smoothed per-tree predictions averaged across the ensemble and a composite uncertainty estimate combining intra- and inter-model variance with noise. Parameter selection via out-of-bag risk enables data-driven tuning of the smoothing bandwidth and calibration. Empirical results on 14 UCI datasets show that the smoothed random forest (SRF), particularly with local smoothing, improves mean-squared error and often log-loss compared with standard RF and GP baselines, while maintaining computational efficiency. Overall, the method offers a practical and scalable approach to robust small-data regression with principled uncertainty quantification.
Abstract
Gaussian process regression is a popular model in the small data regime due to its sound uncertainty quantification and the exploitation of the smoothness of the regression function that is encountered in a wide range of practical problems. However, Gaussian processes perform sub-optimally when the degree of smoothness is non-homogeneous across the input domain. Random forest regression partially addresses this issue by providing local basis functions of variable support set sizes that are chosen in a data-driven way. However, they do so at the expense of forgoing any degree of smoothness, which often results in poor performance in the small data regime. Here, we aim to combine the advantages of both models by applying a kernel-based smoothing mechanism to a learned random forest or any other piecewise constant prediction function. As we demonstrate empirically, the resulting model consistently improves the predictive performance of the underlying random forests and, in almost all test cases, also improves the log loss of the usual uncertainty quantification based on inter-tree variance. The latter advantage can be attributed to the ability of the smoothing model to take into account the uncertainty over the exact tree-splitting locations.
