Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Humanoid Path Planner
hpp-rbprm-corba
Commits
3357eaae
Commit
3357eaae
authored
Jun 11, 2020
by
Pierre Fernbach
Browse files
[Scripts] AbstractPlanner: add optional argument to solve() to display the roadmap
parent
3877a6ea
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/hpp/corbaserver/rbprm/scenarios/abstract_path_planner.py
View file @
3357eaae
...
...
@@ -156,7 +156,7 @@ class AbstractPathPlanner:
else
:
self
.
ps
.
addPathOptimizer
(
"RandomShortcut"
)
def
solve
(
self
):
def
solve
(
self
,
display_roadmap
=
False
):
"""
Solve the path planning problem.
q_init and q_goal must have been defined before calling this method
...
...
@@ -168,7 +168,10 @@ class AbstractPathPlanner:
self
.
ps
.
setInitialConfig
(
self
.
q_init
)
self
.
ps
.
addGoalConfig
(
self
.
q_goal
)
self
.
v
(
self
.
q_init
)
t
=
self
.
ps
.
solve
()
if
display_roadmap
and
self
.
v
.
client
.
gui
.
getNodeList
()
is
not
None
:
t
=
self
.
v
.
solveAndDisplay
(
"roadmap"
,
5
,
0.001
)
else
:
t
=
self
.
ps
.
solve
()
print
(
"Guide planning time : "
,
t
)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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