Questions tagged [drake]

Drake is an open-source toolbox for planning, control, and analysis of nonlinear systems, developed in C++ with bindings available in Python.

Drake is an open-source toolbox for planning, control, and analysis of nonlinear systems, developed in C++ with bindings available in Python.

Resources

692 questions
0
votes
1 answer

Could you demo a very simple C++ example about Symbolic variable and Jacobian by converting Pydrake code to C++ version?

I am trying to convert the following pydrake code to C++ version. Unfortunately,I get lost in the very rigorous C++ API documentation. Could you help to convert the following code into C++ version for a tutorial? Thank you so much! import…
Wc Chang
  • 97
  • 6
0
votes
1 answer

How are you supposed to use a controller with a URDF

I'm trying to use the LQR Controller to move the wheels on this really simple URDF linked here I'm trying to understand how to use the LQR controller for a model loaded from a URDF so this is a mix of the LQR example and the PR2 Example …
cjds
  • 8,268
  • 10
  • 49
  • 84
0
votes
1 answer

Sinusoidal initial trajectory guess for DirectCollocation in Drake

I am trying to provide the solver with an initial guess that is a sinusoidal trajectory. I was hoping that there would be a way to specify the initial guess for the individual knot points, because then it would have been quite simple to provide the…
bernhardpg
  • 61
  • 5
0
votes
1 answer

Visualization Error Shown during Linearization/LQR for Acrobot but not for Double Pendulum

I am trying to port the scripts I made for the double pendulum to the acrobot (moving towards more underactuation). While doing this, I saw that the LQR Controller script (inspired mainly from this notebook from the underactuated course), gave…
Shubham Vyas
  • 163
  • 10
0
votes
1 answer

Understanding State Groups in Context in Drake

I've created a diagram with an LQR Controller, a MultiBodyPlant, a scenegraph, and a PlanarSceneGraphVisualizer. While trying to run this simulation, I set the random initial conditions using the function: context.SetDiscreteState(randInitState).…
Shubham Vyas
  • 163
  • 10
0
votes
1 answer

Recording multiple meshcat visualizers

I would like to record multiple meshcat visualizers with different prefix ids so I can eventually save them to an HTML file that I can interact with later. I would like the different visualizations to play on top of each other and to be able to…
0
votes
2 answers

Using le or ge with scalar left hand side creates unsized formula array

When creating a formula with le or ge with a scalar left hand side, the returned formula has .shape == (), i.e. is an unsized object. This causes problems when adding a constraint with the formula. I'm not sure if this is a bug. prog =…
Rufus
  • 5,111
  • 4
  • 28
  • 45
0
votes
0 answers

PyDrake: Meshcat Not Visualzing URDF with (psuedo) Spherical Joint

I am trying to add reaction wheels to a robotic spacecraft model in drake. For this, I am adding 3 revolute joints to the spacecraft base to simulate the torques applied on the base by the reaction wheels. Since URDF specification does not allow for…
Shubham Vyas
  • 163
  • 10
0
votes
1 answer

TypeError: set_value(): incompatible function arguments

This code should be simple enough. But I can't get it right. And, I don't find answer from previous similar questions. Is it a pydrake issue or just I don't use it in the right way? TypeError: set_value(): incompatible function arguments. The…
Wc Chang
  • 97
  • 6
0
votes
1 answer

How do I save label images from pydrake / Drake directly to disk?

How do I write label images from Drake to disk using PIL? If I try Image.fromarray(label), I get an error that looks like this: File ".../PIL/Image.py", line 2751, in fromarray raise TypeError("Cannot handle this data type: %s, %s" % typekey)…
Eric Cousineau
  • 1,944
  • 14
  • 23
0
votes
1 answer

Using OMPL with Drake

I am trying to work with ompl on drake and am having issues with using the ompl headers in drake. I installed ompl using the default installation path and made the following changes in drake: Added the following to the…
0
votes
2 answers

How to obtain centroidal momentum matrix?

According to Whole-body Motion Planning with Centroidal Dynamics and Full Kinematics (Hongkai Dai, Andrés Valenzuela and Russ Tedrake) Following the reference, one eventually arrives Resolved Momentum Control: Humanoid Motion Planning based on the…
Rufus
  • 5,111
  • 4
  • 28
  • 45
0
votes
1 answer

Sporadic failure in GLX

I am running OpenGL in headless mode with Xserver and invoking this api multiple times: https://github.com/RobotLocomotion/drake/blob/74292cacd1c42d6b3e682dc836254cdb834ea2e6/geometry/render/render_engine_vtk.cc#L311 Sporadically but almost always…
am83
  • 23
  • 3
0
votes
1 answer

Constraint on Ability to Switch Input Values for Trajectory Optimization in Model Predictive Control Framework

I am trying to add a constraint which specifies that, in the optimization, the solver must pick a value of u for a set duration of time and can only switch after that set amount of time. For instance, say I have a mechanical device which can only…
0
votes
1 answer

Processing rgb images

I am using Drake to implement a visual servoing scheme. For that I need to process color images and extract features. I am using the ManipulationStation class, and I have already published the color images of the rgbd_sensor objects to LCM channels…