190 likes | 205 Views
Explore evolving behavior of agents to direct flock movement, similar to sheepdog role. Enhance livestock herding techniques through simulation. Research on flocking algorithms, robotic handling, and behavior determination systems. Utilizing Python and tKinter for coding. Study on herd simulation and herding behavior. Strategies like separation, cohesion, alignment, and genetic code implementation. Analyzing different strategies like "Bubble," "Slow," "Southeast," "Spinning wheel," and "Wall-bounce." Evaluation based on proximity to flock goal. Applications in animation and livestock management.
E N D
Evolving Cutting Horse and Sheepdog Behavior on a Simulated Flock Chris Beacham
Abstract • The focus of this project is attempting to evolve the behavior of a single agent or small group of agents so that they can effectively direct the movement of a much larger group which displays flocking behavior. This is the same role sheepdogs play to manage herds of livestock.
Other Research • There has been little development in this specific field. • Flocking algorithm is well established, but is hard to direct. • Robotic Sheepdog Project: Proof of Concept for robotic handling of livestock
Uses • Two main Applications: Animation – Control direction of flocks in animations, currently no good method exists Livestock Herding: Could be used in a robotic agent to actually herd livestock. Could reduce livestock stress.
Programming Tools • Python is being used for the code, with tKinter providing the graphics. • Breve was looked at as a possibility, but it was dismissed for being to complex and not documented.
Precursors • Initially, an evolution program was written to fine tune the authors understanding of artificial evolution. • This is a genepool of evolved creatures using user selection
Sheepdog and Cutting Horse • The sheepdog directs the movements of sheep, ducks, cows, goats and other herd stock. It accomplishes this by moving around the herd or flock in specific ways. • The cutting horse is used with herds of cattle. It’s job is to single out a single cow, and “cut” it off from the herd, thus allowing people to access it.
Flocking • The herd will be simulated with a flocking algorithm. • Three algorithms make up flocking behavior: • Separation • Cohesion • Alignment
First Quarter • The first quarter was spent creating a flocking behavior simulation, and debugging it. • This is a screenshot of a flock flying to the right.
Second Quarter • Herding behavior established. Same algorithm as flocking.
Second Quarter • Herd reacting to ‘predator’ • Sheepdog agent very simple at this point
Second Quarter • Which behavior determination system to use? • Neural Networks v. Cellular Automaton v. Weighting • Pros and Cons for all options
Second Quarter • Weighting method chosen as best behavior determination system. • Genetic code adds weight to different variables. • Pros • Many strategies can be produced • Should be reproducible in other situations • Cons • Nowhere near the possibilities for innovation of neural nets.
Second Quarter • First generation sheepdog behavior is randomly generated. Movement is very chaotic.
First Generation [32.164006627541823, -19.261148559544093, 28.838154710926517, -2.6177442818239252, -1.610540774960918, -3.0347756036751052, -20.931229810205998, 5.7627079638362986, 1.7473837471501998, 7.7198793790136833], [-11.470881676551826, 28.336696618106188, 38.987209868269673, 2.4890967130213557, -0.078896899902183293, 4.0279192032567082, 38.113753797435876, -9.9091943197785568, 6.0767013600522422, 22.90210747684651], [19.524480722525141, 17.865021602410764, 35.768937982290353, 2.5848421326612847, 1.7679235149952088, 1.780983430333368, 35.344660445143845, 8.9854097668224071, 0.58138734205464693, 19.580526983833721], [14.652628528856667, 37.731823468942835, 16.911577862190441, 0.4858339804315932, 4.2518008367774591, -4.8959446134369822, -12.527178547904271, -23.834582722704489, 2.5735304563845185, 10.983380384038441], [-37.365308224600689, -26.219646166636444, 23.837388022611961, -2.6502990318154742, 2.5285789988460721, -1.9174224730964582, -4.8617111048341215, -27.040194863370225, 5.3442590210258247, 47.707995016754595], [-47.83280830026532, -27.746753711795826, -22.465210886399479, -1.8834401853055285, -4.6526740112824712, 2.1138389668398263, 4.7442060317506503, 13.681368603073729, 1.7036710633058849, -24.335868677880825], [31.332197286921499, 37.788533831872257, -45.919434849424789, 0.48534266655833669, -3.3026128229853424, -1.7377195224251816, 7.2576919556413912, -36.199633586541836, 4.8382490300740457, 4.0074023699981822], [3.2210497987682132, 10.765683943559381, -24.469857259276651, -1.9355065069590394, -0.61633090971086801, -3.1878785380980879, 41.904929197287117, 3.5243513927757348, 5.4548537085994404, 12.247444295078616], • This is a sample of the genetic pool of the first generation.
Third Quarter • Breeding program and Automated testing program produced. • Breeding program designed for very heavy selection pressure • Agents evaluated on how close they get the flock to the goal.
Third Quarter • Several strategies predominate • “Bubble” strategy • “Slow” strategy • “Southeast” strategy • “Spinning wheel” strategy • “Wall-bounce” strategy – suspect disconnect between graphical output and nongraphical output
Are any Strategies Viable? • Two applications: Animations and Livestock • Livestock – Possible, but unknown. Real experience needed. • Animation – depends on application. Some strategies significantly distort flock shape
Continued Development • Expected to continue over the summer • Three main goals • Simulated flock to reflect real flock movement • More vectors in weighing system • Modification of breeding algorithm for more biodiversity • Also, simulation is computationally intensive, so need to secure a location to run it long-term.