Skip to content
Snippets Groups Projects
Commit b0b89d44 authored by Antonio Andriella's avatar Antonio Andriella
Browse files

add function to get statistics from saved variables

parent 1eee9533
No related branches found
No related tags found
No related merge requests found
import numpy as np import numpy as np
import matplotlib.pyplot as plt import matplotlib.pyplot as plt
import pickle
def plot2D_game_performance(save_path, n_episodes, *y): def plot2D_game_performance(save_path, n_episodes, *y):
# The position of the bars on the x-axis # The position of the bars on the x-axis
...@@ -81,4 +81,10 @@ def plot2D_feedback(save_path, n_episodes, *y): ...@@ -81,4 +81,10 @@ def plot2D_feedback(save_path, n_episodes, *y):
plt.xticks(r, x, fontweight='bold') plt.xticks(r, x, fontweight='bold')
plt.ylabel("feedback") plt.ylabel("feedback")
plt.savefig(save_path) plt.savefig(save_path)
plt.show() plt.show()
\ No newline at end of file
def read_user_statistics_from_pickle(file_name):
# Getting back the objects:
with open(file_name, 'rb') as handle:
bn_dict_vars = pickle.load(handle)
return bn_dict_vars
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment