• Aucun résultat trouvé

Simulation Framework

Dans le document Language Acquisition (Page 161-164)

Naive Physics

9.1 Simulation Framework

Abigailsimulates the imagined future of an image by moving sets of gures from that image along linear and circular paths which reduce the potential energy of the set of moved gures. The potential energy of a set of gures is simply the sum of the potential energies of each gure in that set. The potential energy of a gure f is taken to be the product of its mass m(f) and the height of its center-of-mass y(f).

Abigail's kinematic simulator is a function I(F;J;L;P) which takes as input, a set of gures F, along with a joint model J, a layer model L, and a predicate P.3 Each gure f 2 F has an ob-served position, orientation, shape, and size as derived from the current movie frame. From this input, I(F;J;L;P) calculates a series of imagined positions and orientations for each f 2 F.4 This series of po-sitions and orientations constitutes the motion predicted byAbigailfor the gures under the inuence of gravity. I will denote the imagined positions and orientations of a gure f as ^x(p(f)), ^y(p(f)), and ^(f) in contrast to the observed positions x(p(f)), y(p(f)), and (f). I similarly extend such notation to distances ^(p;q), displacements ^(p;f), and any other notion ultimately based on coordinates of gure points. During imagination,Abigailapplies the predicate P to the imagined positions and orientation of the gures after moving each group of gures. If P( ^F) ever returns

true

then the simulation is halted and I(F;J;L;P) returns

true

. If P( ^F) never returns

true

and the simulation reaches a state where no further movement is possible, I(F;J;L;P) returns

false

. Thus I(F;J;L;P) can be interpreted as asking whether P will happen imminently in the current situation.

During simulation,Abigailwill move one set of gures, while leaving the remaining gures station-ary. The set of moved gures will be called the foreground while the stationary gures will be called the background. I will denote the set of foreground gures as F and the set of background gures as G. The sets F and G are disjoint. Their union constitutes the entire set of guresF being imagined. This might not be equivalent to the entire set of gures in the current movie frame, since Abigailoften imagines what would happen if certain gures were missing, as is the case when she tries to determine whether one object supports another by imagining a world without the rst object. Two kinds of foreground

2A closed-loop kinematic chain is a set of componentsfc1;:::;cngwhere eachciexceptcn is joined toci+1andcnis joined back to3 c1.

This may appear to be circular sinceI(F;J;L;P) takes joint and layer models as input, and in turn, is used to compute joint and layer models according to the process described in section 8.2.1. This circularityis broken by callingI(F;J;L;P) with empty joint and layer models initially to compute the rst joint and layer models, and using the previous models at each frame to compute the updated models. Surprisingly, it usually takesAbigailonly a single frame to converge to the correct models.4

Independentof the simplifyingassumptiondiscussed in section 8.1.2, during imagination the shapes and sizes of gures must remain invariant to avoid producing degenerate predictions.

motion are considered: translating F along a linear axis whose orientation is , and rotating F about a pivot point p. The pivot point need not lie on any gure in F. In fact it can be either inside or outside the bounding area of F.

The simulator operates by repeatedly choosing some foreground F, and either translating F along an appropriate axis , or rotating F about an appropriate pivot point p, as far as it can, so long as the potential energy of F is continually decreased and the substantiality, ground plane, and joint constraints are not violated. It terminates when it cannot nd some foreground it can move to decrease its potential energy. At each step of the simulation there may be several potential motions which could each reduce the potential energy. For the most part, the choice of which one to take is somewhat arbitrary, though there is a partial ordering bias which will be described shortly.

The key facet of this simulation algorithm is that at each step, the foreground is translated or rotated as far as possiblesubject to the requirements that potential energy continually decrease and constraints be maintained. Limiting all motion to be linear or circular, and limiting gure shapes to be line segments and circles, allows closed-form analytic determination of the maximum movement possible during that step. Later in this section, I will discuss this fairly complex closed-form solution.

At each simulation step, Abigail must choose an appropriate foreground F, decide whether to translate or rotate F, and choose an appropriate axis for the translation or pivot point p for the rotation. Having made these choices, the maximum movement is analytically determined. Choosing the type of movement (F, and or p), however, involves search. Abigailconsiders the following six possibilities in order.

Translating an object downwards.

In this case F consists of a set of gures connected by joints and = ;2. There must by no joint between any foreground and background gures. Thus F must be a connected component in the connection graph whose vertices are gures and edges are joints between pairs of gures.

Sliding an object along an inclined surface.

In this case F consists of a connected component in the connection graph and is either the orientation (f), or the opposite orientation (f) + , whichever is negative when normalized, of some line segment f such that either

1. f is in the foreground and is coincident with a line segment g in the background,

2. f is in the background and touches a line segment g in the foreground at an endpoint of g, 3. f is in the background and is tangent to a circle g in the foreground,

4. f is in the foreground and touches a line segment g in the background at an endpoint of g, or 5. f is in the foreground and is tangent to a circle g in the background

as long as f ./ g. No other translations axes need be considered for this case. Furthermore, neither vertical nor horizontal translation axes need be considered since vertical translation axes fall under the previous case, and horizontal motion will never reduce the potential energy of an object. Figures 9.2(a) through 9.2(e) depict cases 1 through 5 respectively. These cases may at times yield multiple potential sliding axes for a given foreground as demonstrated in gures 9.2(f) through 9.2(h). In gure 9.2(f) these degenerate to the same axis. In both gures 9.2(g) and 9.2(h) only one of the two axes allows unblocked movement. In general, when multiple sliding axes are predicted, they will either be degenerate, or all but one will be blocked.

An object falling over.

In this case F consists of a connected component in the connection graph and p is either

1. an endpoint of a line segment from F if the endpoint lies on the ground,

2. an endpoint of a line segment f from F if the endpoint lies on a gure g from G and f ./ g,

(a) (b) (c)

(d) (e) (f)

(g) (h)

Figure 9.2: Determining the potential axes of sliding. A foreground might slide relative to a background along any line segment from the foreground which either is coincident with some line segment, touches the endpoint of some line segment, or is tangent to some circle, in the background, or along any line segment from the background with an analogous relationship to a gure in the foreground. Other axes, including the orientations of unrelated line segments, line segments which touch other gures in ways other than those specied above, or line segments which don't touch across the foreground and background boundary need not be considered.

3. an endpoint of a line segment g from G if the endpoint lies on a gure f from F and f ./ g, 4. the center of a circle from F if the circle touches the ground,

5. the center of a circle f from F if the circle touches a gure g from G and f ./ g, or 6. the center of a circle g from G if the circle touches a gure f from F and f ./ g.

No other pivot points need be considered for this case. Figures 9.3(a) through 9.3(f) depict cases 1 through 6 respectively.

Varying a exible rotation parameter of a joint.

If j is a joint with a exible rotation parameter that connects two parts of an object that are otherwise unconnected then it is possible to rotate either part about the joint pivot. In this case F can be any connected component in the connection graph computed without j such that F contains either f(j) or g(j). The only pivot point which need be considered is p(j), the point where the two gures are joined. If j is not part of a closed-loop kinematic chain then there will always be exactly two such foregrounds F, one for each subpart connected by j. One subpart will contain f(j) while the other will contain g(j). If j is part of a closed-loop kinematic chain then there will be a single such foreground F containing both f(j) and g(j). Abigaildetects this case and simply does not consider rotating about exible joints in closed-loop kinematic chains. This amounts to treating all closed-loop kinematic chains as rigid bodies.

Varying a exible translational displacement parameter of a joint.

If j is a joint such that f(j)

Dans le document Language Acquisition (Page 161-164)