Crowd Simulations - PowerPoint PPT Presentation

About This Presentation
Title:

Crowd Simulations

Description:

Divide into several small time-steps (length T) Show new ... Invented Zoopraxiscope (spinning wheel of still images) to animate images. Walk Cycle - Analysis ... – PowerPoint PPT presentation

Number of Views:36
Avg rating:3.0/5.0
Slides: 42
Provided by: leno6
Learn more at: http://www.cs.unc.edu
Category:

less

Transcript and Presenter's Notes

Title: Crowd Simulations


1
Crowd Simulations
  • Guest Instructor - Stephen J. Guy

2
Outline
  • Animation basics
  • Key framing
  • Simulation Loop
  • How to move one man
  • Walk Cycle
  • IK
  • How to move one thousand
  • Crowd Models
  • Collision Avoidance
  • Data Structures
  • Rendering

3
Outline
  • Animation basics
  • Key framing
  • Simulation Loop
  • How to move one man
  • Walk Cycle
  • IK
  • How to move one thousand
  • Crowd Models
  • Collision Avoidance
  • Rendering

4
Animation - Basics
  • Comp 768 Preview
  • Goal Illusion of continuous motion
  • Divide into several small time-steps (length ?T)
  • Show new image at each time-step
  • Needs to happened at least 12/second (more is
    better)

5
Outline
  • Animation basics
  • Key framing
  • Simulation Loop
  • How to move one man
  • Walk Cycle
  • IK
  • How to move one thousand
  • Crowd Models
  • Collision Avoidance
  • Data Structures
  • Rendering

6
Walk Cycle
  • Simply Translating a character to its goal is
    unrealistic
  • Walk Cycle A looping series of positionswhich
    represent a character walking (or running or
    galloping)
  • Shifting the animation provides the illusion of
    walking

Inplace
Shifted w/ Time
7
Digression - Eadweard Muybridge
  • 19th Century English Photograyher
  • Used multiple cameras to capture motion
  • Invented Zoopraxiscope (spinning wheel of still
    images) to animate images

8
Walk Cycle - Analysis
  • Pros
  • Simple to implement
  • Captures the basics of human movement
  • Cons
  • Walks must cycle
  • Cant handle changes in stride length
  • Cant handle jumps
  • Must be animated by hand

9
Walk Cycle - Alternatives
  • Inverse Kinematics
  • Using math to figure out where to place the rest
    of the body to get the feet moving forward
  • Motion Capture
  • Record data of real humans walking
  • Motion Clips
  • FSM of different motions

?
10
Outline
  • Animation basics
  • Key framing
  • Simulation Loop
  • How to move one man
  • Walk Cycle
  • IK
  • How to move one thousand
  • Crowd Models
  • Collision Avoidance
  • Data Structures
  • Rendering

11
Crowd Simulation Models
  • Simplest model Agent Based
  • Capture Global Behavior w/ many interacting
    autonomous agents
  • Each person is represented by one agent
  • Chooses next state based on goal and neighbors
  • Pioneered by Craig Reynolds
  • Won 1998 (Technical) Academy Award

12
Agent Based Simulations
  • Flocking
  • Craig Reylonds
  • SIGGRAPH1987
  • Social Forces Model
  • Dirk Helbing
  • Physics Review B 1995
  • Nature 2000
  • Reciprocal Velocity Obstacles
  • Van den Berg
  • I3D 2008

13
Agent Based Simulations
  • Flocking
  • Craig Reylonds
  • SIGGRAPH1987
  • Social Forces Model
  • Dirk Helbing
  • Physics Review B 1995
  • Nature 2000
  • Reciprocal Velocity Obstacles
  • Van den Berg
  • I3D 2008

14
Flocking
  • Seminal work in multi-agent movement
  • Assign simple force to each agent
  • Used in
  • Lion King
  • Batman Returns

Separation
Alignment
Cohesion
15
Boids - Continued
  • New forces can be added to incorporate more
    behaviors
  • Avoiding Obstacles
  • Collision Avoidance
  • Be Creative!

16
Boids Online
  • Visit http//www.red3d.com/cwr/boids/
  • And http//www.red3d.com/cwr/steer/Unaligned.html

17
Agent Based Simulations
  • Flocking
  • Craig Reylonds
  • SIGGRAPH1987
  • Social Forces Model
  • Dirk Helbing
  • Physics Review B 1995
  • Nature 2000
  • Reciprocal Velocity Obstacles
  • Van den Berg
  • I3D 2008

18
Helbings Social Force Model
  • Very similar to boid model
  • Treats all agents as physical obstacles
  • Solves a F/m where F is social force
  • Fij Pedestrian Avoidance
  • FiW Obstacle (Wall) Avoidance

Desired Velocity
Current Velocity
Avoiding Other Pedestrians
Avoiding Walls
19
Social Force Model Pedestrian Avoidance
Collision Avoidance
Non-penetration
Sliding Force
  • rij dij ?Edge-to-edge distance
  • nij Vector pointing away from agent
  • Aie(rij-dij)/Bi ? Repulsive force which is
    exponential increasing with distance
  • g(x) ? x if agents are colliding, 0 otherwise
  • tij Vector pointing tangential to agent
  • ?Vtji Tangential velocity difference
  • FiW is very similar

20
Helbing - Continued
  • Noticed arching
  • Also observed in real crowds
  • Killed or injured people whoexperienced too much
    force (1,600 N/m) became unresponsive obstacles
  • Noticed Faster-is-slower effect

21
Agent Based Simulations
  • Flocking
  • Craig Reylonds
  • SIGGRAPH1987
  • Social Forces Model
  • Dirk Helbing
  • Physics Review B 1995
  • Nature 2000
  • Reciprocal Velocity Obstacles
  • Van den Berg
  • I3D 2008

22
Reciprocal Velocity Obstacles
  • Applied ideas from robotics to crowd simulations
  • Basic idea
  • Given n agents with velocities, find velocities
    will cause collisions
  • Avoid them!
  • Planning is performed in velocity space
  • RVOAB(vB, vA) vA 2vA vA ? VOAB(vB)

23
RVO Planning In Velocity Space
?
24
RVO Planning In Velocity Space
?
25
RVO Planning In Velocity Space
RA RB
?
26
RVO Planning In Velocity Space
(VA VB)/2
?
27
RVO Planning In Velocity Space
?
28
RVO Planning In Velocity Space
29
RVO Planning In Velocity Space
30
RVO Planning In Velocity Space
31
RVO Planning In Velocity Space
32
RVO Planning In Velocity Space
33
Videos
  • 12 Agents in a Circle

34
Videos
  • 1,000 agents in a circle

35
Related data-structures
  • KD-trees
  • Allowing efficient gathering of nearby neighbors
    O(log n)
  • Roadmaps A
  • Allows global navigation around obstacles

36
Roadmaps
  • Create roadmap in free space
  • Find visible source nodes
  • Graph Search to find path to Destination
  • A is very popular graph search algorithm

37
Video
  • 1,000 people leaving Sitterson Hall
  • Uses RVO, Roadmaps, A and Kd-Trees

38
Outline
  • Animation basics
  • Key framing
  • Simulation Loop
  • How to move one man
  • Walk Cycle
  • IK
  • How to move one thousand
  • Crowd Models
  • Collision Avoidance
  • Data Structures
  • Rendering

39
Rendering Crowds
  • Traditional OpenGL pipeline can be too slow for
    1000s of agents
  • View Culling helps, but often not enough
  • Need Level-of-Detail techniques
  • Use models with more polygons up close, less when
    far away

40
Imposters
  • Replace Far off agents with an oriented texture
  • Several Issues
  • Popping
  • Uniformity
  • Lighting
  • Shadows
  • Many issues addressed in recent works

41
Questions
  • ?
Write a Comment
User Comments (0)
About PowerShow.com