Various techniques have been proposed to enable robots to perform various tasks. For example, some techniques enable a user to kinesthetically teach the robot to follow a particular trajectory. For instance, the user may physically manipulate a robot arm to cause a reference point of an end effector of the robot arm to traverse the particular trajectory—and that particular traversed trajectory may thereafter be repeatable by the robot arm. As another example, while a user uses his or her arm to perform a task like moving to and grasping an object, a camera or other device may obtain visual samples of the movement to determine a trajectory of a reference point of the user's arm, which may then be repeated by a robot arm. However, those and other techniques may suffer from one or more drawbacks, such as those described herein.
The classical way to record a particular trajectory is to generate a time-indexed trajectory, e.g., of individual waypoints. This recorded trajectory can be used as a robot control policy. Whatever the starting point of the end effector reference point, the policy may cause the robot to identify the closest individual waypoint of the time-indexed trajectory, move the end effector reference point to that way point, and then move it along the remainder of the trajectory. However, this technique may not yield optimal results in terms of time required to traverse the trajectory and/or robot wear and tear. Moreover, a robot operating in accordance with such a simple control policy may not be well-suited to deal with dynamic obstacles in the environment.
In contrast to the approaches described previously which formulate a task using a time-indexed trajectory, in a dynamical systems approach to feedback control, robot motion during a task (for example reaching a cup) is formulated as a differential equation. Such a representation allows better generalization since instead of memorizing the demonstration trajectories, the policy has to capture the essential dynamics underlying the task during training. Additionally, a dynamical systems policy can, by construction, adapt to changes in dynamic environments, making it suitable for use in unstructured environments.
Implementations are described herein for using contraction theory and semidefinite programming to generate, from a set of data points generated during a demonstration, a dynamical systems control policy that regulates both robot motion and robot interaction with an environment. In various implementations, the dynamical systems control policy, which may include and/or take the form of a polynomial contracting vector field (referred to herein as “CVF-P” in some instances), is provably optimal for the problem of minimizing imitation loss while providing continuous-time guarantees on the induced imitation behavior. Techniques described herein facilitate real-time adaptation to dynamic obstacles during execution, with convergence to demonstrated behavior within a well-defined safety tube.
In some implementations, a set of data points sampled during demonstration-based learning of a robot trajectory (also referred to as “imitation learning” or “kinesthetic teaching”) is used to calculate a continuous function that corresponds to (e.g., approximates or fits) the trajectory. A polynomial vector field may then be fitted to the continuous function. In some implementations, a neighborhood space that contains the set of data points may be constrained into a contracting region, such as a tube around the robot trajectory. Notably, rather than using optimization techniques such as regression analysis or stochastic gradient descent, in various implementations, semidefinite programming may be employed. In various implementations, it is possible to use semidefinite programming for which a sum-of-squares relaxation yields a globally-optimal solution. Consequently, it is possible to calculate a globally-optimal polynomial vector that has the lowest imitation loss among all polynomial vector fields of a given degree.
To enable obstacle avoidance, in some implementations, an inverse kinematic mapping, “IK,” is calculated that maps a position in Cartesian space to a subset of joint space that contains all possible joint configurations that would cause any part of a robot (particularly a robot arm) to occupy the position in Cartesian space. For example, in some implementations, sensor data indicative of a position of obstacle in Cartesian space, such as a point cloud generated by a 3D or 2.5D vision sensor, may be used to calculate a position of the obstacle in joint space. Based on the position of the obstacle in joint space, a repulsive polynomial vector field may be generated for the obstacle. The polynomial vector field of the dynamical systems control policy may then be modulated based on the repulsive polynomial vector field for the object, e.g., by adding the fields together.
In some implementations, the position of the obstacle in joint space may be determined based on a mapping from Cartesian space to joint space. This mapping may be generated, for instance, by discretizing the joint space of the robot into a plurality of discrete positions (e.g., hundreds of thousands). In some implementations, this may include regularly sampling each joint of the robot from a minimum angle to a maximum angle using a predetermined step size, e.g., of 0.1 radians. The robot may then be voxelized at each of the plurality of discrete positions, e.g., using a robot simulation program, to generate a mapping from joint space to Cartesian space. The mapping from Cartesian space to joint space may be calculated an inverse of the mapping from joint space to Cartesian space.
In various implementations, a method may be implemented using one or more processors and may include: receiving a set of data points generated based on sensor data from one or more sensors obtained during imitation learning of a robot trajectory, wherein the imitation learning includes physical manipulation of a reference point from an initial point to a target point; generating a dynamical systems control policy that regulates both robot motion and robot interaction with an environment, wherein generating the dynamical systems control policy comprises: based on the set of data points, calculating a continuous function that corresponds to the robot trajectory, and fitting a polynomial vector field to the continuous function using semidefinite programming, wherein the dynamical systems control policy comprises the polynomial vector field; and controlling a robot based on the dynamical systems control policy.
In various implementations, the method may include constraining a neighborhood space that contains the set of data points into a contracting region. In various implementations, the contracting region comprises a tube around the robot trajectory.
In various implementations, the method may further include: receiving sensor data indicative of a position of obstacle in Cartesian space; determining a position of the obstacle in joint space based on the position of the obstacle in Cartesian space; based on the position of the obstacle in joint space, generating a repulsive polynomial vector field for the obstacle; and modulating the polynomial vector field of the dynamical systems control policy based on the repulsive polynomial vector field for the obstacle. In various implementations, the position of the obstacle in joint space is determined based on a mapping from Cartesian space to joint space.
In various implementations, the mapping may be generated by: discretizing the joint space of the robot into a plurality of discrete positions; voxelizing the robot at each of the plurality of discrete positions to generate a mapping from joint space to Cartesian space; and calculating the mapping from Cartesian space to joint space as an inverse of the mapping from joint space to Cartesian space. In various implementations, the discretizing may include regularly sampling each joint of the robot from a minimum angle to a maximum angle using a predetermined step size.
In addition, some implementations include one or more processors of one or more computing devices, where the one or more processors are operable to execute instructions stored in associated memory, and where the instructions are configured to cause performance of any of the aforementioned methods. Some implementations also include one or more transitory and/or non-transitory computer readable storage media storing computer instructions executable by one or more processors to perform any of the aforementioned methods.
It should be appreciated that all combinations of the foregoing concepts and additional concepts described in greater detail herein are contemplated as being part of the subject matter disclosed herein. For example, all combinations of claimed subject matter appearing at the end of this disclosure are contemplated as being part of the subject matter disclosed herein.
During a kinesthetic teaching/physical manipulation by a user of one of the robot(s) 180, sensor data is generated by the robot. The sensor data is provided to the control policy system 120. The control policy system 120 generates a group of data points based on the sensor data of the kinesthetic teaching and uses the group of data points in generating a control policy using various techniques described herein. The control policy is provided for use by one or more of the robot(s) 180 (the same robot of the kinesthetic teaching and/or additional robot(s)). Such robot(s) 180 use the control policy to selectively control one or more of its actuators based on the control policy. For example, the control policy may be invoked by such robot(s) 180 in response to detection of an object associated with the control policy, a task associated with the control policy, etc.—and used by the robot in regulating both motion and interaction with the environment.
The control policy system 120 includes a data engine 122 and a learning engine 124. In some implementations, more or fewer engines may be provided. In some implementations, the data engine 122 samples a distributed group of data points and provides them to learning engine 124 for use in generating a control policy. In some implementations, the data engine 122 additionally or alternatively automatically generates a potential gradient for a group of data points, assigns the potential gradient to the data points of the group, and provides the assigned potential gradient to learning engine 124 for use in generating a control policy. The learning engine 124 generates a control policy using one or more groups of data points that are each based on robot sensor data from a corresponding kinesthetic teaching.
The trajectory 201 of
Although not illustrated, robot 280A may also include and/or be in communication with one or more user interface input devices, such as a button or other user interface element located on an exterior surface of the robot 280A, a virtual user interface element provided via a tablet or other computing device in communication with the robot 280A, and/or a microphone included with the robot 280A and/or in communication with the robot. In some of those implementations a user may provide user interface input via the user interface element to, for example: indicate the initiation and/or conclusion of a demonstration.
Although a particular robot 280A is illustrated in
And while manual training of a robot arm is demonstrated in
Operational components 304a-n may include, for example, one or more end effectors (e.g., grasping end effectors) and/or one or more servo motors or other actuators to effectuate movement of one or more components of the robot. For example, the robot 300 may have multiple degrees of freedom and each of the actuators may control actuation of the robot 300 within one or more of the degrees of freedom responsive to control commands provided by the robot control system 302 (e.g., torque and/or other commands generated based on a control policy). As used herein, the term “actuator” encompasses a mechanical or electrical device that creates motion (e.g., a motor), in addition to any driver(s) that may be associated with the actuator and that translate received control commands into one or more signals for driving the actuator. Accordingly, providing a control command to an actuator may comprise providing the control command to a driver that translates the control command into appropriate signals for driving an electrical or mechanical device to create desired motion.
The robot control system 302 may be implemented in one or more processors, such as a CPU, GPU, and/or other controller(s) of the robot 300. In some implementations, the robot 300 may comprise a “brain box” that may include all or aspects of the control system 302. For example, the brain box may provide real time bursts of data to the operational components 304a-n, with each of the real time bursts comprising a set of one or more control commands that dictate, inter alia, the parameters of motion (if any) for each of one or more of the operational components 304a-n. As described herein, the control commands can be at least selectively generated by the control system 302 based on a control policy generated according to one or more techniques disclosed herein.
Although control system 302 is illustrated in
User interface input devices 422 may include a keyboard, pointing devices such as a mouse, trackball, touchpad, or graphics tablet, a scanner, a touchscreen incorporated into the display, audio input devices such as voice recognition systems, microphones, and/or other types of input devices. In general, use of the term “input device” is intended to include all possible types of devices and ways to input information into the computing system 410 or onto a communication network.
User interface output devices 420 may include a display subsystem, a printer, a fax machine, or non-visual displays such as audio output devices. The display subsystem may include a cathode ray tube (CRT), a flat-panel device such as a liquid crystal display (LCD), a projection device, or some other mechanism for creating a visible image. The display subsystem may also provide non-visual display such as via audio output devices. In general, use of the term “output device” is intended to include all possible types of devices and ways to output information from the computing system 410 to the user or to another machine or computing device.
Storage subsystem 424 stores programming and data constructs that provide the functionality of some or all of the modules and methods (e.g., method 700 of
These software modules are generally executed by processor 414 alone or in combination with other processors. Memory 425 used in the storage subsystem 424 can include a number of memories including a main random access memory (RAM) 430 for storage of instructions and data during program execution and a read only memory (ROM) 432 in which fixed instructions are stored. A file storage subsystem 426 can provide persistent storage for program and data files, and may include a hard disk drive, a floppy disk drive along with associated removable media, a CD-ROM drive, an optical drive, or removable media cartridges. The modules implementing the functionality of certain implementations may be stored by file storage subsystem 426 in the storage subsystem 424, or in other machines accessible by the processor(s) 414.
Bus subsystem 412 provides a mechanism for letting the various components and subsystems of the computing system 410 communicate with each other as intended. Although bus subsystem 412 is shown schematically as a single bus, alternative implementations of the bus subsystem may use multiple busses.
The computing system 410 can be of varying types including a workstation, server, computing cluster, blade server, server farm, or any other data processing system or computing device. Due to the ever-changing nature of computers and networks, the description of the computing system 410 depicted in
Learning-from-demonstrations (“LfD”) or imitation learning involves inference of a dynamical systems control policy from a relatively small number of demonstrations. Such a dynamical systems control policy can then bootstrap data-efficient reinforcement learning for challenging tasks. With imitation learning, in some cases, the demonstrator (e.g., a robot technician) attempts to ensure that the robot's motions capture the relevant semantics of the task rather than requiring the robot to understand the semantics. The learned dynamical systems control policy may take over operation of the robot, e.g., from a teleoperator, and enable the robot to repeatedly execute the desired task even in dynamically changing conditions. For example, the origin of a picking task and the goal of a placing task may dynamically shift to configurations unseen during training, and dynamic obstacles may be encountered during execution. Dynamic obstacles are particularly relevant in collaborative human-robot workspaces where safety guarantees are paramount. In such situations, when faced with an obstacle, the robot can no longer follow the demonstration path anymore and should re-compute a new motion trajectory in real-time to avoid collision and still attempt to accomplish the desired task.
In some implementations, such real-time adaptation can be achieved by associating demonstrations with a dynamical system. In some implementations, a vector field may be generated that defines a closed-loop velocity dynamical systems control policy. From any state that the robot finds itself in, the vector field may be used to steer the robot back towards the desired imitation behavior, without the need for path re-planning using conventional approaches. One advantage of the learned vector field is that it can be modulated in real-time in order to avoid collisions with obstacles.
In general, the problem of imitation learning of a dynamical system, {dot over (x)}=f (x)) from samples (x, {dot over (x)}) can be solved as a regression problem: minimize imitation loss Σi,t∥(x(i)(t))−Σi,t∥(x(i)(t))−{dot over (x)}(i)(t)∥22 over a suitable family of vector valued maps, f∈. However, a naive supervised regression approach may be inadequate. In
Accordingly, implementations described herein are usable to formulate a continuous time optimization problem over vector fields involving an imitation loss, subject to a constraint that turns the neighborhood of demonstrations into contracting regions. Within this region, all trajectories are guaranteed to coalesce towards the demonstration exponentially fast. As will be explained herein, such a formulation leads to an instance of time-varying semidefinite programming for which a sum-of-squares (“SOS”) relaxation is exact. Hence, techniques described herein are able to find the globally optimal polynomial vector field that has the lowest imitation loss among all polynomial vector fields of a given degree that are contracting on a region around the demonstrations in continuous time.
Implementations described herein may be used to estimate an unknown continuous time autonomous dynamical system:
{dot over (x)}=freal(x), (1)
where freal:n→n is an unknown continuously differentiable function.
To implement techniques described herein, one more sample trajectories may be accessed: x(i):[0, T]n that satisfy {dot over (x)}(i)=freal(x(i))∀t∈[0, T], where T>0 and i=1, . . . , M. These trajectories (x(i), i=1 . . . . , M) may be used as training data, with a goal to search for an approximation of the vector field freal in a class of functions of interest that reproduces trajectories as close as possible to the one observed during training. In other words, techniques described herein seek to solve the following continuous time least squares optimization problem (“LSP”):
In addition to consistency with freal, a vector field f learned using techniques described herein may be generalized to conditions that were not encountered in the training data. The LSP problem generally admits multiple solutions, as it only dictates how the vector field should behave on the sample trajectories. This under-specification can easily lead to overfitting, especially if the class of function is expressive enough. The example of
Notions of stability called incremental stability and contraction analysis tools are associated with the convergence of system trajectories with respect to each other, as opposed to classical Lyapunov stability which is with respect to a single equilibrium. Contraction analysis derives sufficient and necessary conditions under which the displacement between any two trajectories will go to zero.
Contraction analysis of a system {dot over (x)}=f(x) can be explained by considering the dynamics of δx(t), the infinitesimal displacement between two trajectories:
From this equation it is possible to derive the rate of change of the infinitesimal squared distance between two trajectories ∥δx∥22=δxTδx as follows:
More generally, it is possible to consider the infinitesimal squared distance with respect to a metric that is different from the Euclidian metric. A metric is given by smooth, matrix-valued function M: +×nn×n that is uniformly positive definite, i.e. there exists ϵ>0 such that
M(t, x)ϵI∀t∈+, ∀x∈n, (3)
where I is the identity matrix and the relation AB between two symmetric matrices A and B is used to denote that the smallest eigenvalue of their difference A−B is nonnegative.
The squared norm of an infinitesimal displacement between two trajectories with respect to this metric is given by ∥δx∥M(x)
Similarly to equation (2), the rate of change of the squared norm of an infinitesimal displacement with respect to a metric M(x) follows the following dynamics:
where sym[M] denotes
for any square matrix M and {dot over (M)}(x) is the n×n matrix whose (i, j)-entry is ∇Mij(x)Tf(x). This motivates the following definition of contraction.
Definition 1 (Contraction): For a positive constant τ, a subset U of n, of and positive definite matrix function M: n→n×n,the system {dot over (x)}=f(x) is said to be τ-contracting on the region U with respect to M if
sym[M(x)Jf(x)]+{dot over (M)}(x)−τM(x)∀x∈U. (5)
Remark 1: When the vector field f is a linear function {dot over (x)}=Ax, and the metric M(x) is constant M(x)=P, it can be seen that contraction condition (5) is in fact equivalent to a global stability condition,
P
0 and −PAT−AP0 (6)
Given a τ-contracting vector field with respect to a metric M(x), it can be concluded from the dynamics in Equation (4) that
Integrating both sides yields,
Hence, any infinitesimal length ∥δx∥M(x) (and by assumption, ∥δx∥2) converges exponentially to zero as time goes to infinity. This implies that in a contraction region, trajectories will tend to together converge towards a nominal path. If the entire state-space is contracting and a finite equilibrium exists, then this equilibrium is unique and all trajectories converge to this equilibrium.
It is also possible to globally solve the following continuous-time vector field optimization problem to fit a contracting vector field to the training data given some fixed metric M(x). This will be referred to herein as the least squares problem with contraction (“LSPC”):
The search for a contraction metric itself may be interpreted as the search for a Lyapunov function of the specific form V(x)=f(x)TM(x)f(x). As is the case with Lyapunov analysis in general, finding such an incremental stability certificate for a given dynamical system is a nontrivial problem. If one wishes to find the vector field and a corresponding contraction metric at the same time, then the problem becomes non-convex. A common approach to handle this kind of problems is to optimize over one parameter at a time and fix the other one to its latest value and then alternate (i.e. fix a contraction metric and fit the vector field, then fix the vector field and improve on the contraction metric.)
Next, an explanation will be provided for how to formulate and solve the problem of learning a contracting vector field from demonstrations described in LSPC. It is possible to formulate it as a time-varying semidefinite problem, which can be solved in some implementations using sum of squares programming.
Time-varying semidefinite problems (TV-SDP) optimization programs will be referred to herein in the form:
where the variable t∈[0, T] stands for time, the loss function L: in the objective is assumed to be convex and the (i=1, . . . ,m) are linear functionals that map an element f∈ to a matrix-valued function f:[0, T]n×n. The space of functions may be restricted to be the space of functions whose components are polynomials of degree d∈
:={f: nn|fi∈d[x]}, (7)
and it can be assumed that f is a matrix with polynomial entries. Polynomial functions can approximate most functions reasonably well and are suitable for algorithmic operations as will be described shortly.
In various implementations, the problem in LSPC of fitting a vector field f: nn to m sample trajectories {(x(i)(t), {dot over (x)}(i)(t))|t∈[0, T], i=1, . . . , m} can be reformulated as a TV-SDP. For this problem to fit within frameworks described herein, each trajectory x(i)(t) may be approximated with a polynomial function of time
The decision variable may be the polynomial vector field f and the following objective function (which is already convex and quadratic) can be optimized:
In order to impose the contraction of the vector field f over some region around the trajectories in demonstration, a smoothness argument may be used to claim that it is sufficient to impose contraction only on the trajectories themselves. Put another way,
where M(x) is some known contraction metric.
The notions of sum-of-squares (“SOS”) programming and its applications to polynomial optimization will now be reviewed, as well as how to apply SOS programming for learning a polynomial contracting vector field, or “CVF-P.” SOS techniques have found several applications in robotics, such as constructing Lyapunov functions, locomotion planning, design and verification of provably safe controllers, grasping and manipulation, inverse optimal control and modeling 3D geometry.
Let d[x] be the ring of polynomials p(x) in real variables x=(x1, . . . , xn) with real coefficients of degree at most d. A polynomial p∈[x] is nonnegative if p(x)≥0 for every x∈n. In many applications, a goal may be to find the coefficients of one (or several) polynomials without violating some nonnegativity constraints. While the notion of nonnegativity is conceptually easy to understand, testing whether a given polynomial is nonnegative is known to be NP-hard as soon as the degree d≥4 and the number of variables n≥3.
A polynomial p∈[x] is SOS if there exists polynomials q1, . . . , qm∈d[x] such that
p(x)=Σi=tmqi(x)2 (10)
One feature of the set of SOS polynomials is that optimizing over it can be cast a tractable size semidefinite program. In fact, a polynomial p(x) of degree d can be decomposed if and only if there exists a positive semidefinite matrix Q such that
p(x)=z(x)TQz(x)∀x∈n,
where z(x) is the vector of monomials of x up to degree
and the equality between me two sides of the equation is equivalent to a set of linear equalities in the coefficients of the polynomial p(x) and the entries of the matrix Q.
If a polynomial p(x) is SOS, then it is nonnegative, and the matrix Q acts as a certificate of this fact, making it practical to check that the polynomial at hand is nonnegative for every value of the vector x. In order to use similar techniques to impose contraction of a vector field, a slight generalization of this concept may be employed to ensure that a matrix-valued polynomial P(x) is positive semidefinite (PSD) for all values of x. It is also possible to consider the scalar-valued polynomial q (x, u):=uTP x)u, where u is a nx1 vector of new indeterminates, as positive semidefiniteness of P is equivalent to the non-negativity of q. If q is SOS, then it can be said that P is a sum-of-squares matrix (“SOSM”). Consequently, optimizing over SOSM matrices is a tractable problem.
A natural question that arises is how much is lost by restricting techniques described herein to the set of SOSM matrices, as opposed the set of PSD matrices. In general, these two sets are quite different. However, all the matrices considered are univariate as they depend only on the variable of time t. It turns out that in this special case, these two notions are equivalent.
Theorem 1: A matrix-valued polynomial P(t) is PSD everywhere (i.e. P(t)0∀t∈) if and only if the associated polynomial p(t, u):=uP(t)u is SOS.
The next theorem generalizes this result to the case where PSD-ness is imposed only on the interval [0, T] (as opposed to t∈)
Theorem 2: A matrix-valued polynomial P(t) of degree d is PSD on the interval [0, T] (i. e. P(t)0═t∈[0, T]) if and only if can be written as:
where V and W are SOSM. In the first case, V and W have degree at most deg (P)−1, and in the second case V (resp.) has degree at most deg (P) (resp. deg (P)). When that is the case, it can be said that P(t) is SOSM on [0, T].
The following theorem states that the problem fitting a CFV-P to polynomial data can be cast as a semidefinite program.
Theorem 3: The following semidefinite program
with i, and L finding the polynomial vector field that has the lowest fitting error L(f) among all polynomial vector fields of degree that are contracting on a region around the demonstrations xp(i).
To reiterate, the above sum-of-squares relaxation leads to no loss of optimality: the semidefinite programming above returns the globally optimal solution to the problem stated previously as LSPC. Some implementations described herein may use the splitting conic solver (“SCS”) for solving large-scale convex cone problems.
The contraction property of CVF-P generalizes to a wider region in the state space. The next proposition shows that any sufficiently smooth vector field that is feasible for the problem stated in LSPC-SOS is contracting on a “tube” around the demonstrated trajectories.
Proposition 1 (A lower bound on the contraction tube):
If f: Ω⊆n→n is a twice continuously differentiable vector field that satisfies
−sym[M(x(t))Jf(x(t))]−{dot over (M)}(x(t))τM(x)∀t∈[0, T]
where Ω is a compact region of n, τ is a positive constant, M(x) is a positive definite metric, and x: [0, T]n is a path, then f is τ/4-contracting with respect to the metric M(x) on the region U defined by
U:={x(t)+δ|∈[0, T], ∥δ∥2≤ϵ}∩Ω,
where ϵ is positive scalar depending only on the smoothness parameters and defined explicitly in Eqn (11).
For the proof, the following fact about symmetric matrices will be used:
Lemma 1: For any n×n symmetric matrices A and B
where λmin(⋅) denotes the smallest eigenvalue function.
Proof Let f, M, Ω and τ be as in the statement of Proposition 1. Define
c=max{λ≥0|M(x)λM()∀x, y∈Ω}
C=min{λ≥0|λM(x)(∀x, y∈Ω}.
Notice that c≤C, and since the metric M(x) is uniformly positive definite, then c>0. The following definition will be used:
Fix t∈[0, T], and let δ be a vector in such that ∥δ∥2≤∈. The goal is to prove that the matrix:
R
δ:=−sym[
M(x)(t)+δ)Jf(x(t)+δ)]−{dot over (M)}(x(t)+δ)
satisfies Rδτ/2M(x(t)+δ). Notice that the choice for L guarantees that the maps δRijδ are L-Lipchitz for i,j=1, . . . , n, therefore maxij|Rijδ−Rij051 ≤Lδ. Using Lemma 1 it can be seen that the smallest eigenvalues of Rδ and R0 are within a distance of
each other. Since it is assumed that R0τM(x(t))cτI, then RδCIM(x(t)+δ).
A “pick-and-place” robot task is a task in which objects are picked by a robot from a known location and placed into another location such as a box. With techniques described herein, a teleoperator can demonstrate a relatively small number of trajectories that guide a robot arm to grasp objects and place them in a box. After learning from these demonstrations, the robot arm is expected to continually fill boxes to be verified and moved by a human working in close proximity freely moving obstacles in and out of the workspace.
Next, noise was added to the home position of the robot arm, and again the CVF-P was used to operate the robot arm through the pick-and-place task. In
In various implementations, a robot arm can be operated to follow demonstrated trajectories while avoiding obstacles unseen during training. In the implementation described below, collisions are avoided against any part of robot body. At every time step, a depth sensor (e.g., 2.5 or 3D vision sensor) acquires a representation of the obstacle, such as a point cloud. At this point, the demonstrations and trajectories exist in joint space ≈7, while the obstacle exists (e.g., as a point cloud) in Cartesian space ≈3 with an origin at the base of the robot.
In some implementations, a set-valued inverse kinematic map IK is precomputed that maps a position c∈ to a subset of a containing all the joint configurations that would cause any part of the arm to occupy the position c. More formally, the obstacles positions are known in Cartesian space , which is different from the control space of the robot (e.g., the joint angles are controlled, rather than end-effector pose). A robot arm simulator enables queries of a forward kinematics map FK: →. To compute the inverse of this map, the joint space of the robot may be discretized into some number (e.g., 658,945) discrete positions. These discrete positions may be created, for instance, by regularly sampling each joint from a min to max angle using a step size of, for instance, 0.1 radians. In some implementations, the robot may be positioned in a simulator at each point of the discrete joint space points. The robot may then be voxelized to generate the map FK. IK can be computed as the inverse of FK: IK=FK−1.
In various implementations, the obstacle positions may then be incorporated in a repulsive vector-field to push the arm away from collision as it moves,
where the integer r control how fast the effect of this vector field decays as a function of distance (a high value of r makes the effect of hobstacles local, while a small value makes its effect more uniform.) This vector field may be added to the learnt vector-field f to obtain a modulated vector field (depicted in
{tilde over (f)}(t, x)=f(x)+αhobstacles(t, x)
where α is positive constant that is responsible controlling the strength of the modulation that is then fed to the robot arm. If the modulation is local and the obstacle is well within the joint-space contraction tube, the motion can be expected to re-converge to the demonstrated behavior.
Obstacle avoidance is not limited to the modulation methods described herein. Other modulation techniques are possible for obstacle avoidance, each with different guarantees and drawbacks. For example, a multiplicative modulation function may be employed that preserves equilibrium points in the case of convex or concave obstacles. However, the modulation techniques described herein, due to their additive nature, allow for handling of a large number of obstacles as every term in Equation (14) can be computed in a distributed fashion. Additionally, it is not necessary to impose any restrictions on the shape of the obstacles (convex/concave). This is particularly important as the joint control space is different from the Cartesian space where the obstacle is observed, and the map IK that links between the two spaces can significantly alter the shape of an obstacle in general (e.g. a sphere in Cartesian space can be mapped to a disconnected set in joint space).
At block 702, the system may receive a set of data points generated based on sensor data from one or more sensors obtained during imitation learning of a robot trajectory. The imitation learning may include, for instance, physical manipulation of a reference point from an initial point to a target point.
At blocks 704-708, the system may generate a dynamical systems control policy that regulates both robot motion and robot interaction with an environment. For example, at block 704, the system may constrain a neighborhood space that contains the set of data points into a contracting region. In some such implementations, the contracting region may take the form of a tube around the robot trajectory. At block 706, the system may, based on the set of data points, calculate a continuous function that corresponds to the robot trajectory. At block 708, the system may fit a polynomial vector field to the continuous function using semidefinite programming, as described previously.
At block 710, the system may control a robot based on the dynamical systems control policy. If the robot encounters an obstacle during operation, at block 712, the system may receive sensor data indicative of a position of the obstacle in Cartesian space. For example, a dynamic obstacle may be observed in the robot's workspace using a 2.5 or 3D vision sensor. At block 714, the system may determine a position of the obstacle in joint space based on the position of the obstacle in Cartesian space. As described previously, in some implementations, the system may discretize some number of joint configurations and determine a forward kinematics (“FK,” i.e. joint-space-to-Cartesian-space) mapping based on those discretized joint configurations. Then, the system may calculate an inverse of that mapping, IK, which maps Cartesian space to joint space. At block 716, based on the position of the obstacle in joint space, the system may generate a repulsive polynomial vector field for the obstacle.
At block 718, the system may modulate the polynomial vector field of the dynamical systems control policy based on the repulsive polynomial vector field for the obstacle. An example of this is depicted in
Described herein were implementations for teleoperator imitation using contracting vector fields that are globally optimal with respect to loss minimization and providing continuous-time guarantees on the behavior of the system when started from within a contraction tube around the demonstration. Techniques described herein compare favorably with other movement generation techniques. Also described herein are techniques to generate a workspace Cartesian to joint space mapping for the robot, and for utilizing the mapping to update contracting vector fields on the fly to avoid dynamic obstacles.
While several implementations have been described and illustrated herein, a variety of other means and/or structures for performing the function and/or obtaining the results and/or one or more of the advantages described herein may be utilized, and each of such variations and/or modifications is deemed to be within the scope of the implementations described herein. More generally, all parameters, dimensions, materials, and configurations described herein are meant to be exemplary and that the actual parameters, dimensions, materials, and/or configurations will depend upon the specific application or applications for which the teachings is/are used. Those skilled in the art will recognize, or be able to ascertain using no more than routine experimentation, many equivalents to the specific implementations described herein. It is, therefore, to be understood that the foregoing implementations are presented by way of example only and that, within the scope of the appended claims and equivalents thereto, implementations may be practiced otherwise than as specifically described and claimed. Implementations of the present disclosure are directed to each individual feature, system, article, material, kit, and/or method described herein. In addition, any combination of two or more such features, systems, articles, materials, kits, and/or methods, if such features, systems, articles, materials, kits, and/or methods are not mutually inconsistent, is included within the scope of the present disclosure.
Filing Document | Filing Date | Country | Kind |
---|---|---|---|
PCT/US2020/016151 | 1/31/2020 | WO | 00 |
Number | Date | Country | |
---|---|---|---|
62800378 | Feb 2019 | US |