Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Guilhem Saurel
hpp-rbprm-corba
Commits
3bccce9c
Commit
3bccce9c
authored
Aug 12, 2019
by
Joseph Mirabel
Browse files
Make demo darpa_hyq Python 3 compatible.
parent
66e5a373
Changes
2
Hide whitespace changes
Inline
Side-by-side
script/scenarios/demos/darpa_hyq.py
View file @
3bccce9c
...
...
@@ -103,7 +103,7 @@ def genPlan(stepsize=0.06):
start
=
time
.
time
()
configs
=
fullBody
.
interpolate
(
stepsize
,
5
,
0.
,
filterStates
=
True
,
testReachability
=
False
)
end
=
time
.
time
()
print
"Contact plan generated in "
+
str
(
end
-
start
)
+
"seconds"
print
(
"Contact plan generated in "
+
str
(
end
-
start
)
+
"seconds"
)
def
contactPlan
(
step
=
0.5
):
v
.
client
.
gui
.
setVisibility
(
"hyq"
,
"ON"
)
...
...
@@ -115,6 +115,6 @@ def contactPlan(step = 0.5):
time
.
sleep
(
step
)
print
"Root path generated in "
+
str
(
tp
.
t
)
+
" ms."
print
(
"Root path generated in "
+
str
(
tp
.
t
)
+
" ms."
)
genPlan
(
0.01
);
contactPlan
(
0.01
)
script/scenarios/demos/darpa_hyq_path.py
View file @
3bccce9c
...
...
@@ -57,7 +57,7 @@ t = ps.solve ()
if
isinstance
(
t
,
list
):
t
=
t
[
0
]
*
3600000
+
t
[
1
]
*
60000
+
t
[
2
]
*
1000
+
t
[
3
]
print
"computation time for root path "
,
t
print
(
"computation time for root path "
,
t
)
# Playing the computed path
from
hpp.gepetto
import
PathPlayer
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment