Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

29
Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments Bruce M. Blumberg & Tinsley A. Galyean Presented by Kristen Neal

description

Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments. Bruce M. Blumberg & Tinsley A. Galyean. Presented by Kristen Neal. Overview. We want to create an a behavior system that ‘does the right thing’ The right thing in this case can mean a lot of things - PowerPoint PPT Presentation

Transcript of Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

Page 1: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

Multi-Level Direction of Autonomous Creatures for Real-

Time Virtual Environments

Bruce M. Blumberg&

Tinsley A. GalyeanPresented by Kristen Neal

Page 2: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

19 November 2003 CS 551 - Animation2

Overview

We want to create an a behavior system that ‘does the right thing’ – The right thing in this case can mean a lot of things– More general than what what we’ve looked at before

We want to describe behavior not just movement – Reasons for doing things

Autonomous vs. Controllable.

Page 3: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

19 November 2003 CS 551 - Animation3

Multiple Levels of Control

MotivationalLevel

TaskLevel

DirectLevel

just do the right thing

“you are hungry”

do THIS the right way

“go to that tree”

do what I tellyou

“wag your tail”

Page 4: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

19 November 2003 CS 551 - Animation4

Incorporating these controls into overall behavior

Layered Architecture– Abstraction– Inheritance

Needs to include– Action selection– Response to external stimuli– Resolution functions (picking between behaviors)– Interactive response

Page 5: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

19 November 2003 CS 551 - Animation5

Architecture

5 layers 2 abstraction barriers Each layer ‘controls’ the next layer Motor System

– Unique to each creature– Hides the ‘deals’ of creature– Translates high level behaviors into

interactions with the world

Behavior

Controller

Motor Skill

DOF

Geometry

Mot

or S

yste

m

Page 6: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

19 November 2003 CS 551 - Animation6

Architecture

Geometry– The world the creature interacts with

World geometry / obstacles Sensory input / vision

– General to multiple creatures

Behavior

Controller

Motor Skill

DOF

Geometry

Mot

or S

yste

m

Page 7: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

19 November 2003 CS 551 - Animation7

Architecture

Degrees of Freedom– The joints that the creature can

change– Hierarchy of DOF

Higher level DOF’s control the availably of lower dof’s

Locking Mechanism

Behavior

Controller

Motor Skill

DOF

Geometry

Mot

or S

yste

m

Page 8: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

19 November 2003 CS 551 - Animation8

Architecture

Motor Skills– The specific actions that the creature can

execute– Similar to the various ‘states’ described in

the motion capture papers Walk Run Wag Tail

– Control the availability of DOF’s resource management

Behavior

Controller

Motor Skill

DOF

Geometry

Mot

or S

yste

m

Page 9: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

19 November 2003 CS 551 - Animation9

Architecture

Controller– Selects the appropriate motor skill to

accomplish a behavior– EX:

MoveForward = Truck.Drive MoveForward = Dog.Walk

Behavior

Controller

Motor Skill

DOF

Geometry

Mot

or S

yste

m

Page 10: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

19 November 2003 CS 551 - Animation10

Architecture

Behavior– High level capabilities

“find food and eat” “go over there”

– General to multiple creatures

Behavior

Controller

Motor Skill

DOF

Geometry

Mot

or S

yste

m

Page 11: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

19 November 2003 CS 551 - Animation11

Motor System Summary

Provides Abstraction Supports multiple forms of commands Provides a generic set of commands for all

creatures Provides resource management Minimizes ‘house keeping’ that the behavior

system (or user) must do

Page 12: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

19 November 2003 CS 551 - Animation12

Motor Skills Summary

Utilize DOF’s to produce coordinated movement

Spring-Loaded– Drift back to a default ‘rest’ value over time when

not specified Advantage: Behavior system doesn’t need to ‘turn off’

motor skills Disadvantage: Behavior system must continually direct that

a particular skill be used

Page 13: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

19 November 2003 CS 551 - Animation13

Controller Overview

Translates behaviors into calls to motor skills 3 Types of Controls

– Primary Commands “Do this NOW”

– Secondary Commands “Do this now if it doesn’t interfere with the primary”

– Meta Commands “Accomplish another goal in this way….”

Control Blocks

Page 14: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

19 November 2003 CS 551 - Animation14

Synthetic Vision

Scene rendered from creature’s viewpoint Gradient field is calculated from image Useful for…

– Collision Avoidance– Low level movement control– Allows the creature to interact in new environments

No preset world ‘map’ is needed

Page 15: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

19 November 2003 CS 551 - Animation15

Behavior System Overview

Goal oriented (Motor skills are not)– Evaluates conflicting goals and chooses between

them– Selects the control signals to send to the Motor

System at each time step– Provided high-level autonomous action– Chooses when a particular behavior is active

(instead of being told)

Page 16: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

19 November 2003 CS 551 - Animation16

Behavior System

Behavior

Motor Commands

Level of Interest

ReleasingMechanism

Sensory System

Inhibition

InternalVariable

Internal Variable

External World Goals / Motivations

Page 17: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

19 November 2003 CS 551 - Animation17

Behavior System

Pronomes– Similar to ‘pronoun’ in English– Data structure in Behavior System– Allows you to say ‘do IT’ without specifying what ‘it’

exactly is

Page 18: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

19 November 2003 CS 551 - Animation18

Behavior System

Sensory System– Synthetic Vision, ect..

Internal State Variables– Current condition of the system– Autonomous growth and Dampening Rates

Releasing Mechanisms– Filters/detectors that interpret sensory input– Takes strength of external stimuli and internal motivation into

account Weak Stimulus + Strong Motivation Strong Stimulus + Weak Motivation

Page 19: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

19 November 2003 CS 551 - Animation19

Behavior System

Behavior Groups– Group mutually inhibitive (related) behaviors– Hieratical Structure

Move

Run SkipJog WalkSprint

Page 20: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

19 November 2003 CS 551 - Animation20

Behavior System Implementation

ReleasingMechanism

Find: (“is the object of interest within range?”

Filter:(“dos x aspect of object pass filter?”)

Weight:

(“how close is object to optimal dist?”)

Temporal Filter:Immediate, Latch, Average or Integrate

SensorySystem

World

Behavior

Pronome:TypeclosestPtRangeBearing,last stage passed

Page 21: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

19 November 2003 CS 551 - Animation21

Inhibition

Only one mutually exclusive behavior can be active at a time– Dithering

Switching back and forth between two behaviors– Avalanche Effect

Possibility for pathological behavior Can be unrealistic

– Inhibitory Gains / Level of Interest Temporal aspects of behavior

Page 22: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

19 November 2003 CS 551 - Animation22

Algorithm

(1) Update internal variables based on Previous value Growth rate Dampening rate Feedback effects

ivit = ( ivi(t - 1) • dampi ) + growthi – effectskit k

Effectskit = ( modifyGainki • vk(t – 1)

Page 23: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

19 November 2003 CS 551 - Animation23

Algorithm

(2) Update level of interest based on Previous value Growth rate Dampening rate Boredom rate Clamp between 0 and 1

liit = Clamp (( lii(t - 1) • dampi ) + growthi – ( vi(t - 1) • bRatei ),0, 1)

k

Page 24: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

19 November 2003 CS 551 - Animation24

Algorithm

(3) Behaviors compete to become active starting with the top level behavior group

(3.1) Releasing Mechanisms update their values based on sensory input– Result is summed with Behavior’s internal interest variables– Then multiplied by its Level of Interest

(3.2) Inhibition due to other behaviors in the group is found (3.3) Result is clamped to to mini , maxi

rmit = Clamp( TemporalFilter ( t, rmi(t - 1), Find( sit , dMini , dMaxi ) Filter(sit) • Weight(sit , dOpti ),

mini , maxi )

k

Page 25: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

19 November 2003 CS 551 - Animation25

Algorithm

(4) Update the behavior based on Level of interest Releasing Mechanism Internal Variables

vit = Max [ ( liit • Combine,( rmki, ivjt) - nmi • vmt), 0 ]mk j

Page 26: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

19 November 2003 CS 551 - Animation26

Algorithm

(5) If more than one behavior > 0 then repeat– The final ‘winning’ behavior becomes the active behavior for

that group

(6) Behaviors not active are given a chance to issue secondary or meta commands

(7) If the active behavior is a leaf, it can execute– Else, child becomes active behavior group…

Page 27: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

19 November 2003 CS 551 - Animation27

Integration of Directability

Motivational Control– Adjusting internal variables

Changing constituent parts of the behavior system Action Selection can be initiated at any node Imaginary Sensory Inputs External Motor Commands

– Primary– Secondary

Page 28: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

19 November 2003 CS 551 - Animation28

Implementation

Object oriented C++ (3,000 lines of code) Silas T. Dog

– Responds to ~12 human gestures– 24 dog specific motor skills (2,000 of lines of code)– 70 motor commands– 40 behaviors– 11 behavior groups– 40 releasing mechanisms– 8 internal variables

Page 29: Multi-Level Direction of Autonomous Creatures for Real-Time Virtual Environments

19 November 2003 CS 551 - Animation29

Comments

Good– Relatively simple structure– Creature can be controlled on different levels– Not much math

Bad– Doesn’t really specify how the motor system is

constructed