MCPcopy Create free account
hub / github.com/BIT-MCS/DRL-eFresh / plot_error_lines

Function plot_error_lines

utils/base_utils.py:267–283  ·  view source on GitHub ↗
(name,list_mean,list_min,list_max,list_var,full_path)

Source from the content-addressed store, hash-verified

265 pdf.close()
266
267def plot_error_lines(name,list_mean,list_min,list_max,list_var,full_path):
268 plt.plot(list_mean,color='green',label="mean")
269 plt.plot(list_var,color='red',label="std")
270 plt.plot(list_min,color='b',alpha=0.2,label="min")
271 plt.plot(list_max,color='b',alpha=0.2,label="max")
272 if params.trainable is True:
273 plt.xlabel("Training episode")
274 else:
275 plt.xlabel("Step")
276
277 plt.fill_between(range(len(list_mean)),list_min,list_max,color='b',alpha=0.2)
278 plt.ylabel(name)
279 plt.grid(True)
280 plt.legend()
281 plt.grid(linestyle='--')
282 plt.savefig(full_path + "/"+name+'.png')
283 plt.close()
284
285def plot_age_lines(uav_aoi_list,move_aoi_list,collect_aoi_list,sendback_aoi_list,full_path):
286 uav_aoi_array=np.array(uav_aoi_list).transpose((1,0))

Callers 1

draw_pathMethod · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected