{'fraction_non_alphanumeric': 0.027536054255014913, 'fraction_numerical': 0.00829350002042734, 'mean_word_length': 4.77311320754717, 'pattern_counts': {'":': 0, '<': 0, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
EDO-Net: Learning Elastic Properties of Deformable Objects from Graph Dynamics

We study the problem of learning graph dynamics of deformable objects which generalize to unknown physical properties. In particular, we leverage a latent representation of elastic physical properties of cloth-like deformable objects which we explore through a pulling interaction. We propose EDO-Net (Elastic Deformable Object - Net), a model trained in a self-supervised fashion on a large variety of samples with different elastic properties. EDO-Net jointly learns an adaptation module, responsible for extracting a latent representation of the physical properties of the object, and a forward-dynamics module, which leverages the latent representation to predict future states of cloth-like objects, represented as graphs. We evaluate EDO-Net both in simulation and real world, assessing its capabilities of: 1) generalizing to unknown physical properties of cloth-like deformable objects, 2) transferring the learned representation to new downstream tasks.


I. INTRODUCTION
Manipulation of deformable objects is a fundamental skill toward folding clothes, assistive dressing, wrapping or packaging [1], [2], [3], [4]. In unstructured environments, variations in physical properties such as mass, friction, density or elasticity influences the dynamics of the manipulation [5], [6]. Modelling, learning and transferring skills considering deformable objects remain open challenges in robotics [7] and are due to two key factors: i) the state of deformable objects is high dimensional and difficult to represent canonically; ii) the interaction dynamics are often non-linear and influenced by the objects' physical properties usually not known a-priori [8].
To address i), analytical models often employ particlebased representations such as graphs, commonly extracted from point clouds [9], [10], [11]. Recent advances in Graph Neural Network (GNN) research have shown promising results in learning complex physical systems [12], [13], [14]. However, current methods assume that the physical properties are known a-priori, which may not hold when it comes to robots operating in human environments, requiring to address problem ii). The field of intuitive physics [15] tackles this challenge by learning predictive models which distill knowledge about the physical properties from past experience and interaction observations [16]. This line of research has so far focused mostly on rigid objects, but recent advances of data-driven techniques for deformable objects Fig. 1: A pulling interaction is leveraged by EDO-Net to explore the elastic properties of the object, which improves performance in subsequent task such as partial bandage. manipulation suggest that interactions such as whipping or pulling may be relevant to learn an intuitive physics model of deformable objects [8], [17].
In this paper, we study the problem of learning graph dynamics of deformable objects that generalize to objects with unknown physical properties. In particular, we focus on elastic properties of cloth-like deformable objects, such as textiles, which we explore through a pulling interaction (Fig. 1). We propose EDO-Net (Elastic Deformable Object -Net), a model trained in a self-supervised fashion on a large variety of samples with different elastic properties. EDO-Net jointly learns an adaptation module, responsible for extracting a latent representation of the physical properties of the object, and a forward-dynamics module, which leverages the latent representation to predict future states, represented as graphs.
We evaluate our approach both in simulation and in the real world, showing how EDO-Net accurately predicts the future states of a deformable object. We also validate the quality of the learned representation by retrieving the ground truth physical properties from the simulation environment using a weak learner. In summary, our contributions are: graph dynamics; • We propose a procedure to train our model on a large variety of samples with different elastic properties, enabling generalization to objects with unknown physical properties; • We conduct extensive evaluations, both in simulation and in the real world, of the quality of the latent representation and of the dynamics prediction.

II. RELATED WORK
We discuss the related work from the perspective of learning physical properties, as well as data-driven strategies to learn representations and dynamics of deformable objects. Learning physical properties: a common approach to extract physical properties like mass, moment of inertia or friction coefficients is to use different exploratory actions such as pushing, tilting or shaking [6], [18], [5]. In [6] mass and friction of rigid objects are learned through tactile exploration. Similarly, [19], [5] use a multi-step framework to encode rigid objects physical properties from pushing tasks using dense pixels representations. Related to deformable objects, in [20] the authors propose how to predict properties of clothlike objects to perform real2sim, learning to align real world and simulated behaviors through a differentiable simulator. In contrast to [20], we want to learn a representation of physical properties without relying on simulated behaviors and elastic parameters.
Representations and dynamics of deformable objects: regarding the challenge of finding canonical representations of deformable objects, an approach is to encode their high dimensional observations in structured latent spaces to perform planning and control there. An example is [21], where the authors use contrastive learning on image observations to separate different states in the latent space to learn how to manipulate deformable objects such as clothes and ropes. Similarly, in [22], [23], image observations are mapped in a latent space represented as a graph, where similar observations are mapped to the same nodes, allowing to perform visual action planning to solve a folding task with clothes. G-Doom [11], instead, relies on a graph representation to learn cloth-like deformable objects dynamics directly using GNNs. VCD [10] is a cloth dynamics model based on particle representations and connectivity structure of the visible portion of the cloth which addresses the challenge of partial observations. DiffSRL [24] proposes to introduce a physics prior relying on a differentiable simulator to better capture the complex dynamics models of deformable objects. None of these works, however, focus on learning graph dynamics across a wide range of physical properties of deformable objects. To the best of our knowledge, this is the first work to propose a method that explicitly trains a graph dynamics model to generalize to unknown physical properties of clothlike deformable objects.

III. PROBLEM FORMULATION
In our formulation, we refer to the object's elastic properties as T i ∼ T , where T is the distribution of all possible physical properties. We explore T i by collecting a sequence of observations O i through an Exploratory Action (EA) [5], [6]. An adaptation module is responsible for extracting a latent representation z i of the physical properties T i from the observations O i , which can be subsequently leveraged by a forward dynamics module to generalize its predictions across different T i ∼ T . We define the state of a deformable object with physical properties T i as a graph G i = (V i , E i ) with nodes v ∈ V i and edges e ∈ E i . The features of the node v describe the 3D Cartesian position of the nodes, while the features of the edge e characterize the interaction properties among nodes.
Given these, the aim of EDO-Net is to learn a graph dynamics model of cloth-like deformable objects g θ conditioned on a latent representation z i of the underlying physical properties T i of the deformable object and the robot control action a t : The latent representation z i can be obtained through a learned function f φ that takes as input sequence of observations O i and an initialization z 0 of the representation: where the initialization z 0 is learned together with the model's parameters θ and φ. In what follows, we will describe in detail the method to implement and train the graph dynamics g θ and adaptation functions f φ , respectively.

IV. METHOD
An overview of the proposed EDO-Net is shown in Fig. 2. In particular, for each deformable object with unknown physical properties T i , the robot has to adapt the initialization z 0 by using a sequence of exploratory observations O i . From O i , the adaptation module f φ first extracts a latent representation z i of the physical properties T i . The extracted representation z i is subsequently used in the forward dynamics module g θ to obtain accurate predictions of the future states of T i conditioned on different interactions a t .
We assume that the state G i t of the deformable object with physical properties T i is directly observable, which, in realworld applications, can be extracted from observations such as point clouds [11], [10]. We focus on the scenario where the physical properties T i are not directly observable from the initial state of the object.

A. Exploratory Action and Adaptation
To collect information about the physical properties T i , the robot needs to observe the response of the object during a dynamic interaction. To this end, we evaluate a pulling interaction shown in Fig. 3, where a two-arm robotic manipulator grasping a deformable object from its edges exerts tension stress on the object by pulling its edges along opposite directions, similarly to what is done in [17]. During the pulling Exploratory Action (EA), we record a set of T observations ..,T processed by an attention layer and a RNN. In a second phase, the forward dynamics module g θ , implemented as a GNN, uses z i obtained from the adaptation module to predict future statesĜ t of the deformable object.
the robot sensors at time t. The information contained in O i about the physical properties T i is subsequently input to the learned function f φ to update the initialization z 0 . The implementation of the adaptation function f φ is the following: for each observation We subsequently obtain an estimateẑ t i ∈ R p of z i from o i t by learning a node's aggregation function through an attention layer, which aggregates the nodes as [25]: where α n is the attention weight of the node n. For details about the implementation of the attention mechanism, we refer the reader to [26]. The set ofẑ t i | t=1,..,T is used to obtain the latent representation z i ∈ R p by recursively updating the initial belief z 0 through a Recurrent Neural Network (RNN), yielding the following update rule:

B. Forward Dynamics Module
We model the forward graph dynamics g θ with a GNN conditioned on the latent representation z i of the physical properties T i . We trained g θ to predict state differences δG i t receiving as input the control action of the robotic manipulator a t , and the initial state of the object G i t . We integrate z i as features of the edges of the input graph as shown in the input processing block in Fig. 2. We use MLPs to encode nodes and edges before propagating the information among the nodes using a standard M-step message passing GNN with the following update rule [27]: where Ψ and Φ are the learned message and update functions, and N 1 v and N 2 v are the sets of 1st and 2nd order neighbors of the node v ∈ V i . To decrease the number of steps needed to propagate the information along the graph, we parallelize the computation of 1st and 2nd order neighbors as suggested in prior work [28]. Finally, the M -th hidden nodes are passed through a decoder MLP to the prediction of the graph displacement δĜ i t .

C. Self-Supervised Loss
The overall model can be learned using a dataset of exploratory observations D O = {D O i } Ti∼T and a dataset of interactions D = {D i } Ti∼T . The parameters φ, θ and the initialization z 0 can be optimized using a loss on the prediction of the state difference δĜ i t obtained from g θ for each training sample with physical properties T i ∼ T . The loss function L can be defined as follows: where , and d is a distance measure, Mean-Squared Error (MSE), between the ground truth state displacement of the deformable object and the model's prediction. Equation 6 optimizes the parameters θ to learn a forward dynamic model conditioned on different representations z i of physical properties T i , implicitly driving the parameters φ to learn to encode z i of different samples without supervision from ground truth labels of the physical parameters. Moreover, training across multiple T i ∼ T enforces the model to learn how to generalize to deformable objects with unknown physical properties.

V. ENVIRONMENT AND IMPLEMENTATION DETAILS
In this section, we introduce the simulated and real-world environments designed to evaluate the proposed method, along with its implementation and training details.

A. Environments Setup
For the simulation experiments, we use Pybullet [29], [30]. In it, we create the two environments displayed in Fig. 4a and Fig. 4b, both of which include two free-floating Franka-Emika Panda end-effectors equipped with Force/Torque sensors. In the first environment, called Lifting, the robot lifts a sphere located on a cloth-like deformable object from an initial resting position on the table to a predefined height, by applying a displacement control action a t ∈ [0, D max ]. In the second environment, called Partial Bandage, the robot holds and pulls the cloth downward over a human arm, applying a force control action a t ∈ [0, F max ]. For both environments, we uniformly discretize the action intervals into 30 instances with fixed step size, while the pulling EA is implemented as shown in Fig. 3.
We extract the graph G i t and force F i t observations at each time step of the simulation. We downsample the graph to a grid of 8×8 nodes. Furthermore, we smooth the force profiles using a Savitzky-Golay filter [31] with a window size of 21 and a third-grade polynomial.
We generate a large variety of physical properties of the cloth by varying both the stiffness and the bending parameters of the simulator. We empirically selected the elasticity parameters in the range [10, 45] with a step size of 3.0, and the bending parameters in the range [0.01, 5.01] with a step size of 0.5, for a total of 143 unique elastic deformable objects.
We replicate the Partial Bandage simulation environment in the real world as visible in Fig. 4c. We collect the pulling EA and the interaction trajectories on 40 different textile samples with different elastic properties where the dataset characteristics correspond to the one in prior work [32]. The real-world dataset and the graph extraction procedure are shown in Fig. 5.

B. Network Architecture and Training details
We used an MLP with one hidden layer of size 32 to implement the node encoder of the adaptation module, while the attention layer is implemented as a learned linear projection from the encoded node o v ∈ R 32 to the attention value α v ∈ R. The RNN architecture has one hidden state which starts with initialization z 0 ∈ R p and outputs z i ∈ R p as its last hidden state [33], where p = 32. Hyperparameters were chosen empirically based on the highest overall performance across the evaluations. Regarding the forward model, we propagate the information for M = 4 steps, while we implement the node's encoder, the final linear projection, and the message and the aggregation functions as MLPs with one hidden layer of size 32. We use ReLU as non-linearity for all the modules except the RNN, where we used tanh as the activation function. The models are trained on the datasets normalized to zero mean and unit variance for 5K epochs and batch size equal to 8. We used Adam [34] with a learning rate of 10 −3 and weight decay equal to 10 −5 . The simulation dataset consists of 30 datapoints for each of the 143 unique samples for Lifting, Partial Bandage and the pulling EA. We split the 143 samples into a train (80%), validation (10%), and test (10%) samples, using the validation set to select the best-performing model during training. In the real world, instead, the dataset consists of 30 datapoints for each of the 40 unique samples for the Partial Bandage and the pulling EA. We split the 40 samples into a training (80%) and test samples (20%).

VI. EXPERIMENTS
In this section we evaluate the performance of EDO-Net, regarding its adaptation module f φ , forward module g θ and its generalisation capabilities. To this aim, we design the following experiments: 1) We examine how accurately we can decode physical properties from the latent representation z i by learning to predict ground-truth parameters from z i in simulation; 2) We quantitatively evaluate whether the latent representation z i transfers between environments (from Partial Bandage to Lifting) or to different downstream tasks, such as learning an inverse model to predict the control action between two states in simulation; 3) We analyse the generalization capabilities of EDO-Net both in simulation and real-world environments, testing the model over a set of deformable objects with unseen elastic physical properties T i ∼ T . We compare EDO-Net with a Non-Conditioned (NC) baseline model, which trains the forward model g θ without conditioning on z i . We also consider an ablation of EDO-Net trained on a single exploratory observation, rather than a sequence of interactions, which we denote by EDO1. Moreover, we additionally consider three oracle models in simulation to set an upper-bound performance for the tasks: two Oracle models conditioned on the ground-truth simulation parameters, respectively (OI) and (OF) for inverse and forward dynamics models, and an Oracle Supervised forward model (OS), trained with an additional supervised loss term over z i , to directly predict the ground-truth simulation parameters during the training procedure.

A. Decoding Physical Properties
The aim of this section is two-fold: 1) to evaluate whether it is possible to decode from the latent representation z i the ground truth physical properties T i of the deformable object, and 2) to analyse the influence of the length T of the sequence of exploratory observations used to extract z i . In particular, we train an MLP with 3 hidden layers of size 64 and ReLU non-linearities which takes as input the learned representation z i to predict the bending and elastic parameters of the simulator. We evaluate the predicted physical parameters in both the Partial Bandage and Lifting environments by evaluating the MSE between the ground truth normalized physical parameters and the model predictions. We distinguish between seen and unseen physical properties depending on whether T i ∼ T was used to train the model or not. Fig. 6 shows the prediction results of the physical parameters from the learned z i while varying the number T of exploratory observation O i used to extract the representation. It can be noticed how increasing the number of observations improves the quality of the latent representation of the physical properties learned by f φ , highlighting the relevance of using a sequence of dynamic interactions to encode physical properties. Moreover, the performance of EDO-Net is close to OS, suggesting that the self-supervised loss implicitly trains the model to learn a latent representation of the physical properties without explicit supervision from the ground truth labels.

B. Evaluation of the Adaptation Module f φ
In this section, we further evaluate z i by answering the following questions: can we 1) transfer z i to efficiently learn forward models of different environments, and 2) transfer z i to efficiently learn new downstream tasks, such as inverse dynamics prediction? To address these questions we pretrain EDO-Net on the Partial Bandage environment and designed the following scenarios: 1) Bandage2Lifting: we fine-tune the forward dynamics model g θ on the Lifting environment, while keeping the weights of f φ fixed; 2) Inverse Dynamics: we train an inverse dynamics model g θ conditioned on z i in the Partial Bandage environment to predict the control action a t i between the initial state of the deformable object G i 0 and the next state G i t while keeping the weights of f φ fixed. In the Bandage2Lifting scenario, we evaluate the performance of the fine-tuned model by computing the MSE between the state-differences δĜ t+1 i (in normalized units) and the ground-truth δG t+1 i of the Lifting environment for deformable objects with physical properties T i ∼ T unseen during training. For the Inverse Dynamics scenario, we implement g θ by initially encoding graph nodes and physical properties z i with an MLP, subsequently projecting their concatenation to a latent space of the same dimensionality of the action. We finally aggregate and average the projections to obtain the predicted action. The performance of the inverse model is evaluated by computing the MSE between the normalized versions of the predicted actionâ t i and the ground-truth action a t i . For both scenarios, we compare the model performance with the NC baseline, and EDO1. For the Bandage2Lif ting scenario we set as reference performances EDO-Net model trained directly on the Lifting environment (EDO(L)-Net) and OF, while for the Inverse Dynamics scenario we set as reference performances OS and OI. The results are presented in Table I. We observe in the Bandage2Lifting scenario that all the evaluated models outperform the NC baseline, indicating that the representation z i learned in the Partial Bandage environment carries relevant information for the Lifting one. For the Inverse Dynamics scenario, instead, we observe that EDO-Net outperforms all the other baseline methods. These results suggest that our latent representation transfers to different environments and downstream tasks.

C. Generalization to Unseen Physical Properties
In this section, we evaluate the generalisation capabilities of EDO-Net. We consider both simulation and real-world environments, and we perform quantitative and qualitative tests of the model over a set of deformable objects with elastic physical properties T i ∼ T unseen during training. We evaluated the model performance by computing the MSE of the model's predictions with respect to the ground truth for each testing sample. We compare the performance of our model with respect to the NC and the EDO1 baselines. In simulation we also compare to OS and OF. In Table II we report the mean and standard deviation of the MSEs evaluated across all the testing samples with physical properties T i ∼ T . In all scenarios, EDO-Net outperforms the baseline models both in terms of the average error and the standard deviation across samples with different elastic properties. The high standard deviation of the NC model is due to the large difference between the average elastic behavior and the extreme (rigid/elastic) ones. Moreover, EDO-Net achieves comparable performances with respect to OF. Qualitative visualizations of the relevance of our proposed method for both simulation and real-world environment are shown in Fig. 7. We can observe how the NC baseline does not distinguish among samples with different physical properties (T 1 and T 2 ), hindering its capability of predicting the outcome of the robot control actions. On the other hand, EDO-Net successfully leverages the latent representations (z 1 and z 2 ) provided by the adaptation module f φ . VII. CONCLUSIONS We presented EDO-Net, a data-driven model to jointly learn a latent representation of physical properties of clothlike deformable objects which is capable to generalize to unseen physical properties. We assessed in simulation that it is possible to decode ground truth parameters from the learned representation, as well as transfer it to different environments. Furthermore, we assessed both in simulation and real world how conditioning to the latent representation z i helps the forward dynamics model in generalizing over unseen physical properties. The latent representation learned from EDO-Net is relevant for robotics tasks to generalize manipulation skills to a wide variety of cloth-like objects. Moreover, extending the framework to multiple exploration actions could enable learning physical properties beyond elasticity.