In compass_gait_limit_cycle.ipynb, I followed the instruction and added five groups of constraints:
for t in range(T):
vars = q[t]
prog.AddConstraint(swing_foot_height, lb=[0]*nq, ub=[np.inf]*nq, vars=vars)
However, I got the error information:
RuntimeError Traceback (most recent call last)
<ipython-input-24-5cf4d7a05da1> in <module>()
1 # solve mathematical program with initial guess
2 solver = SnoptSolver()
----> 3 result = solver.Solve(prog, initial_guess)
4
5 # ensure solution is found
RuntimeError: PyFunctionConstraint: Output must be of .ndim = 1 or 2 (vector) and .size = 4. Got .ndim = 1 and .size = 1 instead.