A small black and white form enters the circular arena, gathers a flock of ducks and skillfully maneuvers them safely to their pen. But Rover’s work wasn’t guided by a shepherd, it was modeled by a computer programmer.
Ten years ago researchers at PennState used a computer model simulating the ducks ‘ flocking behaviour to design a herding algorithm. The algorithm was initially tested in computer simulations then tranferred to a robot that was used to herd ducks. It was reported as the first case of a robot system used to control an animal behavior in a useful way.
“Rover” is a vertical cylinder on wheels. designed to work outdoors on short grass. It can accelerate to 9 mph and outrun the ducks. It’s about a foot tall, 19 inches in diameter and cushioned in plastic to keep the ducks safe. The system includes the mobile robot vehicle that herds the ducks, a computer and a camera. Camer images are analyzed by the computer to control the robot. Given a pre-programmed goal, the program uses a flocking algorithm to determine a path for the robot.
The Robot Sheepdog Project (RSP) was a collaboration between the Silsoe Research Institute and the universities of Bristol, Leeds and Oxford.
According to the Robot Sheepdog Project website:
This may sound straightforward, but nothing like it has ever been tried before; we had to design the robot, guess the correct mathematical model, and implement it whilst ensuring that the ducks were never harmed! To do this we first relied a lot on simulation, and on seeing whether the mathematical model gave simulated results that “looked right” to expert duck herders. Finally, the system was tried with real ducks, and was shown to be capable of herding a flock of ducks from one end of an arena to a specified position at the other end.
The Spatial Reasoning research group is continuing the research work, but using robot sheep as well as robot sheepdogs to extend the theories without the complications of dealing with real animals.
The project uses a collection of small wheeled mobile robots, each of which can act as a sheep or a dog. The “sheep” behave according to a pre-programmed flocking model, whereas the “dogs” are controlled through an external PC. The dogs can be driven by a human using a joystick, or can be programmed to herd the sheep to a predetermined point.
Fascinating… but why go to so much effort when real sheepdogs do this work so well? According to an article published by Simon Frasier University:
The sheepdog’s gather-and-fetch task was chosen because of its familiarity and the strong interaction between the dog, shepherd and flock animals. Using ducks instead of sheep allows us to experiment on a conveniently small scale, in a controlled indoor environment. Duck flocking behaviour is recognised by shepherds as similar to sheep; ducks are often used to train sheepdogs because of their relatively slow movement.
Flocking is considered an adaptive behaviour, as it a affords various advantages in hazard-avoidance, mating and foraging. Models of flocking behaviour exist in the literature and are generally derived from Hamilton’s observation that flocking may be produced by the mass action of individual animals, each seeking the proximity of its nearest neighbours.
Similar models have produced realistic computer animations of bird flocks. The best-known of these is Boids. Boids, developed by Craig Reynolds in 1986, is an artificial life program, simulating the flocking behaviour of birds. From Wikipedia:
As with most artificial life simulations, Boids is an example of emergent behavior; that is, the complexity of Boids arises from the interaction of individual agents (the boids, in this case) adhering to a set of simple rules. The rules applied in the simplest Boids world are as follows:
- separation : steer to avoid crowding local flockmates
- alignment : steer towards the average heading of local flockmates
- cohesion : steer to move toward the average position of local flockmates
More complex rules can be added, such as obstacle avoidance and goal seeking.
A Boids Java applet that allows you to change program inputs and includes optional predators is available here. If you tweak it a bit you can program it to have one predator that ‘herds’ boids that get separated back into the flock.