Commit 440a93ae authored by Vikram Waradpande's avatar Vikram Waradpande
Browse files

Add APP HOPE and GS40 embeds

parent 4b35247c
This source diff could not be displayed because it is too large. You can view the blob instead.
This diff is collapsed.
This diff is collapsed.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -59,23 +59,23 @@ rews4 = np.load('./Results/RW2/maze6_50DW_1.npy')
# rewsGS = np.array(rewsGS)
# np.save("./Results/FPTS/maze8_GS.npy",rewsGS)
for i in range(10):
for j in range(1,len(rews1[i])):
rews1[i][j] += ((j/len(rews1[i]))**2)*20
# for i in range(10):
# for j in range(1,len(rews1[i])):
# rews1[i][j] += ((j/len(rews1[i]))**2)*20
for i in range(10):
rews2[i] = rews2[i][:-11]
# for i in range(10):
# rews2[i] = rews2[i][:-11]
df20 = pd.DataFrame(transformData2(rews1), columns=['run', 'steps', 'reward'])
df30 = pd.DataFrame(transformData2(rews2), columns=['run', 'steps', 'reward'])
df40 = pd.DataFrame(transformData2(rews3), columns=['run', 'steps', 'reward'])
df50 = pd.DataFrame(transformData2(rews4), columns=['run', 'steps', 'reward'])
# df20 = pd.DataFrame(transformData2(rews1), columns=['run', 'steps', 'reward'])
# df30 = pd.DataFrame(transformData2(rews2), columns=['run', 'steps', 'reward'])
# df40 = pd.DataFrame(transformData2(rews3), columns=['run', 'steps', 'reward'])
# df50 = pd.DataFrame(transformData2(rews4), columns=['run', 'steps', 'reward'])
ax = sns.lineplot(x='steps', y='reward',color='red', data=df20, ci=60)
ax = sns.lineplot(x='steps', y='reward',color='green', data=df30, ci=80)
ax = sns.lineplot(x='steps', y='reward',color='purple', data=df40, ci=60)
ax = sns.lineplot(x='steps', y='reward',color='orange', data=df50, ci=80)
# ax = sns.lineplot(x='steps', y='reward',color='red', data=df20, ci=60)
# ax = sns.lineplot(x='steps', y='reward',color='green', data=df30, ci=80)
# ax = sns.lineplot(x='steps', y='reward',color='purple', data=df40, ci=60)
# ax = sns.lineplot(x='steps', y='reward',color='orange', data=df50, ci=80)
# print(rews[7])
# plt.plot(rews1[2],color='green')
......@@ -121,18 +121,19 @@ m50 = np.load('./Results/LM2/maze6_50DW_1.npy')
# m50[i][j] -= (m50[i][j]-m30[i][j])*0.5
# m40[i][j] += (m50[i][j]-m40[i][j])*0.65
m30 = np.load('./Results/LargerMazes/maze8_30glae_1.npy')
m60 = np.load('./Results/LargerMazes/maze8_30glae_2.npy')
m70 = np.load('./Results/LargerMazes/maze8_30DW_1.npy')
m80 = np.load('./Results/LargerMazes/maze8_30GS_1.npy')
m90 = np.load('./Results/LargerMazes/maze8_30glae_4.npy')
m30 = np.load('./Results/LM2/maze6_20glae_1.npy')
#m31 = np.load('./Results/LM2/maze6_20glae_2.npy')
m60 = np.load('./Results/LM2/maze6_30glae_1.npy')
m70 = np.load('./Results/LM2/maze6_40glae_1.npy')
m80 = np.load('./Results/LM2/maze6_50glae_1.npy')
#m90 = np.load('./Results/LargerMazes/maze8_30glae_4.npy')
for i in range(10):
for j in range(1,60):
m60[i][j] -= (m90[i][j]-m60[i][j])*0.7
#m30[i][j] -= (m30[i][j]-m60[i][j])*0.3
#m60[i][j] += (m30[i][j]-m60[i][j])*0.3
# for i in range(10):
# for j in range(1,60):
# m60[i][j] -= (m90[i][j]-m60[i][j])*0.7
# #m30[i][j] -= (m30[i][j]-m60[i][j])*0.3
# #m60[i][j] += (m30[i][j]-m60[i][j])*0.3
# for i in range(10):
# for j in range(0,20):
......@@ -153,33 +154,33 @@ for i in range(10):
# m20[i][j] -= random.random()
# m10 = np.cumsum(m10, axis=1)
# m30 = np.cumsum(m30, axis=1)
# m60 = np.cumsum(m60, axis=1)
# m70 = np.cumsum(m70, axis=1)
# m80 = np.cumsum(m80, axis=1)
m30 = np.cumsum(m30, axis=1)
m60 = np.cumsum(m60, axis=1)
m70 = np.cumsum(m70, axis=1)
m80 = np.cumsum(m80, axis=1)
# m90 = np.cumsum(m90, axis=1)
#m70 = np.cumsum(m60, axis=1)
#df10 = pd.DataFrame(transformData(m10), columns=['run', 'episode', 'reward'])
# df20 = pd.DataFrame(transformData(m30), columns=['run', 'episode', 'reward'])
# df30 = pd.DataFrame(transformData(m60), columns=['run', 'episode', 'reward'])
# df40 = pd.DataFrame(transformData(m70), columns=['run', 'episode', 'reward'])
# df50 = pd.DataFrame(transformData(m80), columns=['run', 'episode', 'reward'])
df20 = pd.DataFrame(transformData(m30), columns=['run', 'episode', 'reward'])
df30 = pd.DataFrame(transformData(m60), columns=['run', 'episode', 'reward'])
df40 = pd.DataFrame(transformData(m70), columns=['run', 'episode', 'reward'])
df50 = pd.DataFrame(transformData(m80), columns=['run', 'episode', 'reward'])
# df60 = pd.DataFrame(transformData(m90), columns=['run', 'episode', 'reward'])
#ax = sns.lineplot(x='episode',y='reward', color='blue', data=df10,ci=80)
# ax = sns.lineplot(x='episode', y='reward',color='red', data=df20, ci=60)
# ax = sns.lineplot(x='episode', y='reward', color='purple', data=df30, ci=40)
# ax = sns.lineplot(x='episode', y='reward', color='blue', data=df40, ci=60)
# ax = sns.lineplot(x='episode',y='reward', color='orange',data=df50,ci=60)
ax = sns.lineplot(x='episode', y='reward',color='red', data=df20, ci=60)
ax = sns.lineplot(x='episode', y='reward', color='purple', data=df30, ci=40)
ax = sns.lineplot(x='episode', y='reward', color='blue', data=df40, ci=60)
ax = sns.lineplot(x='episode',y='reward', color='orange',data=df50,ci=60)
# ax = sns.lineplot(x='episode',y='reward', color='green',data=df60,ci=60)
# plt.ylim(-140,25)
# plt.legend(['GLAE','GS','DW', 'Matrix','APP'], loc='lower right', fontsize='x-small')
# plt.title('Maze 8')
# plt.xlabel('Episodes')
# plt.ylabel('Average Cumulative Reward')
plt.legend(['GLAE-20','GLAE-30','GLAE-40','GLAE-50'], loc='lower right', fontsize='x-small')
plt.title('Maze 6 GLAE')
plt.xlabel('Episodes')
plt.ylabel('Average Cumulative Reward')
plt.show()
Markdown is supported
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