-
hi, I have a question regarding threshold value for patchcore. What is the boundary for it? I saw it is a floating point value, but do not know what is the minimal and maximal value for the anomaly score. I assume it is between 0 to 255 ? I need to properly set the value for pixel level and image level threshold in model meta_data |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
The threshold is applied to the un-normalized anomaly score predictions generated by the model. As such, the range of possible values differs per model class. In the case of PatchCore, the anomaly scores are computed as the distance in feature space from the sample to its nearest neighbors in the model's memory bank, so their values are theoretically unbounded. To get an idea of what could be a good threshold value, you could initially train a model with adaptive thresholding enabled, and then use the computed adaptive threshold value as a starting point. You could then choose a lower threshold value to increase your model's sensitivity, or a higher threshold value to increase specificity. |
Beta Was this translation helpful? Give feedback.
The threshold is applied to the un-normalized anomaly score predictions generated by the model. As such, the range of possible values differs per model class. In the case of PatchCore, the anomaly scores are computed as the distance in feature space from the sample to its nearest neighbors in the model's memory bank, so their values are theoretically unbounded. To get an idea of what could be a good threshold value, you could initially train a model with adaptive thresholding enabled, and then use the computed adaptive threshold value as a starting point. You could then choose a lower threshold value to increase your model's sensitivity, or a higher threshold value to increase specificity.