Skip to content

Commit

Permalink
[sample/SampleRobot/samplerobot_auto_balancer.py] apply numpy.allclos…
Browse files Browse the repository at this point in the history
…e to list of list
  • Loading branch information
eisoku9618 committed Sep 2, 2015
1 parent 1f83310 commit 256d997
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion sample/SampleRobot/samplerobot_auto_balancer.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ def demoAutoBalancerSetParam():
hcf.startAutoBalancer();
hcf.stopAutoBalancer();
ret=hcf.abc_svc.getAutoBalancerParam()
flag = (ret[0] and all([numpy.allclose(act, ref, 1e-6) for act, ref in zip(ret[1].default_zmp_offsets, abcp.default_zmp_offsets)]))
flag = (ret[0] and numpy.allclose(ret[1].default_zmp_offsets, abcp.default_zmp_offsets, 1e-6))
if flag:
print >> sys.stderr, " setAutoBalancerParam() => OK"
assert (flag), (ret[0], ret[1].default_zmp_offsets, abcp.default_zmp_offsets)
Expand Down

0 comments on commit 256d997

Please sign in to comment.