def chooseErrorData(self, game, lesson=None):
'''
Choose saved error function data by lesson and game name in
history database.
'''
self.history.setGame(game)
self.load()
if lesson is not None:
self.error_data_training = np.split(self.data[0,:],
np.argwhere(self.data[0,:] == -1))[lesson][1:]
self.error_data_test = np.split(self.data[1,:],
np.argwhere(self.data[1,:] == -1))[lesson][1:]
else:
self.error_data_training = np.delete(self.data[0,:],
np.argwhere(self.data[0,:]==-1))
self.error_data_test = np.delete(self.data[1,:],
np.argwhere(self.data[1,:]==-1))
# ------------------- for test and show reasons only ----------------------
评论列表
文章目录