Skip to content

Commit fa22624

Browse files
committed
Merge branch 'main' of https://github.com/DojoSim/Dojo.jl into main
2 parents b10750a + 2a3f3ea commit fa22624

File tree

1 file changed

+43
-0
lines changed

1 file changed

+43
-0
lines changed

docs/src/system_identification.md

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,45 @@
11
# System Identification
22

3+
A [real-world dataset](https://github.com/DAIRLab/contact-nets/tree/main/data) is used to learn the geometric and friction properties of a block being tossed onto a flat surface. Gradient-based optimization is employed to regress parameters and real-to-sim validation is performed. The ground truth system is shown in orange and the learned system in blue.
4+
5+
## Geometry
6+
7+
```@raw html
8+
<img src="../../examples/animations/box_learning.gif" width="300"/>
9+
```
10+
11+
The eight locations of the block's corners relative to its center of mass are learned.
12+
13+
## Friction
14+
15+
```@raw html
16+
<img src="../../examples/animations/cone_learning.gif" width="200"/>
17+
```
18+
19+
A friction coefficient, describing a friction cone, is learned for all of the contact points.
20+
21+
## Real-To-Sim
22+
23+
```@raw html
24+
<img src="../../examples/animations/box_toss.gif" width="300"/>
25+
```
26+
27+
The system parameters are learned to within a ``\pm 5 \%`` error from their ground-truth values. These parameters are then compared to the ground-truth system in simulation.
28+
29+
## Learning
30+
31+
The cost function:
32+
33+
``\mathcal{L}(\mathcal{D}, \theta) = \sum_{Z \in \mathcal{D}} L(Z, \theta) = \sum_{Z \in \mathcal{D}} \frac{1}{2} ||s(z_{-}, z, \theta) - z_{+}||_W^2``,
34+
35+
is used where ``\mathcal{D}`` is a dataset of trajectories containing tuples ``(z_{-}, z, z_{+})`` of state sequences, with system parameters ``\theta \in \mathbf{R}^p``, and where ``s : \mathbf{Z} \times \mathbf{Z} \times \mathbf{R}^p \rightarrow \mathbf{Z}`` represents the simulator.
36+
37+
A quasi-Newton method is employed to optimize the cost function and uses gradients:
38+
39+
``\frac{\partial L}{\partial \theta} = {\frac{\partial s}{\partial \theta}}^T W \Big(s(z_{-}, z, \theta) - z_{+} \Big)``,
40+
41+
and the following Gauss-Newton approximation:
42+
43+
``\frac{\partial^2 L}{\partial \theta^2} \approx {\frac{\partial s}{\partial \theta}}^T W \frac{\partial s}{\partial \theta}``,
44+
45+
of the cost function Hessian, which only relies on Jacobians from Dojo.

0 commit comments

Comments
 (0)