Transcript PowerPoint
Chenney & Forsyth, 2000 Animation CS 551 / 651 Chenney/Forsyth Paper Likelihood of an animation pw (A) = probability ball bounce animation A is observed • A ball bounces on flat table i times with – normal vector mean at 0 degrees – standard deviation 10 degrees Constraints We want pw(A | C) • Examples • The ball must start here and land there • The ball must go through this point • The initial acceleration must be foo Bayes’ Rule A = P(an animation is natural) C = P(an animation satisfies constraints) • Chenney ignores denominator because it is the same for all animations and washes out • P(C|A) becomes a new function Pc(A) How do we compute P(A|C) Could generate lots of examples… • Select those that satisfy C • Out of all those that satisfy C, how likely is A Generating lots of examples of bouncing ball will not generate many that satisfy C How do we compute Generate any example animation, A • Evaluate how likely is it in the real world • Evaluate how well it satisfies the (soft) constraints Ball example pw(A) • pc(A) • Gaussian function defined on final position of ball, d We’re onto something here Our goal is to find animations that are likely and satisfy constraints • Animations with high P(A|C) Because it’s hard to find animations that satisfy constraints exactly, we’ll be satisfied with animations that are likely and come close to satisfying constraints • Animations with high P(A)Pc(A) Animations with high P(A)Pc(A) are likely to also have high P(A|C) so let’s search… Searching for likely candidates Sampling • Given an animation, A, how “good” is it • Could a simple change to A make it better? Markov Chain Monte Carlo Markov chain • Given a sequence of events, the present state is only dependent on the preceding state and independent of the previous states – Only the present influences the future – The past doesn’t influence the future – A random walk (why?) Monte Carlo • Using random numbers to solve a problem MCMC Algorithm Compute p(A0) Use markov model to perturb degree-of-freedom values from Ai Compute p(Ac) MCMC Algorithm How likely is change from parameters used to generate Ac to parameters used for Ai Ball example Transition probability, q n ball bounces, k were changed 10 values for normal (+/- 5) • First term = prob of choosing particular set of degrees of freedom to change • Second term = prob of choosing any particular value for a degree of freedom MCMC Algorithm Key component • propose ( ) – “designed through intuitive reasoning and experimentation” – “use past experience as a guide” MCMC Algorithm Provable feature of algorithm • As i inf, samples are true reflection of probability distribution of model • Sampling animation from the set of samples produces well-understood plausibility 2D Ball Solving for ball Take the log 2D Ball Lesson learned about standard dev s too small most animations are improbable because they don’t land in correct place s too large most animations are probable because they land within landing region but they miss the exact spot Tuning probability function, p(A) is tricky Bowling Degrees of freedom • Ball (diameter, initial position, initial velocity, initial angular velocity) • Pin (initial position) Constraints • Initial pins up, final pins down • Gibb’s Distribution Lesson learned • If constraints are too strict, iterative perturbations will not frequently “jump” from one legal animation to another Rolling Dice Normal function (for tabletop) • Example from bouncing ball won’t work – Nearby points should have similar normals (not independent) – Object bouncing in same place should use same normal each time • Create “surface” using b-splines – Degrees of freedom are control point heights, initial pos – Also use restitution and friction values at control points Rolling Dice Lessons learned • Creating a good proposal algorithm is difficult • Algorithm finds first constraint satisfying animation (in one hour) and has hard time jumping to another satisfying animation (“many” hours) Rolling Dice Constraints • Any position/orientation at any time Review What’s easy about this? • Getting a simulation • Selecting some degrees of freedom • Building the MCMC algorithm Review What’s difficult? • Building p(A|C) function – Tuning bouncing ball standard deviation – Authors used Gibbs distribution function to assist • Building proposal function – Dice example had simple proposal algorithm Review What’s difficult • This is a search problem – Global vs. local search – Requires infinite samples to be perfect ² Simulation time and search space size are realistic constraints on feasibility Big Picture How to synthesize animations that accomplish specific goals • Keyframing • Simulation • Motion capture Data-driven simulation is a compromise