Sample-Efficient Cardinality Estimation Using Geometric Deep Learning
Silvan Reiner, Michael Grossniklaus
Abstract
In database systems, accurate cardinality estimation is a cornerstone of effective query optimization. In this context, estimators that use machine learning have shown significant promise. Despite their potential, the effectiveness of these learned estimators strongly depends on their ability to learn from small training sets. This paper presents a novel approach for learned cardinality estimation that addresses this issue by enhancing sample efficiency. We propose a neural network architecture informed by geometric deep learning principles that represents queries as join graphs. Furthermore, we introduce an innovative encoding for complex predicates, treating their encoding as a feature selection problem. Additionally, we devise a regularization term that employs equalities of the relational algebra and three-valued logic, augmenting the training process without requiring additional ground truth cardinalities. We rigorously evaluate our model across multiple benchmarks, examining q-errors, runtimes, and the impact of workload distribution shifts. Our results demonstrate that our model significantly improves the end-to-end runtimes of PostgreSQL, even with cardinalities gathered from as little as 100 query executions.
Ask about this paper
Your agent reads all of it.
Lune indexed this paper to the last equation, along with the top-tier papers that cite it. Ask a question and the answer quotes them.
Your agent calls
Luneget_paper_fulltext
Free to start. No credit card required.
Terminal
Install the CLIlune papers fulltext 3f7ef99e-c883-425b-801e-e084139fbf9bCited by top-tier papers12
- How Good are Learned Cost Models, Really? Insights from Query Optimization TasksRoman Heinrich, Manisha Luthra, Johannes Wehrstein, Harald Kornmayer et al.SIGMOD 2025 · 13 citations
- Learned Offline Query Planning via Bayesian OptimizationJeffrey Tao, Natalie Maus, Haydn Thomas Jones, Yimeng Zeng et al.SIGMOD 2025 · 5 citations
- Low Rank Learning for Offline Query OptimizationZixuan Yi, Yao Tian, Zachary G. Ives, Ryan MarcusSIGMOD 2025 · 4 citations
- Distinctiveness Maximization in Datasets AssemblageTingting Wang, Shixun Huang, Zhifeng Bao, J. Shane Culpepper et al.WWW 2025 · 3 citations
- RankPQO: Learning-to-Rank for Parametric Query OptimizationSongsong Mo, Yue Zhao, Zhifeng Bao, Quanqing Xu et al.VLDB 2025 · 3 citations
Builds on20
- Design Space for Graph Neural NetworksJiaxuan You, Zhitao Ying, Jure LeskovecNeurIPS 2020 · 409 citations
- An End-to-End Learning-based Cost EstimatorJi Sun, Guoliang LiVLDB 2020 · 251 citations
- Deep Unsupervised Cardinality EstimationZongheng Yang, Eric Liang, Amog Kamsetty, Chenggang Wu et al.VLDB 2020 · 206 citations
- Cardinality Estimation in DBMS: A Comprehensive Benchmark EvaluationYuxing Han, Ziniu Wu, Peizhi Wu, Rong Zhu et al.VLDB 2022 · 169 citations
- Are We Ready For Learned Cardinality Estimation?Xiaoying Wang, Changbo Qu, Weiyuan Wu, Jiannan Wang et al.VLDB 2021 · 156 citations
Related papers
- Learned Cardinality Estimation: A Design Space Exploration and A Comparative EvaluationJi Sun, Jintao Zhang, Zhaoyan Sun, Guoliang Li et al.VLDB 2022 · 90 citations
- Deep Learning Models for Selectivity Estimation of Multi-Attribute QueriesShohedul Hasan, Saravanan Thirumuruganathan, Jees Augustine, Nick Koudas et al.SIGMOD 2020 · 101 citations
- Speeding Up End-to-end Query Execution via Learning-based Progressive Cardinality EstimationFang Wang, Xiao Yan, Man Lung Yiu, Shuai Li et al.SIGMOD 2023 · 24 citations
- NeuroCard: One Cardinality Estimator for All TablesZongheng Yang, Amog Kamsetty, Sifei Luan, Eric Liang et al.VLDB 2021 · 138 citations
- FACE: A Normalizing Flow based Cardinality EstimatorJiayi Wang, Chengliang Chai, Jiabin Liu, Guoliang LiVLDB 2022
