in experiments/rolling/Rolling.py [0:0]
def _f(self, xs):
costs = []
goals = [
[0.3, 0.3],
[0.3, 0.5],
[0.3, 0.7],
[0.5, 0.3],
[0.5, 0.7],
[0.7, 0.3],
[0.7, 0.5],
[0.7, 0.7],
]
print("xs", xs)
for i in range(len(xs)):
K = xs[i].reshape([2, 2]) / 1000
c = 0
for goal in goals:
c += self.env.simulate(goal, K)
costs.append([c / len(goals)])
costs = np.matrix(costs)
print("costs", costs)
return costs