Out-of-Distribution Detection with Logical Reasoning

Abstract

Machine Learning models often only generalize reliably to samples from the training distribution. Consequentially, detecting when input data is out-of-distribution (OOD) is crucial, especially in safety-critical applications. Current OOD detection methods, however, tend to be domain agnostic and often fail to incorporate valuable prior knowledge about the structure of the training distribution. To address this limitation, we introduce a novel, hybrid OOD detection algorithm that combines a deep learning-based perception system with a first-order logic-based knowledge representation. A logical reasoning system uses this knowledge base at run-time to infer whether inputs are consistent with prior knowledge about the training distribution. In contrast to purely neural systems, the structured knowledge representation allows humans to inspect and modify the rules that govern the OOD detectors' behavior. This not only enhances performance but also fosters a level of explainability that is particularly beneficial in safety-critical contexts. We demonstrate the effectiveness of our method through experiments on several datasets and discuss advantages and limitations. Our code is available online.

Cite

Text

Kirchheim et al. "Out-of-Distribution Detection with Logical Reasoning." Winter Conference on Applications of Computer Vision, 2024.

Markdown

[Kirchheim et al. "Out-of-Distribution Detection with Logical Reasoning." Winter Conference on Applications of Computer Vision, 2024.](https://mlanthology.org/wacv/2024/kirchheim2024wacv-outofdistribution/)

BibTeX

@inproceedings{kirchheim2024wacv-outofdistribution,
  title     = {{Out-of-Distribution Detection with Logical Reasoning}},
  author    = {Kirchheim, Konstantin and Gonschorek, Tim and Ortmeier, Frank},
  booktitle = {Winter Conference on Applications of Computer Vision},
  year      = {2024},
  pages     = {2122-2131},
  url       = {https://mlanthology.org/wacv/2024/kirchheim2024wacv-outofdistribution/}
}