Improve options for loadSDF #3733
ShravanTata
started this conversation in
General
Replies: 1 comment
-
I have a urdf robot description file, but there are loops in the robot structure, so I convert it to a sdf file using the command import pybullet as p
import pybullet_data
import os
cheetahDIR = os.path.dirname(__file__)
physicsClient = p.connect(p.GUI) # or p.DIRECT for non-graphical version
p.setGravity(0, 0, -9.81)
p.setAdditionalSearchPath(pybullet_data.getDataPath())
planeId = p.loadURDF("plane.urdf")
cheetahStartPos = [0, 0, 0.7]
p.setAdditionalSearchPath(cheetahDIR)
# cheetahId = p.loadURDF('cheetah/cheetah.urdf', cheetahStartPos) # This line can load the robot model without loop constraint.
cheetahId = p.loadSDF('cheetah/cheetah.sdf', cheetahStartPos) # This line cannot run properly even if I have comment the loops in the sdf file
while True:
p.stepSimulation()
p.disconnect() And I have noticed this answer, does this mean that the pybullet does not support loops in a sdf file? |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Currrently load sdf supports only minimal options when compared to loadURDF or createMultiBody. It would be good to expose all the options to loadSDF since it is a "more widely" used description format.
Beta Was this translation helpful? Give feedback.
All reactions