Jingkang50 / OpenOOD

Benchmarking Generalized Out-of-Distribution Detection
MIT License
858 stars 108 forks source link

Nnguide #193

Closed jungyg closed 1 year ago

jungyg commented 1 year ago
  1. We have implemented the ICCV23 paper "Nearest Neighbor Guidance for Out-of-Distribution Detection" (NNGuide) and appended it to the README File methods list.
  2. In order to show the best performance of NNGuide which is dependent to the backbone architecture, we added the files for loading torchvision library's RegNet.
  3. In addition, we added the post-processor and configuration file for NNGuide.
  4. NNGuide depends on random samples of training dataset using them as bank sets, so we changed the shuffle argument in training data loader in "eval_ood_imagenet.py" to True.
  5. By running NNGuide with the default config file(which we committed), results are shown as below. OOD :: nnguide.csv

FSOOD: nnguide.csv

Reference : Park, Jaewoo, Yoon Gyo Jung, and Andrew Beng Jin Teoh. "Nearest Neighbor Guidance for Out-of-Distribution Detection." Proceedings of the IEEE/CVF International Conference on Computer Vision. 2023.

zjysteven commented 1 year ago

Hi @jungyg congrats on your ICCV paper, and thank you for these detailed considerations of integrating NNGuide into OpenOOD, which significantly reduce our burden 👍 We will take a brief overview of your commits and also include the numbers into the leaderboard asap.

zjysteven commented 1 year ago

The NNGuide entry has been added to ImageNet-1K (standard and full-spectrum) leaderboard. Check it here.

jungyg commented 1 year ago

Thank you very much for your quick process!

jS5t3r commented 6 months ago

How to start NNGuide?

Is there a script? https://github.com/Jingkang50/OpenOOD/tree/main/scripts/ood

zjysteven commented 6 months ago

@jS5t3r From the commits of this pull request, it seems the authors of NNGuide only enables the usage via https://github.com/Jingkang50/OpenOOD/blob/main/scripts/eval_ood_imagenet.py, where you can specify the post-processor to be nnguide.

jS5t3r commented 6 months ago

@zjysteven no result folder iscreated, how to fix this?