Hyp-OC: Hyperbolic One Class Classification for Face Anti-Spoofing

Kartik Narayan, Vishal M. Patel
4/22/2024
cs.CV

No official code found. Best implementation: Kartik-3004/hyp-oc (23 stars, MIT, last commit 2025-07-20).

Abstract

Face recognition technology has become an integral part of modern security systems and user authentication processes. However, these systems are vulnerable to spoofing attacks and can easily be circumvented. Most prior research in face anti-spoofing (FAS) approaches it as a two-class classification task where models are trained on real samples and known spoof attacks and tested for detection performance on unknown spoof attacks. However, in practice, FAS should be treated as a one-class classification task where, while training, one cannot assume any knowledge regarding the spoof samples a priori. In this paper, we reformulate the face anti-spoofing task from a one-class perspective and propose a novel hyperbolic one-class classification framework. To train our network, we use a pseudo-negative class sampled from the Gaussian distribution with a weighted running mean and propose two novel loss functions: (1) Hyp-PC: Hyperbolic Pairwise Confusion loss, and (2) Hyp-CE: Hyperbolic Cross Entropy loss, which operate in the hyperbolic space. Additionally, we employ Euclidean feature clipping and gradient clipping to stabilize the training in the hyperbolic space. To the best of our knowledge, this is the first work extending hyperbolic embeddings for face anti-spoofing in a one-class manner. With extensive experiments on five benchmark datasets: Rose-Youtu, MSU-MFSD, CASIA-MFSD, Idiap Replay-Attack, and OULU-NPU, we demonstrate that our method significantly outperforms the state-of-the-art, achieving better spoof detection performance.

View on arXivView PDF

Code Implementations(1)

Kartik-3004/hyp-ocCommunity73%
MIT

[FG 2024] Official implementation of Hyp-OC: Hyperbolic One Class Classification for Face Anti-Spoofing

236Shell, MATLABApr 17, 20241 years agoMIT

Similar Papers

Cite this paper

@article{narayan2024hypoc,
  title  = {Hyp-OC: Hyperbolic One Class Classification for Face Anti-Spoofing},
  author = {Kartik Narayan and Vishal M. Patel},
  year   = {2024},
  eprint = {2404.14406},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2404.14406v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2404.14406.svg)](https://codeofpaper.com/paper/2404.14406)

Discussion