7a8be4139a3d1f3968081728375c4621285ec3fe,unrestricted_advex/eval_kit/eval_with_attacks.py,,plot_confident_error_rate,#,145
Before Change
fig = plt.figure()
ax = fig.add_subplot(111)
plt.plot(coverages, [float(len(idxs)) / num_examples
for idxs in cov_to_confident_error_idxs])
plt.title(title.format(attack_name=attack_name))
plt.ylabel("Risk \n (error rate on covered data)")
plt.xlabel("Coverage \n (fraction of points not abstained on)")
After Change
ax = fig.add_subplot(111)
cov_to_num_covered_examples = [
num_examples * coverage for coverage in coverages
]
risk_on_covered_data = [
float(len(error_idxs)) / num_covered_examples
for error_idxs, num_covered_examples in
zip(cov_to_confident_error_idxs, cov_to_num_covered_examples)]
plt.plot(coverages, risk_on_covered_data)
plt.title(title.format(attack_name=attack_name))
plt.ylabel("Risk \n (error rate on covered data)")
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 5
Instances
Project Name: google/unrestricted-adversarial-examples
Commit Name: 7a8be4139a3d1f3968081728375c4621285ec3fe
Time: 2018-08-25
Author: nottombrown@gmail.com
File Name: unrestricted_advex/eval_kit/eval_with_attacks.py
Class Name:
Method Name: plot_confident_error_rate
Project Name: scikit-optimize/scikit-optimize
Commit Name: b8f10b387de929bcb250e4750064355e50b44317
Time: 2016-04-18
Author: manojkumarsivaraj334@gmail.com
File Name: examples/plot_gp_minimize_1d.py
Class Name:
Method Name:
Project Name: richzhang/colorization-pytorch
Commit Name: 1215d2390c0ef900337366e7a89e8d21e4bfd592
Time: 2018-08-25
Author: rzhang88@gmail.com
File Name: test_sweep.py
Class Name:
Method Name: