When Do Neural Nets Outperform Boosted Trees on Tabular Data?

Duncan McElfresh, Sujay Khandagale, Jonathan Valverde, Vishak Prasad C, Benjamin Feuer, Chinmay Hegde, Ganesh Ramakrishnan, Micah Goldblum, Colin White

TL;DR

This paper presents the largest tabular data analysis to date, comparing 19 algorithms across 176 datasets to investigate the long-standing rivalry between Neural Networks (NNs) and Gradient-Boosted Decision Trees (GBDTs). The authors conclude that the "NN vs. GBDT" debate is often overblown; for many datasets, light hyperparameter tuning on a single strong model is more impactful than choosing between these two families.

What Problem Does This Paper Address?

In fields like computer vision and natural language processing, neural networks are the undisputed champions. However, for tabular data—the rows-and-columns format ubiquitous in finance, medicine, and advertising—the winner is less clear. Researchers have spent years debating whether modern NNs have finally surpassed traditional GBDTs like XGBoost or CatBoost.

The authors identify a major flaw in this debate: most prior studies used fewer than 50 datasets or failed to properly tune their baseline models, leading to conflicting results. This paper seeks to provide a definitive, large-scale answer by asking not just which is better, but when and why one might outperform the other.

Methods

The researchers conducted a massive experimental campaign, training over 500,000 models. Their methodology included:

  • Algorithm Breadth: They compared 19 algorithms, including 3 GBDTs (CatBoost, XGBoost, LightGBM), 11 NNs (such as FT-Transformer, SAINT, and TabNet), and 5 classic baselines (like Random Forest and SVM).
  • Rigorous Tuning: Each algorithm was subjected to 30 iterations of hyperparameter optimization (HPO) using Optuna to ensure a fair comparison.
  • Metafeature Analysis: To understand why certain models win, they extracted 965 "metafeatures" (statistical properties of the datasets) using the PyMFE library.
  • TabPFN Evaluation: They paid special attention to TabPFN, a recently proposed "Prior-Data Fitted Network" that approximates Bayesian inference in a single forward pass.
Figure 1: Overview of our work. We start by conducting the largest study on tabular data to date (left); we analyze the importance of algorithm selection (‘NNs vs. GBDTs’) as well as metafeatures (middle); and based on our study, we release TabZilla, a collection of the hardest tabular datasets.

Datasets

The study utilized 176 classification datasets sourced from OpenML, including the well-known CC18 and OpenML Benchmarking suites. Dataset sizes ranged from tiny (32 samples) to large (over 1 million samples).

A key contribution is the introduction of the TabZilla Benchmark Suite, a curated collection of the 36 "hardest" datasets from their study. These were selected because simple baselines fail to perform well on them, and there is a significant performance gap between the top-tier algorithms.

Key Insights and Ideas

  • The Debate is Overemphasized: For a high number of datasets, the performance difference between a well-tuned NN and a well-tuned GBDT is negligible. In fact, for about one-third of datasets, light tuning on a model like CatBoost provides a bigger boost than switching to a completely different algorithm family.
  • TabPFN is a "Small Data" Powerhouse: TabPFN emerged as the top-performing algorithm on average. While it is technically limited to 3,000 training samples due to memory scaling, the authors found that even on large datasets, randomly sampling 3,000 points for TabPFN often outperformed other models trained on the full dataset.
  • Irregularity Favors Trees: GBDTs are significantly better at handling "irregular" data—datasets with skewed feature distributions, heavy tails, or high variance. NNs, conversely, perform best when the data is "regular" and smooth.
  • Size Matters: GBDTs tend to scale their relative performance better as the number of training instances increases, whereas NNs (excluding specialized ones like TabPFN) often struggle to maintain an edge on larger tabular datasets.

Key Results

  • Top Performers: CatBoost and TabPFN were the overall winners across the 176 datasets.
  • Statistical Significance: As shown in the critical difference plot below, TabPFN achieved a statistically significant lead in terms of mean log loss rank.
Figure 3: Critical difference plot comparing all algorithms according to their mean log loss rank over 98 datasets. Each algorithm’s average rank is shown as a horizontal line on the axis. Sets of algorithms which are not significantly different are connected by a horizontal black bar. Algorithm family is indicated by a marker next to the algorithm name: red “X” indicates a neural net, blue circle indicates a baseline algorithm, green triangles indicate GBDTs, and purple squares indicate a PFN.
  • Efficiency: TabPFN is remarkably fast, often performing training and inference in under a second for small datasets, making it two orders of magnitude faster than CatBoost in those scenarios.
  • Predictive Metafeatures: The authors successfully trained a meta-model that uses dataset properties (like the number of instances or feature skewness) to predict whether an NN or a GBDT will perform better, reaching an accuracy of up to 74%.

Limitations and Future Work

The primary limitation of the most successful NN, TabPFN, is its quadratic scaling with respect to the number of training samples, effectively capping its native use at around 3,000 points. While the authors' subsampling strategy (TabPFN*) works well, it doesn't fully leverage massive datasets.

The authors suggest several avenues for future research:

  • Extending the analysis to regression and time-series datasets.
  • Investigating the specific impact of categorical features on NN performance.
  • Developing more robust NNs that can handle the "irregularity" that currently gives GBDTs an advantage.

Summary updated

Abstract

Tabular data is one of the most commonly used types of data in machine learning. Despite recent advances in neural nets (NNs) for tabular data, there is still an active discussion on whether or not NNs generally outperform gradient-boosted decision trees (GBDTs) on tabular data, with several recent works arguing either that GBDTs consistently outperform NNs on tabular data, or vice versa. In this work, we take a step back and question the importance of this debate. To this end, we conduct the largest tabular data analysis to date, comparing 19 algorithms across 176 datasets, and we find that the 'NN vs. GBDT' debate is overemphasized: for a surprisingly high number of datasets, either the performance difference between GBDTs and NNs is negligible, or light hyperparameter tuning on a GBDT is more important than choosing between NNs and GBDTs. A remarkable exception is the recently-proposed prior-data fitted network, TabPFN: although it is effectively limited to training sets of size 3000, we find that it outperforms all other algorithms on average, even when randomly sampling 3000 training datapoints. Next, we analyze dozens of metafeatures to determine what properties of a dataset make NNs or GBDTs better-suited to perform well. For example, we find that GBDTs are much better than NNs at handling skewed or heavy-tailed feature distributions and other forms of dataset irregularities. Our insights act as a guide for practitioners to determine which techniques may work best on their dataset. Finally, with the goal of accelerating tabular data research, we release the TabZilla Benchmark Suite: a collection of the 36 'hardest' of the datasets we study. Our benchmark suite, codebase, and all raw results are available at https://github.com/naszilla/tabzilla.
BibTeX
@inproceedings{mcelfresh2023when,
  author = {Duncan McElfresh and Sujay Khandagale and Jonathan Valverde and Vishak Prasad C and Benjamin Feuer and Chinmay Hegde and Ganesh Ramakrishnan and Micah Goldblum and Colin White},
  title = {{When Do Neural Nets Outperform Boosted Trees on Tabular Data?}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2023},
  url = {https://openreview.net/forum?id=g62mtufBVA},
}
Figure