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
Jason Chemin
hpp-rbprm-corba
Commits
3ff8652c
Commit
3ff8652c
authored
Apr 30, 2018
by
Pierre Fernbach
Browse files
[scripts] small changes in tools scripts
parent
77b7bee3
Changes
3
Hide whitespace changes
Inline
Side-by-side
script/dynamic/export_blender.py
View file @
3ff8652c
...
...
@@ -45,7 +45,7 @@ r.client.gui.captureTransformOnRefresh(False)
nodes
=
[
'world/pinocchio'
]
gui
.
setCaptureTransform
(
"/local/dev_hpp/screenBlender/
iros2018/yaml/darpa_wholeBody
.yaml"
,
nodes
)
gui
.
setCaptureTransform
(
"/local/dev_hpp/screenBlender/
locomote/yaml/stairs10_NO_effectorRRT
.yaml"
,
nodes
)
#gui.captureTransform()
gui
.
captureTransformOnRefresh
(
True
)
gui
.
captureTransformOnRefresh
(
False
)
...
...
@@ -63,6 +63,8 @@ r.client.gui.captureTransformOnRefresh(False)
r
.
client
.
gui
.
writeBlenderScript
(
"/local/dev_hpp/screenBlender/talos/models/pyrene.py"
,
[
'talos'
])
r
.
client
.
gui
.
writeBlenderScript
(
"/local/dev_hpp/screenBlender/talos/stairs.py"
,
[
'world'
])
nodes
=
[
"hrp2_14"
,
"Vec_Acceleration"
,
"Vec_Velocity"
]
r
.
client
.
gui
.
setCaptureTransform
(
"/local/dev_hpp/screenBlender/iros2017/yaml/slope_interp_3.yaml"
,
nodes
)
r
.
client
.
gui
.
captureTransformOnRefresh
(
True
)
...
...
script/tools/cut_contact_sequence.py
View file @
3ff8652c
...
...
@@ -9,7 +9,7 @@ import planning.generate_muscod_problem as mp
import
muscodSSH
as
ssh
from
planning.config
import
*
statesPerStep
=
5
# number of double support configs from the planning per call to muscod
statesPerStep
=
4
# number of double support configs from the planning per call to muscod
stepSize
=
statesPerStep
*
2
-
1
# contact_sequence contain double support AND simple support states
def
solveMuscodProblem
(
configsFull
,
cs
):
...
...
script/tools/disp_bezier.py
View file @
3ff8652c
...
...
@@ -6,7 +6,7 @@ from numpy.linalg import norm
def
displayBezierCurve
(
r
,
curve
,
step
=
0.001
,
color
=
[
0.85
,
0.75
,
0.15
,
1.0
],
name
=
None
):
def
displayBezierCurve
(
r
,
curve
,
step
=
0.001
,
color
=
[
0.85
,
0.75
,
0.15
,
1.0
],
name
=
None
,
offset
=
None
):
if
name
==
None
:
name
=
"bezier_curve"
list
=
r
.
client
.
gui
.
getNodeList
()
...
...
@@ -17,7 +17,12 @@ def displayBezierCurve(r,curve,step=0.001,color=[0.85, 0.75, 0.15, 1.0],name=Non
current
=
0
path
=
[]
while
current
<=
curve
.
max
():
path
+=
[
curve
(
current
).
transpose
().
tolist
()[
0
]]
p
=
curve
(
current
).
transpose
().
tolist
()[
0
]
if
offset
:
assert
(
len
(
offset
)
==
len
(
p
))
for
i
in
range
(
len
(
p
)):
p
[
i
]
+=
offset
[
i
]
path
+=
[
p
]
current
+=
step
r
.
client
.
gui
.
addCurve
(
name
,
path
,
color
)
r
.
client
.
gui
.
addToGroup
(
name
,
r
.
sceneName
)
...
...
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