Skip to content
This repository has been archived by the owner on Oct 31, 2023. It is now read-only.

Query regarding learning of robot model using this code #2

Open
deepakraina99 opened this issue Nov 6, 2020 · 1 comment
Open

Query regarding learning of robot model using this code #2

deepakraina99 opened this issue Nov 6, 2020 · 1 comment

Comments

@deepakraina99
Copy link

deepakraina99 commented Nov 6, 2020

Dear Contributors,

Great work! I have thoroughly looked into the code and understood the following:

Step 1: First the sine wave trajectory data having (q, dq, ddq, tau) is being generated using ground truth robot model as given below:

train_data = generate_sine_motion_inverse_dynamics_data(gt_robot_model, n_data=1000, dt=1.0/250.0, freq=0.05)

Step 2: Then torque values are predicted using the learnable robot model as:

tau_pred = learnable_robot_model.compute_inverse_dynamics(q=q, qd=qd, qdd_des=qdd_des, include_gravity=True)

My query is regarding the step 2. You are computing the inverse dynamics (i.e. tau) using the same model from which you have computed the ground truth values. I think the learnable robot model should be a neural network. Please guide me regarding this.

Thanks.

Best,
Deepak Raina

@deepakraina99 deepakraina99 changed the title Query regrding learning of robot model using this code Query regarding learning of robot model using this code Nov 6, 2020
@fmeier
Copy link
Contributor

fmeier commented Dec 2, 2020

Hi Deepak,

Thanks! and sorry for the long wait! To answer your question:

When we instantiate a robot model, we can instantiate either with ground truth parameters (which are taken from the Urdf), or with unknown parameter values (for instance randomly initialized). In the 2nd case we would then estimate these parameters from data. So when we generate data, we use the ground truth parameters from the Urdf.

An example of where we generate data using the ground truth model, and then compare learning a "structured robot model" (robot model with randomly initialized parameters) to an "unstructured robot model" (neural network) in the ipython notebook
https://github.com/facebookresearch/differentiable-robot-model/blob/master/experiments/l4dc-sim-exps.ipynb

I hope this helps!
Franziska

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants