arXiv ScienceSearch

arXiv subjects

Sebastian Neumayer

Publications and source records attributed to Sebastian Neumayer.

2 recordsLinked to original sources

Fast Gauss Sums via Flash Attention

Gaussian kernel sums are the computational core of maximum mean discrepancies (MMDs), kernel gradient flows, Stein variational gradient descent (SVGD), and many other kernel methods. At the same time, softmax attention has received an extraordinary amount of hardware-aware code engineering, culminating in flash attention. We show that Gauss kernel sums with arbitrary, signed weights can be evaluated via flash attention: two small input augmentations turn the normalized softmax reduction into the unnormalized Gauss sum, without writing a single line of custom GPU code. For feature dimension D>8 in fp16, this approach beats compiled PyTorch code as well as PyKeOps kernels (often significantly) in speed, memory-overhead and accuracy. Indeed, its memory scaling remains linear.

cs.LG

Greedy sampling designs via reduced basis methods: optimal recovery in the uniform norm

We study optimal sampling recovery in reproducing kernel Hilbert spaces (RKHS) in the uniform norm. For every RKHS with bounded kernel, we establish new comparisons between linear sampling widths and Gelfand widths that overcome the known square-root gap, without requiring a measure or a Christoffel-type condition. Our bounds rely on nested sampling designs obtained by kernel interpolation at (weak) P-greedy points. Under additional (polynomial) decay assumptions the decay rate of the Gelfand widths directly transfers to the sampling widths. With either a logarithmic oversampling or passing to the square root of the Gelfand widths we obtain a direct comparison (requiring no decay assumption) between them. This is particularly effective for super-polynomial decay, such as in Paley-Wiener spaces. Our results follow from representations of both widths in terms of kernel translates and yield, in the opposite direction, a new existence result for a sharp reduced basis selection. Numerical experiments for Legendre, mixed-Sobolev, and Paley-Wiener kernels illustrate our findings.

math.NA