Kernel-Based Tests for Likelihood-Free Hypothesis Testing

Patrik Robert Gerber, Tianze Jiang, Yury Polyanskiy, Rui Sun

Abstract

In many scientific domains, the complexity of physical processes precludes the derivation of analytical likelihood functions, necessitating Likelihood-Free Inference (LFI). This paper addresses the challenge of Likelihood-Free Hypothesis Testing (LFHT), specifically focusing on the "Mixed" scenario (mLFHT) where experimental data is a mixture of background and signal distributions. We propose a kernel-based testing framework utilizing Maximum Mean Discrepancy (MMD) and deep kernel learning. Our theoretical and empirical results demonstrate a fundamental asymmetric trade-off between simulation data ($n$) and experimental data ($m$), showing that increased experimental sampling significantly reduces the computational burden of simulations. The proposed method achieves state-of-the-art performance on high-energy physics and computer vision benchmarks, reaching the $5\sigma$ discovery threshold in Higgs boson detection tasks.

Introduction

Scientific discovery often relies on comparing experimental observations against theoretical models. In fields like particle physics, epidemiology, and cosmology, these models are typically implemented as "black-box" simulators. While these simulators can generate synthetic data based on physical laws, they do not provide an explicit likelihood function $p(x|\theta)$, making traditional likelihood-ratio tests impossible.

This paper formalizes the problem of Likelihood-Free Hypothesis Testing (LFHT). In the standard setup, we have a simulator for a background process ($P_X$) and a simulator for a potential discovery ($P_Y$). Given a set of experimental observations ($Z$), the goal is to determine if $Z$ is drawn solely from the background or contains a signal component. The authors specifically investigate Mixed LFHT (mLFHT), where the alternative hypothesis posits that experimental data is a mixture of background and signal—a scenario that more accurately reflects real-world experimental conditions.

Methodology

Maximum Mean Discrepancy (MMD) and Variance Cancellation

The core of the proposed framework is a test statistic based on Maximum Mean Discrepancy (MMD). MMD measures the distance between two distributions by comparing their embeddings in a Reproducing Kernel Hilbert Space (RKHS). To address the high variance inherent in small experimental sample sizes ($m$), the authors introduced a "variance cancellation" technique. By carefully designing the test statistic, they ensure that the variance associated with the experimental data is minimized, allowing the test to remain powerful even when real-world data is scarce.

Deep Kernel Learning

Traditional MMD tests often rely on fixed kernels, such as the Gaussian kernel, which may fail to capture complex features in high-dimensional data. To overcome this, the authors utilize Deep Kernel Learning. They parameterize the kernel using a neural network, which is trained on simulation data to maximize the ratio of the MMD signal to its variance. This process effectively "learns" the optimal features required to distinguish between the null and alternative hypotheses, transforming the raw data into a space where the distributions are most separable.

Minimax Analysis

A significant contribution of this work is the rigorous mathematical analysis of sample complexity. The authors provide both upper and lower bounds for the number of samples required to achieve a specific testing power. This minimax analysis reveals a near-optimal relationship between the number of simulations ($n$) and experimental observations ($m$).

Experimental Results

The framework was evaluated across three distinct domains to verify the theoretical predictions and practical utility.

  1. Toy Discrete Distributions: These experiments confirmed the predicted "asymmetric trade-off," demonstrating that the required number of simulations $n$ scales inversely with the number of experimental samples $m$.
  2. Higgs Boson Detection: Using a classic high-energy physics benchmark, the method was tasked with detecting the Higgs boson signal within a massive background. The MMD-based test reached the $5\sigma$ significance level—the gold standard for discovery in physics—using approximately 2.6 million simulated datapoints. This result demonstrates the method's applicability to large-scale scientific experiments.
  3. CIFAR-10 vs. DDPM: In a computer vision context, the test successfully identified images generated by a Denoising Diffusion Probabilistic Model (DDPM) embedded within real CIFAR-10 data. This highlights the framework's robustness in handling high-dimensional, structured data.

Key Insights

The $m$ vs. $n$ Asymmetry

The most critical insight is the relationship between $m$ and $n$. The research proves that $m$ and $n$ are not interchangeable; rather, they exhibit an asymmetric trade-off. Specifically, increasing the experimental sample size $m$ allows for a significant reduction in the number of expensive simulations $n$ required to maintain testing power. This is particularly valuable in fields where simulations are computationally prohibitive.

Bridging Classification and Two-Sample Testing

The framework provides a unified view of hypothesis testing. When $m=1$, the problem reduces to standard binary classification. As $m$ increases, the problem evolves into a two-sample testing scenario. The proposed MMD-M test gracefully handles this entire spectrum, outperforming standard benchmarks like Scheffé’s test and logit-based classifiers, particularly in low-data regimes.

Conclusion and Future Work

This paper establishes a robust, near-optimal framework for Likelihood-Free Hypothesis Testing. By leveraging deep kernel learning and addressing the variance challenges of mixed distributions, the authors provide a tool that is both theoretically grounded and practically effective for scientific discovery.

Future research directions include extending the minimax theory to account for data-dependent (learned) kernels, improving the computational efficiency of p-value calibration, and scaling the approach to even more complex data types, such as high-resolution video or natural language. The alignment between the mathematical theory of sample complexity and the empirical performance on neural network tasks marks a significant step forward in the reliability of likelihood-free methods.

Summary updated

BibTeX
@inproceedings{gerber2023kernel,
  author = {Patrik Robert Gerber and Tianze Jiang and Yury Polyanskiy and Rui Sun},
  title = {{Kernel-Based Tests for Likelihood-Free Hypothesis Testing}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2023},
  url = {https://openreview.net/forum?id=paTESG8iSE},
}
Figure