loss = self.algorithm.train()
explore_var = self.algorithm.update()
self.loss_history.append(loss)
self.explore_var_history.append(explore_var)
def close(self):
"""Close agent at the end of a session, e.g. save model"""
// TODO save model
After Change
data_names = ["loss", "explore_var"]
loss_a, explore_var_a = self.agent_space.aeb_space.init_data_s(
data_names, a=self.a)
for (e, b), body in util.ndenumerate_nonan(self.body_a):
loss_a[(e, b)] = loss
explore_var_a[(e, b)] = explore_var
return loss_a, explore_var_a
def close(self):