GradPCA: Leveraging NTK Alignment for Reliable Out-of-Distribution Detection

Fuente: arXiv
Saved in:
Bibliographic Details
Main Authors: Seleznova, Mariia, Chou, Hung-Hsu, Verdun, Claudio Mayrink, Kutyniok, Gitta
Format: Preprint
Published: 2025
Subjects:
Online Access:
Tags: Add Tag
No Tags, Be the first to tag this record!
_version_ 1866908857475792896
author Seleznova, Mariia
Chou, Hung-Hsu
Verdun, Claudio Mayrink
Kutyniok, Gitta
author_facet Seleznova, Mariia
Chou, Hung-Hsu
Verdun, Claudio Mayrink
Kutyniok, Gitta
contents We introduce GradPCA, an Out-of-Distribution (OOD) detection method that exploits the low-rank structure of neural network gradients induced by Neural Tangent Kernel (NTK) alignment. GradPCA applies Principal Component Analysis (PCA) to gradient class-means, achieving more consistent performance than existing methods across standard image classification benchmarks. We provide a theoretical perspective on spectral OOD detection in neural networks to support GradPCA, highlighting feature-space properties that enable effective detection and naturally emerge from NTK alignment. Our analysis further reveals that feature quality -- particularly the use of pretrained versus non-pretrained representations -- plays a crucial role in determining which detectors will succeed. Extensive experiments validate the strong performance of GradPCA, and our theoretical framework offers guidance for designing more principled spectral OOD detectors.
format Preprint
id arxiv_https___arxiv_org_abs_2505_16017
institution arXiv
publishDate 2025
record_format arxiv
spellingShingle GradPCA: Leveraging NTK Alignment for Reliable Out-of-Distribution Detection
Seleznova, Mariia
Chou, Hung-Hsu
Verdun, Claudio Mayrink
Kutyniok, Gitta
Machine Learning
Computer Vision and Pattern Recognition
We introduce GradPCA, an Out-of-Distribution (OOD) detection method that exploits the low-rank structure of neural network gradients induced by Neural Tangent Kernel (NTK) alignment. GradPCA applies Principal Component Analysis (PCA) to gradient class-means, achieving more consistent performance than existing methods across standard image classification benchmarks. We provide a theoretical perspective on spectral OOD detection in neural networks to support GradPCA, highlighting feature-space properties that enable effective detection and naturally emerge from NTK alignment. Our analysis further reveals that feature quality -- particularly the use of pretrained versus non-pretrained representations -- plays a crucial role in determining which detectors will succeed. Extensive experiments validate the strong performance of GradPCA, and our theoretical framework offers guidance for designing more principled spectral OOD detectors.
title GradPCA: Leveraging NTK Alignment for Reliable Out-of-Distribution Detection
topic Machine Learning
Computer Vision and Pattern Recognition
url https://arxiv.org/abs/2505.16017