Commit 26283711 authored by Tommy Duc Luu's avatar Tommy Duc Luu
Browse files

updated script for making graphs


Former-commit-id: 74a2844abf0e22bc8b02b3e94feb0012a3aa73df [formerly d71362c3]
Former-commit-id: 6cbf0a68816e80dc7223aada29eb4b82f0af0711
parent 5bcc0fc6
......@@ -7,22 +7,22 @@ import time
from colorama import Fore
plt.style.use('seaborn-whitegrid')
dirs = ['data\\growing_results\\samples',
'data\\growing_results\\non_samples']
dirs = ['data\\growing_results\\non_samples', 'data\\growing_results\\samples']
size = ['9x9', '15x15']
type_ = ['carrot', 'rabbit']
colors = ['r','b','g','m','c']
labels = ['ES', 'Adam']
s = size[0]
t = type_[0]
t = type_[1]
logdir = dirs[0]+os.sep+s+os.sep+t
eventdirs = [d for d in os.listdir(logdir)]
fig = plt.figure()
ax = plt.axes()
ax.set_yscale('log')
ax.set_title(f'{s} {t}')
ax.set_xlabel('Iterations')
ax.set_xlabel('Update steps')
ax.set_ylabel(r'log$_1$$_0$(loss)')
for dir in eventdirs:
path = f"{logdir}/{dir}"
......@@ -37,4 +37,4 @@ for dir in eventdirs:
#plt.show()
plt.legend()
plt.savefig(f'graphs/{s}-{t}_{time.time()}.png')
plt.savefig(f'graphs/{s}-{t}_{time.time()}.png', dpi=400)
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment