andrewlai61616 / NPSR

Nominality Score Conditioned Time Series Anomaly Detection by Point/Sequential Reconstruction (NeurIPS 2023) https://arxiv.org/abs/2310.15416
https://neurips.cc/virtual/2023/poster/70582
31 stars 7 forks source link

关于阈值选取 #3

Open sunshineh1314 opened 1 week ago

sunshineh1314 commented 1 week ago

在异常检测中,大部分方法是通过SPOT方法;在NPSR中如何进行阈值的选取

ZYRJZ03 commented 1 week ago

它的best-F1方法计算了测试的所有异常分数作为阈值下的F1,并取其中的最大值。

sunshineh1314 commented 1 week ago

您在config.txt文件中对每个数据集给定了固定的参数

# dataset                 SWaT
# downsample              10
# dl                      100             # window size for M_pt (= W)
# stride                  10              # stride for M_pt
# model                   NPSR            # should match one model in [default model config] above
# pred_dl                 100             # window size for M_seq (= W_0)
# delta                   20              # M_seq output window size
# heads                   9
# theta_N_ratio           0.9985          # cf. sec 3.4

theta_N_ratio这一参数是按百分比决定了异常分数的阈值分数吗

ZYRJZ03 commented 1 week ago

我不是作者,也是来学习的>_< 我看代码里theta_N_ratio这个参数是用来调整异常分数的,没有用来计算阈值。你可以看一下train.py和evaluation.py