D IFF S KILL : S KILL A BSTRACTION FROM D IFFERENTIABLE P HYSICS FOR D EFORMABLE O BJECT M ANIPULATIONS WITH T OOLS
eng
Yunzhu Li
MIT BCS, CBMM, CSAIL jbt@mit.edu
Chuang Gan
MIT-IBM Waston AI Lab chuangg@mit.com
A BSTRACT
We consider the problem of sequential robotic manipulation of deformable objects using tools.
Previous works have shown that differentiable physics simulators provide gradients to the environment state and help trajectory optimization to converge orders of magnitude faster than model-free reinforcement learning algorithms for deformable object manipulation.
However, such gradient-based trajectory optimization typically requires access to the full simulator states and can only solve short-horizon, single-skill tasks due to local optima.
In this work, we propose a novel framework, named DiffSkill, that uses a differentiable physics simulator for skill abstraction to solve long-horizon deformable object manipulation tasks from sensory observations.
In particular, we ﬁrst obtain short-horizon skills using individual tools from a gradient-based optimizer, using the full state information in a differentiable simulator; we then learn a neural skill abstractor from the demonstration trajectories which takes RGBD images as input.
Finally, we plan over the skills by ﬁnding the intermediate goals and then solve long-horizon tasks.
We show the advantages of our method in a new set of sequential deformable object manipulation tasks compared to previous reinforcement learning algorithms and compared to the trajectory optimizer.
Videos are available at our project page 1 .
I NTRODUCTION
Robot manipulation of deformable objects is a fundamental research problem in the ﬁeld of robotics and AI and has many real-world applications such as laundry making (Maitin-Shepard et al., 2010), cooking (Bollini et al., 2013), and caregiving tasks like assistive dressing, feeding or bed bathing (Erickson et al., 2020).
The recent development of differentiable physics simulators for deformable objects has shown promising results for solving soft-body control problems (Hu et al., 2019b; Murthy et al., 2020; Heiden et al., 2021;
Huang et al., 2021).
These differentiable simulators have facilitated gradient-based trajectory optimizers to ﬁnd a motion trajectory with much fewer samples, compared with black box optimizers such as CEM or reinforcement learning algorithms (Huang et al., 2021;
Heiden et al., 2021; Geilinger et al., 2020).
However, the usage of these simulators is often limited in two ways.
First, most differentiable physics simulators are only applied to solve short-horizon, single-skill tasks, such as cutting (Heiden et al., 2021), ball throwing (Geilinger et al., 2020), or locomotion (Hu et al., 2019b).
This is partly because the gradient only provides local information, and thus, gradient-based optimizers often get stuck in local optima, preventing them from solving long horizon tasks.
For example, consider a two-stage task of ﬁrst gathering scattered dough on a table and then putting it on the cutting board using a spatula (Figure 1).
If the objective function is to minimize the distance between all the dough
[Figure] [Figure]
and the cutting board, a gradient-based trajectory optimizer would directly use the spatula to put a small amount of dough on the cutting board without ever using the gathering operation.
Second, the agent needs to know the full simulation state and relevant physical parameters in order to perform gradient-based trajectory optimization, which is a great limiting factor for real-world generalization, as reliable full state estimation of deformable objects from sensory data like RGB-D images can often be challenging and sometimes impossible due to ambiguities caused by self-occlusions.
Planning over the temporal abstraction of skills is a powerful approach to tackle the ﬁrst issue of solving long horizon tasks.
However, ﬁnding a suitable set of skills is challenging.
For example, while standard skills such as grasping an object or moving the robot arm from one pose to another may be manually speciﬁed (Toussaint et al., 2018), more complex skills such as cutting or gathering can be difﬁcult to deﬁne manually.
Therefore, it is desirable to learn these skills automatically.
In this work, we aim to solve a novel set of sequential dough manipulation tasks that involve operating various tools and multiple stages of actions (Figure 1), including lifting and spreading, gathering and transporting, cutting and rearranging the dough.
To extend the use of differentiable physics models to these long-horizon tasks and enable the agent to directly consume visual observations, we propose
DiffSkill: a novel framework where the agent learns skill abstraction using the differentiable physics model and composes them to accomplish complicated manipulation tasks.
Our method consists of three components, (1) a trajectory optimizer that acts as an expert that applies gradient-based optimization on the differentiable simulator to obtain demonstration trajectories, which requires the full state information from the simulator (2) a neural skill abstractor that is instantiated as a goal-conditioned policy, taking RGBD images as input and imitating the demonstration trajectories, and (3) a planner that learns to assemble the abstracted skills by opgimizing the intermediate goals to reach and solve the long horizon tasks.
Experiments show that our method, operating on the high-dimensional RGB-D images, can successfully accomplish a set of the dough manipulation tasks, which greatly outperforms the model-free RL baselines and the standalone gradient-based trajectory optimizer.
M ETHOD
Our goal is to learn a policy to perform sequential deformable object manipulation using tools from sensory observations.
We utilize a differentiable physics simulator during training.
Since it is not feasible to directly use a standalone differentiable physics solver to ﬁnd an optimal solution for long-horizontal tasks, we propose to ﬁrst learn to abstract primitive skills from this differentiable physics simulator; we then plan on top of these skills to solve long-horizon tasks.
An overview of our framework is shown in Figure 2.
[Figure]
) Collecting demonstration in
[Figure] [Figure]
2. P ROBLEM FORMULATION
We consider a Markov Decision Process (MDP) deﬁned by a set of states s ∈ S , actions a ∈ A and a deterministic, differentiable transition dynamics s t
+1 = p ( s t , a t ) , with t indexing the discrete time.
At each timestep, the agent only has access to an observation o ∈ O (such as an image) instead of directly observing the state.
For any goal state s g ∈ G , a distance function from the state s is given as
D ( s, s g ) .
The objective is to ﬁnd a policy a t =
π
( o, o g ) that minimizes the ﬁnal distance to the goal
D ( s T , s g ) , where T is the length of an episode.
2. C OLLECTING D EMONSTRATION T RAJECTORIES WITH D IFFERENTIABLE P HYSICS
Previous work has shown that differentiable physics solvers can acquire short-horizon skills for deformable object manipulation in tens of iterations (Huang et al., 2021).
Inspired by this work, we ﬁrst collect demonstration trajectories of using each tool to achieve a short-term goal.
Given an initial state s 0 , a goal state s g and the transition dynamics p of a differentiable simulator, we use gradient-based trajectory optimization to solve for an open-loop action sequence (Kelley, 1960): arg min a 0 ,...a T − 1 L ( a 0 , . . .
a T − 1 )
= arg min a 0 ,...
a T −
T (cid:88) t =
D ( s t , s g )
+ λ
T (cid:88) t =
E ( m ( s t ) , d ( s t )) , where s t +1 = p ( s t , a t ) , (1)
In the case of deformable object manipulation, we represent the current and target shape of the deformable object as two sets of particles and use the Earth Mover Distance (EMD) between the two particle sets as the distance metric D ( s t , s g ) , which we approximate with the Sinkhorn
Divergence (Séjourné et al., 2019) .
To encourage the manipulator to approach the deformable object, we additionally add into the objective the Euclidean distance between the manipulator and the deformable object E ( m ( s t ) , d ( s t )) , with a weight λ , where m ( s t ) and d ( s t ) are the positions of the center of mass of the manipulator and deformable object at time t , respectively.
We solve Equationby updating the action sequence using ∇ a t L, t = 0 . . .
T, with an Adam optimizer (Kingma & Ba, 2014), initialized using an action sequence of all zeros.
In this paper, we deﬁne a “skill" as a policy that uses a single tool to achieve a short-horizon goal s g , starting from an initial state s 0 .
Each skill corresponds to the use of one tool and can be applied to different observations.
For example, in the LiftSpread task, the skill of using the rolling pin can be applied to either when the dough is on the right or when the dough is on the cutting board.
Assuming that we have K tools, the action space over all tools can be written as [ A (1) , . . .
A ( K ) ] , where A ( k ) is the action space of the k th tool.
When collecting demonstration for learning the skills, for each short-horizon goal s g , we run the trajectory optimizer for each tool separately, by masking the actions for other tools to be zero at each timestep.
2. N EURAL S KILL A BSTRACTION
Although the trajectory optimizer is able to provide solutions for short-horizon tasks, it is unable to solve long-horizon tasks due to local optima.
Furthermore, running the trajectory optimizer requires knowing the full state of the environment, including particle positions and mass distributions of the deformable objects and the physical parameters of these objects.
This information is difﬁcult to obtain during real-world deployment, where the observations available to a robot are from sensory information such as RGB-D images.
Additionally, the trajectory optimizer takes minutes to run, which is too slow during evaluation for real-time applications.
As such, we propose to learn a neural skill abstractor that learns skills from the demonstration videos of a trajectory optimizer; we will then leverage these skills for solving long horizon tasks.
Our neural skill abstraction consists of a goal-conditioned policy that takes a sensory observation (RGB-D images in our case) as input, a feasibility and reward predictor, as well as a variational auto-encoder (VAE).
Goal conditioned policy: For each tool, we learn a goal-conditioned neural policy a t = π k
( o t , o g ) ∈
A ( k ) , using behavior cloning from the corresponding demonstration trajectories collected for the k th tool.
Given the demonstration trajectory ( s 0 , a 0 , . . .
, s T ) and the corresponding RGB-D sensory observations ( o 0 , . . .
o T ) , as well as an observation of the goal
o g , we train a policy using the MSE loss L policy =
||
π ( o t , o g ) − a t || 22 .
Furthermore, to make the policy more robust to goal observations outside of the training goal images, we adopt hindsight relabeling (Andrychowicz et al., 2017).
When sampling from the demonstration buffer, with a probability p hind , we will relabel the original goal o g with a hindsight goal ¯
o i , where ¯ o i ∼ Uniform { o t +1 , . . .
o T } .
The intuition is that, for any goal that will be achieved by the current action sequence, the policy should imitate the current action.
Variational Auto-Encoder: As will be explained in Section 2.4, we will plan to compose skills in a latent space instead of optimizing directly in the image space.
To learn the latent space, we train a generative model of the observation space, speciﬁcally a VAE Kingma & Welling (2013).
The
VAE includes an encoder z
= Q ( o ) that encodes an observation into a ﬁxed length latent vector, and a decoder o = G ( z ) that decodes back into the observation space.
The VAE is trained such that
G ( z ) , z ∼ N ( 0 , I ) reproduces the observation distribution.
Feasibility Predictor: For each skill, we learn a feasibility predictor f k ( z t , z g ) ∈ R to determine the feasibility of reaching from o t to o g using the trajectory optimizer, where z t =
Q ( o t ) , z g =
Q ( o g ) .
For training the feasibility predictor, we obtain positive pairs by sampling ( z t 1 , z t 2 ) from the same demonstration trajectory and negative pairs by sampling pairs of observations from different trajectories.
We additionally add negative pairs ( z 1 , z 2 ) where both z 1 and z 2 are sampled from a unit Gaussian distribution in the VAE latent space.
We assign a label of 1 for positive pairs and a label of 0 for negative pairs.
We use an MSE loss L fea for model training, which was shown empirically to work better than a cross-entropy loss.
While there may be false negative pairs, we ﬁnd the feasibility predictor to perform reasonably well, as different trajectories have different initial and goal conﬁgurations and it is less likely that the state of a different conﬁguration (e.g. mass of the dough) can be achieved from the current state within one skill.
This intuition was similarly used for goal relabeling in previous work by Lin et al.
Reward Predictor: We further train a reward predictor r
( o t , o g ) ∈ R that predicts the negative of the Sinkhorn divergence between the corresponding states − D ( s t , s g ) using an MSE loss L r .
The reward predictor does not depend on any speciﬁc skill or tool.
Training We
ﬁrst pretrain the VAE and then freeze the weights.
We then jointly optimize the feasibility predictor, reward predictor and the goal conditioned policy.
2. L ONG - HORIZON P LANNING WITH S KILL A BSTRACTION
To apply the skill abstraction learned above sequentially, we need to determine 1) which skill to use at each stage; 2) what intermediate goal to specify for each skill.
Given o 0 , o g the initial and goal observations, we plan over H steps.
By using the feasibility and reward predictor, we formulate our problem as a hybrid discrete and continuous optimization problem:
[Equation]
Here, k i is the index of the tool used at step i , f is the feasibility predictor and
¯ r ( z H , z g ) = exp( − D ( z H , z g )) which can be computed from the reward predictor, and z 0 , z g are the VAE encoded latent vectors of the initial and goal observations (RGB-D image)
o 0 , o g .
The optimization variables include the discrete variables k
= k 1 , . .
, k H , representing the index of the skills to use at each step and the continuous variables z
= z 1 , . . .
, z H that are latent vectors that represent the intermediate goals.
The term ||
z
i || 22 in the constraint is proportional to the log likelihood of the latent vectors under a unit normal distribution and M is a threshold to ensure that the latent vectors correspond to actual intermediate goals in the observation space.
To optimize for both the discrete and continuous variables in Eqn. 2, we use exhaustive search over all possible combinations of the discrete variables.
For the continuous variables, we start with N initial solutions { z 1 , . . .
z H } j , j = 1 , . . .
, N and use Adam with projected gradient on the loss for all the initial solutions in parallel, since the constraint is convex.
Speciﬁcally, after each gradient update step of Adam, we project the current z i to the constraint set by setting z i =
[Equation]
Once we have solved for k 1 , z 1 , . .
, k H , z H , we can decode the latent vectors back to images o 1 , . . .
, o H =
G ( z 1 ) , . .
, G ( z H ) , and call the corresponding goal-conditioned policies sequentially: π k 1 ( o 0 , o 1 ) , . .
, π k H ( · , o H ) .
To simplify the execution, we move each tool to its initial pose at the beginning of executing each skill.
The pseudocode is shown in Algorithm 1.
Input : Trajectory optimizer,
[Table]
, planning
[Table]
H Initialize modules for
[Table]
abstraction
[Table]
, f
[Table]
, r, G, Q ;
Generate N demonstration trajectories in differentiable physics τ = { ( o 0 , a 0 , r 0 , . .
, o T , r T , o g ) } i =1 ,...,N ; Train neural skill abstraction π k , f k r
G, Q using loss L skill until convergence; for k
K
H do
Initialize
Choose do
; Decode
Execute
E XPERIMENTS
In this section, we will discuss our experimental setup, implementation details and comparison results.
3. E XPERIMENTAL SETUP
Tasks and environments We experiment with a set of sequential deformable object manipulation tasks with dough.
We build our simulation environments on top of PlasticineLab (Huang et al., 2021), a differentiable physics benchmark using the DiffTaichi system (Hu et al., 2019a) that could simulate plasticine-like objects based on the MLS-MPM algorithm
(Hu et al., 2018).
Inspired by the dumpling making process, we design three novel tasks that require long-horizon planning and usage of multiple tools:
• LiftSpread :
The agent needs to ﬁrst use a spatula (modeled as a thin surface) to lift a dough onto the cutting board and then adopt a rolling pin to roll over the dough to ﬂatten it.
The rolling pin is simulated as a 3-Dof capsule that can rotate along the long axis and the vertical axis and translate along the vertical axis to press the dough.
GatherTransport : Initially, residual of dough is scattered over the table.
First, the agent needs to gather the dough with an extended parallel gripper and place it on top of a spatula.
Then the agent
needs to use the spatula to transport the dough onto the cutting board.
The spatula can translate and rotate along the vertical plane.
The gripper can translate along the horizontal plane, rotate around its center and open or close the gripper.
• CutRearrange :
This is a three-step task.
Given an initial pile of dough, the agent needs to ﬁrst cut the dough in half using a knife.
Inspired by the recent cutting simulation (Heiden et al., 2021), we model the knife using a thin surface as the body and a prism as the blade.
Next, the agent needs to use the gripper to transport each piece of the cut dough to target locations.
A visualization of these tasks can be found in Figure 1.
For all the taks, the agent receives RGB-D image resized to 64x64 from a camera and return velocity control commands directly on the tools.
Evaluation metric We report the normalize decrease in Sinkhorn diverge computed as s ( t ) =
s 0 − s t s 0 , where s 0 , s t are the initial and current Sinkhorn divergence.
In this way, a normalized performance of 0 representing a policy that does nothing and a normalized performance of 1 representing an upper bound of a policy that perfectly match the two distributions.
The maximum normalized performance of 1 may not always be possible.
For example, due to the incompressibility of the dough, certain target shape may be too small for a large dough to ﬁt into.
As such, we additionally set a threshold on the Sinkhorn divergence for each task such that the task is assume to be completed successfully when EMD is below the threshold.
This threshold is manually picked by observing the performance gap between successful and failed trajectories.
For each task, 5 initial and target conﬁgurations are given for evaluation, which all require multi-stage manipulation of the dough.
We report both the normalized performance metric and the success rate for comparisons.
3. I MPLEMENTATION D ETAILS OF D IFF S KILL
For each task, we ﬁrst generate 1000 different initial and goal conﬁgurations, varying the initial and target shape of the dough as well as poses of the manipulators.
For each conﬁguration, we run the optimizer for each tool separately to generate trajectories of length
The Adam optimizer
We then train our VAE, policy, feasibility and score predictors over this demonstration video dataset.
These modules share the same encoder architecture: 4 convolutional layers with a kernel size ofand a stride of 2 and a channel size of (32 , 64 , 128 , 256) , followed by an MLP that maps the feature into a ﬁxed 8 dimension vector.
The VAE, feasibility and the score predictor also share the same weights for the encoder.
After training, we ﬁnd the feasibility and score predictor to perform well on the held out trajectories, achieving a L2 error of less than 0.05 for the score predictor and an accuracy of over 0.95 for the feasibility trajectory, across different environments.
We found behavior cloning to be sufﬁcient for learning short-horizon skills from the demonstration dataset.
In Table 3, we can see that the learned skills (labeled as Behavior Cloning) approach the normalized performance of the trajectory optimization (Trajectory Opt) on single-tool use, although they cannot solve the long-horizon tasks.
Given the skill abstraction, DiffSkill iterates through all skill combination.
For each skill combination, we randomly sample 1000 initial solutions for the latent vectors z 1 , . . .
, z H , and then performiterations of Adam optimization for each of them.
Since we are optimizing in the latent space, and with the help of parallel computation of GPU, this optimization can be done efﬁciently in aroundseconds for each skill combination on a single NVIDIA 2080Ti GPU.
3. B ASELINES
We compare with three strong baselines:
Model-free Reinforcement Learning (RL)
We compare with two model-free RL methods: TD3 (Fujimoto et al., 2018) and SAC (Haarnoja et al., 2018).
The RL methods use the same encoder architecture as DiffSkill and receive the negative of the cost function used for the trajectory optimizer as the reward function.
We train the RL agents with either a single tool, or with both tools where the agent controls them simultaneously.
Behavior Cloning We compare with another baseline that directly trains a goal-conditioned policy with Behavior Cloning (BC) and hindsight relabeling using all tools.
The agent is trained with the same dataset and jointly controls all tools.
Trajectory Opt (Oracle)
We compare with the trajectory optimizer used to generate the demonstration, with the same parameters.
Note that this method requires full state of the simulation and multiple forward and backward passes through the simulator during evaluation time.
Since DiffSkill sequentially apply multiple skills, we move any used tools to its initial pose after executing each skill with a manual policy.
3. R ESULT A NALYSIS
We show that DiffSkill is able to solve the challenging long-horizon, tool-use tasks from the sensory observation (RGB-D) while the baselines cannot.
The quantitative results can be found in Table 1.
Tool A refers to the spatula for LiftSpread, the parallel gripper for GatherTransport and the knife for the CutRearrange environment, while tool B refers to the rolling pin, the spatula and the gripper for each task respectively.
First, we can compare the rows for single-tool use.
All baselines are able to solve one-stage of the task, achieving a reasonable performance, if the correct tool is used (e.g. tool A for LiftSpread and
GatherTransport), although for cutting, the performance is still close to zero with cutting only, since cutting itself does not reduce the distance between the current dough and the desired dough locations.
BC can well approach the performance of the corresponding trajectory optimizer despite being a policy that only receives RGB-D input.
SAC can also solve some of the single-stage tasks such as lifting or transporting, while TD3 performs worse.
Second, with multiple tools, we can see that DiffSkill signiﬁcantly outperforms the single-skill policy.
Remarkably, DiffSkill even outperforms the trajectory optimizer that controls both tools at the same time, which uses the full simulation state during evaluation time.
This indicates that high-level planning over skills is necessary for achieving these sequential manipulation tasks.
Furthermore, we show visualization of the found solutions of DiffSkill in Figure 3.
We can see that DiffSkill is able to ﬁnd reasonable intermediate goal state such as ﬁrst putting the dough on the cutting board, or gather dough onto the spatula.
CutRearrange is shown to be a harder task, with all methods performing poorly.
This is because it requires three stages of manipulation; further, it is non-trivial to transport the dough without deforming it too much.
Still, DiffSkill is able to achieve higher success, even though the trajectory optimizer oracle achieves a higher average score.
This is because the trajectory optimizer is more reliable at ﬁnding partial solutions that transport part of the dough to the target locations but does not complete the full task.
Please see our website for visualizations of different methods
[Table]
3. A BLATION A NALYSIS
We perform two ablations on DiffSkill.
First, we try removing the planning over the discrete variables that decides which tool to use at each step.
Instead, we train a tool-independent policy, the feasibility and score predictor, where the action space is the joint-tool action space.
Then during planning, we only need to optimize for the intermediate goals.
This ablation is labeled as No Discrete Planning .
[Figure]
Second, we try to remove the planning over the continuous variables, i.e. the intermediate goals.
Without the intermediate goals, we directly use the ﬁnal target image as the goal for sequentially executing each skill.
This ablation is labeled as Direct Execution.
Since we do not have the intermediate goals anymore, we try two different ways of choosing the skills to execute at each stage:
Randomly pick one skill and an oracle that execute each combination of skills in the simulator and choose the best one in hindsight.
The results are shown in Table 2.
Without discrete planning, the policy performs poorly.
This is probably because during training, a single policy and feasibility predictor is used for learning two modes of skills that are very different and the policy is unable to differentiable for different modes or decide when to switch modes.
On the other hand, if we do not optimize for the intermediate goals, we also cannot determine which tools to use at evaluation time, since both the feasibility predictor requires intermediate goals as input.
In this case, we can see that using random skills at each stage results in poor performance.
Even if the oracle skill order is used, there is still a drop in performance as the policy may not work well given only a future goal instead of an immediate goal.
[Table]
R ELATED W ORK
Motion Planning with Differentiable Physics.
Differentiable physics models provide the gradients of the future states with respect to the initial state and the input actions.
Compared with black-box dynamics models, planning with differentiable physics models can often make more accurate updates on the action sequences and deliver better sample efﬁciency (Huang et al., 2021).
Over the past few years, researchers have built differentiable physics models from ﬁrst principles rooted in our understanding of physics for various physical systems, ranging from multi-body systems (Degrave et al., 2019; Tedrake & the Drake Development Team, 2019; de Avila Belbute-Peres et al., 2018;
Geilinger et al., 2020), articulated bodies (Werling et al., 2021; Qiao et al., 2021), cloth (Qiao et al., 2020; Liang et al., 2019), ﬂuid (Schenck & Fox, 2018), plasticine (Huang et al., 2021), to soft robots (Hu et al., 2019b;a; Du et al., 2021).
They have shown impressive performance in using the gradient to solve inverse problems like parameter identiﬁcation and control synthesis.
A complement thread of methods tried to relax the assumption that we have to know the full state and the physics equations; instead, they employ deep neural networks to learn the dynamics models directly from observation data and use the gradients from the learned models to aid motion planning or policy learning (Battaglia et al., 2016;
Chang et al., 2016; Mrowca et al., 2018; Ummenhofer et al., 2019;
Sanchez-Gonzalez et al., 2020; Pfaff et al., 2020; Sanchez-Gonzalez et al., 2018; Li et al., 2019; 2018).
Our method differs from prior works in that we use the differentiable physics model for skill abstraction and compose the learned skills for long-horizon manipulation of deformable objects.
Deformable Object Manipulation.
Deformable objects have more degrees of freedom and are typically more challenging to manipulate than rigid objects.
Extensive work has been done in this area, focusing on different types of deformable objects, including plasticine (Li et al., 2018;
Huang et al., 2021), ﬂuid (Li et al., 2021), cloth (Maitin-Shepard et al., 2010; Lin et al., 2021; Weng et al., 2021; Ha & Song, 2021; Wu et al., 2019; Yan et al., 2020; Ganapathi et al., 2020), rope (Nair et al., 2017; Sundaresan et al., 2020), and object piles (Suh & Tedrake, 2020).
People have also come up with standard benchmarks to establish a fairer comparison between various algorithms (Lin et al., 2020).
Our method aims to manipulate dough using tools similar to how humans would do in a kitchen environment (Figure 1).
There are also a series of works on tool-using for object manipulation (Toussaint et al., 2018; Qin et al., 2020; Fang et al., 2020; Xie et al., 2019), but most of them focus on rigid objects, whereas we take a step further and tackle deformable objects.
Solving Long Horizon Tasks.
Our work aims to solve long-horizon manipulation tasks; thus, it is also closely related to task and motion planning (TAMP) that contains elements of discrete task planning and continuous motion planning.
(Gravot et al., 2005; Kaelbling & Lozano-Pérez, 2010; 2013; Toussaint et al., 2018; Garrett et al., 2021).
However, most TAMP approaches assume a fully speciﬁed state space, dynamics model as well as a set of pre-deﬁned skills such as grasping, pushing, or placing (Toussaint et al., 2018).
Differing from prior works, our method learns a policy over
RGB-D inputs and generates motion trajectories and skill abstractions by applying gradient-based trajectory optimization techniques using a differentiable simulator.
Our feasibility predictor also relates to previous works that plan over the temporal abstraction of options (Sutton et al., 1999) or skills.
In order to do planning, these approaches deﬁne a multi-time model (Precup & Sutton, 1997) or equivalently a skill effect model (Kaelbling & Lozano-Pérez, 2017; Liang et al., 2021) to model the end state after executing a skill.
In contrast, we model such dynamics implicitly by predicting the feasibility between two latent vectors which allows direct optimization over the sub-goals in a latent space.
The most similar to ours is (Nasiriany et al., 2019), which learns a value function as the implicit dynamics.
Our method differs from this work by learning skills from a trajectory optimizer instead of using RL.
Additionally, we encode multiple skills in different neural networks and perform discrete optimization over the skills for planning.
C ONCLUSIONS
In this paper, we propose DiffSkill, a novel framework for learning skill abstraction from differentiable physics and compose them to solve long-horizontal deformable object manipulations tasks from sensory observation.
We evaluate our model on a series of challenging tasks for sequential dough manipulation using different tools and demonstrate that it outperforms both reinforcement learning and standalone differentiable physics solver.
We hope our work will be a ﬁrst step towards more common application of differentiable simulators beyond solving short-horizon tasks.
There are a few interesting directions for future work.
First, currently DiffSkill uses exhaustive search for planning over the discrete space.
As the planning horizon and the number of skills grow larger for more complex tasks, exhaustive search quickly becomes infeasible.
An interesting direction is to incorporate a heuristic policy or value function for more efﬁcient planning.
Second, similar to many other data-driven methods, while neural skill abstraction gives good prediction results on region where a lot of data are available, it performs worse when tested on situations that are more different from training.
This can be remedied by either collecting more diverse training data in simulation, for example, under an online reinforcement learning framework, or by using a more structured representation beyond RGBD images, such as using an object-centric representation.
Third, we hope to extend our current results to the real world, by using a more transferrable representation such as just a depth map or a point-cloud representation.
Finally, we hope to see DiffSkill be applied to other similar tasks, such as those related to cloth manipulation.
A CKNOWLEDGMENTS
We thank Sizhe Li for the initial implementation of the CutRearrange environment.
This material is based upon work supported by the National Science Foundation under Grant No. IIS-1849154,
IIS-2046491, LG Electronics, MIT-IBM Watson AI Lab and its member company Nexplore, ONR
MURI (N00014-13-1-0333), DARPA Machine Common Sense program, ONR (N00014-18-1-2847) and MERL.
A I MPLEMENTATION D ETAILS
A list of the hyperparameters used can be found in Table 3.
[Table]
B C OMPARISON WITH MODEL - FREE RL ON SINGLE - TOOL TASKS
In this work
[Table]
we focus on solving long-horizon multi-tool tasks.
But our proposed method is not limitied to the multi-tool setup.
For the single-tool task, or more speciﬁcally the single-skill task, our method can be directly applied without planning over the discrete space of which tool to use.
To show this, we show results on two single-tool, single-stage tasks:
Lift and Spread
[Table]
which corresponds to the two sub-tasks in LiftSpread
[Table]
but with a different initial and target dough shapes.
For both environments, only one tool can be used: the spatula for Lift and the rolling pin for Spread.
The results are shown in Table 4.
As these are two simpler tasks, DiffSkill can solve both tasks.
SAC can also solve the simpler lift task
[Table]
but has some trouble learning the spread task.
Visualization of both methods on these environments can be found on our website
[Table]