Benchmarking code + variable Bayes threshold.