From 3405ade4f73f78a8dd8c3132547aec6942ef8c52 Mon Sep 17 00:00:00 2001 From: Eduardo Cueto-Mendoza Date: Fri, 4 Oct 2024 12:11:49 +0100 Subject: [PATCH] New alphas for each model --- general_plots_noisy.py | 8 ++++---- get_entropy_noisy.py | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/general_plots_noisy.py b/general_plots_noisy.py index 3cccbd8..f2384c9 100644 --- a/general_plots_noisy.py +++ b/general_plots_noisy.py @@ -1,8 +1,8 @@ import matplotlib.pyplot as plt import functions as aux -model_type = 'LeNet' # BCNN or LeNet -dataset = 'CIFAR' # MNIST or CIFAR +model_type = 'BCNN' # BCNN or LeNet +dataset = 'MNIST' # MNIST or CIFAR eff_df = aux.load_pickle("efficiency_data.pkl") @@ -22,8 +22,8 @@ lenet_keys = ['conv1.weight', 'conv1.bias', 'conv2.weight', 'conv2.bias', all_noises = [0.1, 0.25, 0.5, 0.75, 0.99, 'raleigh', 'erlang', 'exponential', 'uniform', 'impulse'] for size in range(1, 2): - plt.plot(eff_df[dataset][model_type][size], - label='Efficiency') + #plt.plot(eff_df[dataset][model_type][size], + # label='Efficiency') plt.plot(entropy_data[dataset][model_type][size], label='Entropy at noise 0.0') diff --git a/get_entropy_noisy.py b/get_entropy_noisy.py index a4980e3..7ee509e 100644 --- a/get_entropy_noisy.py +++ b/get_entropy_noisy.py @@ -63,7 +63,7 @@ bayes_keys = ['conv1.W_mu', 'conv2.W_mu', 'fc1.W_mu', 'fc2.W_mu', - 'fc3.W_mu',] + 'fc3.W_mu'] lenet_keys = ['conv1.weight', 'conv2.weight',