Evolved Virtual Creatures (Karl Sims)
(Karl Sims, Evolving Virtual Creatures, SIGGRAPH 1994)

Project 4 : Creature Contest


Assigned Date : 3/3/2009
Project Due Date : 3/18/2009 at 11:59pm
Artifcat (Writeup) Due Date : 3/19/2009 at 10:00am

Help Session: Mon March 9, 3:00pm CSE 624

Contest Winners

Project Description

In this assignment Creature Contest, your task is to design a physically simulated and controlled creature that walks/hops/slithers across a terrain, from some start area to the finish area. Your creature will have limbs held together with joints, and it will move by applying forces to its joints. Not only will you have to design your creature, but you will also have to build a controller for it, to tell it how to move its joints/flex its muscles at each point in time. Your creature will live in the phyiscal simulation engine world of ODE (Open Dynamics Engine). There will be a competition between your creatue and the creatures of the other students in the class to see who can reach the finish area the fastest over various types of terrains.

{insert image of some finalized creature... when one exists}

Getting Started

  1. Skeleton Code (Includes a Mac Makefile)
  2. ODE, ODE Wiki/Manual
  3. GLUT
  4. Help Session PDF, PowerPoint

The skeleton code uses GLUT and ODE. ODE is the physics engine and GLUT is a library that builds off of standard OpenGL calls that makes the writing of graphics applications easier. FLTK is not used in this project -- there is no GUI, but you can still use GLUT to do things with mouse and keyboard input. The code was adapted this project at UCSC, which used SDL.

In the skeleton code, you will find 3 classes: CreatureWorld, Creature, and Terrain. CreatureWorld contains 1 Creature object and 1 Terrain object and is responsible for setting up the graphics and physics, and then handling the main simulate/draw/repeat loop. Both Creature and Terrain have a method called 'build()' that CreatureWorld calls to add them to the physical world. Creature and Terrain also both have a 'draw()' function called by CreatureWorld. Creature additionally has a 'think()' method called once per time-step where your controller logic should go.

The starting terrain is just a flat plane. There are 10x10 green checkered squares drawn on the plane.

The starting creature is a series of flattish rectangles connected together with hinge joints. The creature curls and uncurls to move forward a little bit at a time. The controller has 4 states: curling, uncurling, curled, and uncurled. Curled and uncurled are there to give the system time to stablize. On the curling step, a force is applied to all the joints or a subset of the joints to bend them inward. On the uncurling step, a negative force is applied to straighten out the joints. The creature that you create should be smarter and/or more intricate than this roll-up worm.

ODE Terms

  1. WORLD: 'a dynamics world', think forces applied to masses, causing the masses to move.
  2. SPACE: 'a collision space', think 3D shapes colliding, intersecting. Collisions generate forces which have an effect on the world.
  3. BODY: a rigid body living in the world. Has mass, position, orientation only. No 3D structure.
  4. GEOM: geometry (for collision), need a geom to spatially describe a body if you want it to collide with anything
  5. JOINT: a constraint between two bodies

Required Extensions

  1. Build a creature out of ODE primitives (boxes, cylinders, capsules, etc.) and joints (ball joints, hinges, etc.)
  2. Design a controller for this creature such that it can move itself forward across flat terrain in the positive X direction by only applying forces to its joints.
  3. Make a new terrain that is more interesting than a flat plane that your creature can still move across.
  4. Web page writeup: Something intelligent sounding we can put on the artifact page. You should include:
    • A description of your model
    • A description of your controller
    • What inspired your creature, if anything
    • Details about anything special that you did
    • A list of references you used
    • Visuals, including screen shots, figures, and/or video clips
    • A representative image, say 400 pixels wide, that I can use on the artifact page.

Turn in: Send me an email with your code and all of the materials for your webpage. Images and other files should be locally referenced so I can just throw it up on the course webpage. You can also just give me a link to the webpage if you choose to host it yourself, but giving me the files ensures it will be around *forever*! I would like to try to get all your creatures running on my own computer so they can compete in a consistent environment. This is why they're due at midnight the night before.

Additional Resources

  1. Karl Sims' Evolved Virtual Creatures
  2. Seth and Yongjoon's 557 Final Project Physically Based Animation of a Lizard-like Creature

Skulls and Crossbones

Here is a list of suggestions for extending the program for extra credit. You are encouraged to come up with your own extensions. We're always interested in seeing new, unanticipated ways to use this program! 2 crossbones = 1 skull = 1 extra credit point. One "jolly roger" aka "skull and crossbones" therefore equals 1.5 points.
 

[bell+whistle] Learn a motion controller. Take a look at Radek Grzeszczuk and Demetri Terzopoulos, Automated Learning of Muscle-Actuated Locomotion Through Control Abstraction