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
6
votes
1 answer

The hydroelastic contact does not give expected contact surface

I have been using Hydroelastic Contact to simulate a peg-in-hole task. The simulation scene is like The blue peg is a compliant hydroelastic cylinder and the hole is a rigid hydroelastic mesh. The wire frame view of the hole mesh is When I push…
Chen Wang
  • 448
  • 2
  • 11
6
votes
1 answer

When to use drake-visualizer vs meshcat visualizer

What is the difference between these 2 visualizers that are available with drake? When should I use one over another?
Rufus
  • 5,111
  • 4
  • 28
  • 45
5
votes
2 answers

drake gurobi cannot handle quadratic constraint

I am currently working to implement a simple quadratic constraint on an optimization problem. Gurobi's website says that quadratic constraints can be implemented. Does drake not have an interface with this constraint using Gurobi? The code is as…
Yuki
  • 139
  • 6
5
votes
1 answer

Mesh based collision geometry in drake

I wanted to generate datasets for perception and grasping based on the physics engine. I tried importing following 3D models released by google research recently ( https://app.ignitionrobotics.org/GoogleResearch ) into drake and creating the…
darshan
  • 1,230
  • 1
  • 11
  • 17
4
votes
1 answer

Retrieve symbolic function from cost or constraint in pydrake

I apparently have a complicated enough constraint function that it takes over 1 minute just to call prog.AddConstraint(), presumably because it's spending a long time constructing the symbolic function (although if you have other insights why it…
adamconkey
  • 4,104
  • 5
  • 32
  • 61
4
votes
1 answer

In Drake, how do I convert an NumPy array to different scalar types? (e.g. from float to AutoDiffXd or Expression?)

In Drake, I have NumPy ndarray's (some multidimensional) that are of dtype=float, and I want to convert them to AutoDiffXd, Expression, etc. In C++, I know I can do things like this: MatrixXd X(2, 2); X << 1.0, 2.0, 3.0,…
Eric Cousineau
  • 1,944
  • 14
  • 23
4
votes
1 answer

Adding a torsional spring to rigid body plant in drake

I'm new to using drake and trying to add a torsional spring through pydrake to an acrobot model imported from urdf. The relevant portion of the code looks like this builder = DiagramBuilder() plant, scene_graph = AddMultibodyPlantSceneGraph(builder,…
4
votes
1 answer

Why does this simple MP for finding angular velocity between 2 quaternions fail?

This is a follow up to What is the recommended way of constraining floating base quaternion position and angular velocity? As a sample problem, I am trying to find the angular velocity given a starting quaternion, ending quaternion, and a specific…
Rufus
  • 5,111
  • 4
  • 28
  • 45
4
votes
1 answer

Question regarding Drake's current inverse kinematics code

I've been looking into some papers on inverse kinematics planning with collision avoidance for a robotic arm. I found this paper called, "Global Inverse Kinematics via Mixed-Integer Convex Optimization", which I believe a few of Drake's developer's…
Yuki
  • 139
  • 6
4
votes
2 answers

Cost function using absolute value and division by decision variables

I am trying to implement a cost function in a pydrake Mathematical program, however I encounter problems whenever I try to divide by a decision variable and use the abs(). A shortened version of my attempted implementation is as follows, I tried to…
4
votes
2 answers

How to use decision variable from MathematicalProgram in a multibody plant (TypeError)

I'm trying to add dynamics constraints to my mathematical program. However, I get TypeError as pasted below indicating MBP is unhappy with a continuous variable being an input. Do I need to convert the symbolic variable to numerical values somehow…
zliu
  • 143
  • 6
4
votes
2 answers

Applying an external force to an object in pydrake

This questions is strongly related to adding-forces-to-body-post-finalize I would like to be able to apply an external force to simple geometric primitives in pydrake. This is to perform an evaluation of interactions between bodies. My current…
Guillaume
  • 163
  • 10
3
votes
1 answer

How to exclude an object from KInematic Trajectory Optimization #Drake

I want to enable a gripper to do pick&place an object from a shelf. For this, I am trying to use trajectry optimization using KInematic Trajectory Optimization and I am using this deepnote. But the problem is when I add an object to the plant, also…
3
votes
1 answer

Time derivative of contact jacobian

I was implementing some ideas from [1] and [2], and I came across the need to calculate Jc_dot. For example in [1] they project the linearized system into the nullspace of the contact constraints (top right of the second page). From what I…
3
votes
1 answer

Define New Shapes For Proximity Engine

I'd like to define two new classes of Shape: Mesh class that allows vertices/faces to be passed in directly (current Mesh class only takes in a filepath), and Cone class that supports proximity queries (MeshcatCone is the only existing one, I don't…
alvin
  • 137
  • 7
1
2 3
46 47