Tabela de conteúdos
Repast
The Recursive Porous Agent Simulation Toolkit (Repast) is one of several agent modeling toolkits that are available. Repast borrows many concepts from the Swarm [and] is differentiated from Swarm since Repast has multiple pure implementations in several languages and built-in adaptive features such as genetic algorithms and regression.
Homepage | http://repast.sourceforge.net |
---|---|
Origin | University of Chicago |
Year | 2000 |
Version | Alpha 1 |
License | GNU-GPL |
Language | Java, .Net, python |
There are fixed and flexible components. The fixed are the Engine, Logging, and Interactive and Batch Run Modules. The Engine contains Engine Controller, Scheduler, Action, and Agent components. The logging has a Data and an Objects Logger. Data logger store simple values, and Objects store the full state of each agent.
The batch module can be controlled by a Parameter Sweep Framework, that iterates over a range of model input parameters to complete a set of simulation runs.
The Adaptive Behaviors Module provides adaptive components for implementing agent behaviors. The components can include genetic algorithms, neural networks, other artificial intelligence tools, and regression tools. The Domains Module provides area-specific functions. Example components include tools for general networks, social systems, geographical information systems (GIS), systems dynamics, and computational game theory.
Simphony
The Repast Organization for Architecture and Design (ROAD) is pleased to announce the release of Repast Simphony 1.0! We thank the Repast core developers, contributing developers, and supporters for the hard work that made this release possible!
As many know, Repast Simphony is a free and open source agent-based modeling toolkit that offers users a rich variety of features including the following:
- An optional point-and-click model development environment that generates Java classes and seamlessly integrates with hand written Java and Groovy components.
- A pure Java point-and-click model execution environment that includes built-in results logging and graphing tools as well as automated connections to a variety of optional external tools including R, VisAD, Weka, popular spreadsheets, MATLAB, and iReport.
- An extremely flexible hierarchically nested definition of space including the ability to do point-and-click and modeling and visualization of 2D environments, 3D environments, networks including full integration with the JUNG network modeling library, and geographical spaces including full Geographical Information Systems (GIS) support.
- A range of data storage “freeze dryers” for model check pointing and restoration including text file and database storage.
- A fully concurrent multithreaded discrete event scheduler.
- Libraries for genetic algorithms, neural networks, regression, random number generation, and specialized mathematics.
- Automated Monte Carlo simulation framework which supports multiple modes of model results optimization.
- Built-in tools for integrating external models.
- Fully object-orientation.
- Availability on virtually all modern computing platforms including Windows, Mac OS, and Linux.
More information on Repast Simphony can be found on the main web site: http://repast.sourceforge.net
Documentation, including a step-by-step tutorial, can be found here: http://repast.sourceforge.net/docs/docs_main.html
Downloads can be found here: http://repast.sourceforge.net/download.html
Thank you for your continuing interest in Repast!
Mike
Michael J. North, MBA, Ph.D.
Papers
The Repast Simulation/Modelling System for Geospatial Simulation
A T Crooks, 2007 | UCL Working Papers Series |
Abstract: The use of simulation/modelling systems can simplify the implementation of agent-based models. Repast is one of the few simulation/modelling software systems that supports the integration of geospatial data especially that of vector-based geometries. This paper provides details about Repast specifically an overview, including its different development languages available to develop agent-based models. Before describing Repast’s core functionality and how models can be developed within it, specific emphasis will be placed on its ability to represent dynamics and incorporate geographical information. Once these elements of the system have been covered, a diverse list of Agent-Based Modelling (ABM) applications using Repast will be presented with particular emphasis on spatial applications utilizing Repast, in particular, those that utilize geospatial data.
The current implementation of GIS functionality within Repast is focused on two systems: ESRI’s ArcGIS via the Agent Analyst extension and the open source software OpenMap. While both rely on ESRI shapefiles, the type of integration between the agent-based model and the GIS are different. Repast has shapefile integration with ArcGIS and native Java integration with OpenMap (Najlis and North, 2004).
Experiences Creating Three Implementations of the Repast Agent Modeling Toolkit
M. J. North and N. T. Collier and J. R. Vos, 2006 | ACM Transactions on Modeling and Computer Simulation (TOMACS) | 21 citations in Scholar |
Many agent-based modeling and simulation researchers and practitioners have called for varying levels of simulation interoperability ranging from shared software architectures to common agent communications languages. These calls have been at least partially answered by several specifications and technologies. In fact, Tanenbaum [1988] has remarked that the “nice thing about standards is that there are so many to choose from.” Tanenbaum goes on to say that “if you do not like any of them, you can just wait for next year’s model.” This article does not seek to introduce next year’s model. Rather, the goal is to contribute to the larger simulation community the authors’ accumulated experiences from developing several implementations of an agent-based simulation toolkit. As such, this article focuses on the implementation of simulation architectures rather than agent communications languages. It is hoped that ongoing architecture standards efforts will benefit from this new knowledge and use it to produce architecture standards with increased robustness.
The paper describes the three implementations (Java, .Net, python), showing advantages and disadvantages of each implementation. It also shows a set of groups that work with repast and their scientific questions. How do national borders emerge and why do they take the shapes that they do? How did ancient people build their tools and why did they use the approaches that were chosen?
An introduction to repast simphony modeling using a simple predator-prey example
E. Tatara, M.J. North, T.R. Howe, N.T. Collier, J.R. Vos, 2006 | Agent 2006 - Conference on Social Agents: Results and Prospects |
We implement a model of wolf-sheep predation (Wilenski 1998) in Repast S as a demonstration of the toolkit’s capabilities. This model represents a simple variation of predator prey behavior using three agents: wolves, sheep, and grass. Both the wolves and sheep move randomly on a grid, and the movement has a cost in the form of lost energy. The wolves and sheep need to eat food in order to replenish their energy, and they will die once their energy level reaches zero.
Wolves prey on sheep and may eat them if the two are located in the same spatial position, thereby increasing the wolf’s energy level. Sheep may similarly eat grass if the sheep is located on a patch which contains living grass. Once a sheep eats the grass in its location, the grass needs to regrow before the sheep can eat it again. Repast S models a re-grow rate for grass by counting down after the grass has been eaten in a specific location. Reproduction is modeled by a random process that creates a child from the parent, divides the energy of the parent agent in half, and assigns the energy equally to the parent and child.
The movement do not use the concept of neighbourhood:
public void move() { Context context = ContextUtils.getContext(this); Grid grid = (Grid) context.getProjection(“Simple Grid”); GridDimensions dims = grid.getDimensions(); GridPoint point = grid.getLocation(this); x = point.getX() + (int) Math.round(2*Math.random() - 1); y = point.getY() + (int) Math.round(2*Math.random() - 1); grid.move(this, x, y); }
It returns the agents in the same cell using a function getObjectsAt() which needs a position in the space:
Sheep sheep = null; for (SimpleAgent agent : grid.getObjectsAt(x,y)){ if (agent instanceof Sheep) sheep = (Sheep) agent; } if (sheep != null){ sheep.die(); energy = energy + gain; }
doing
RePast supports the exchange of data between agents. Work is currently underway to support group-based communication
RePast supports various sorts of spatial relationships (2D, 3D, hexagonal grids, hexagonal tori, vector spaces, raster spaces, etc.). Work is underway on a GIS library that will contain additional geographic operators. There are simple positioning algorithms as well as simple influence spaces
GIS Integration: (e.g. OpenMap, Java Topology Suite, and GeoTools). Repast simulations can also be run within ArcGIS through an extension called Agent Analyst (http://www.institute.redlands.edu/agentanalyst).
graphing/statistics: (e.g. Colt statistical package, and basic Repast functionality for simple network statistics)
Repast development appears to have been driven by several objectives. The initial objective was to implement Swarm, or equivalent functionality, in Java. However, Repast did not adopt all of Swarm’s design philosophy and does not implement swarms. Repast was also clearly intended to support one domain - social science - in particular, and includes tools specific to that domain. The additional objective of making it easier for inexperienced users to build models has been approached in several ways by the Repast project. These approaches include a built-in simple model, and interfaces through which menus and Python code can be used to begin model construction.
The Repast Simphony Development Environment
M.J. North and T.R. Howe and N.T. Collier and J.R. Vos, 2005 | Agent 2005 Conference |
Abstract: Repast is a widely used free and open-source agent-based modeling and simulation toolkit. Three Repast platforms are currently available, each of which has the same core features but a different environment for these features. Repast Simphony (Repast S) extends the Repast portfolio by offering a new approach to simulation development and execution. The Repast S development environment is expected to include advanced features for agent behavioral specification and dynamic model self-assembly. This paper introduces the architecture and core features of the Repast S development environment. A related paper in the Agent 2005 conference proceedings by the same authors that is titled “Repast Simphony Runtime System” discusses the Repast S model execution environment.
The Repast Simphony Runtime System
M.J. North and T.R. Howe and N.T. Collier and J.R. Vos, 2005 | Agent 2005 Conference |
Abstract: Repast is a widely used free and open-source agent-based modeling and simulation toolkit. Three Repast platforms are currently available, namely, Repast for Java (Repast J), Repast for the Microsoft .NET framework (Repast .NET), and Repast for Python Scripting (Repast Py). Each of these platforms has the same core features. However, each platform provides a different environment for these features. Taken together, the Repast platform portfolio gives modelers a choice of model development and execution environments. Repast Simphony (Repast S) extends the Repast portfolio by offering a new approach to simulation development and execution. The Repast S runtime is designed to include advanced features for agent storage, display, and behavioral activation, as well as new facilities for data analysis and presentation. This paper introduces the architecture and core features of the Repast S runtime system and discusses how Repast S fits within the larger Repast portfolio. A related paper in this Agent 2005 conference proceedings by the same authors, “Repast Simphony Development Environment,” discusses the Repast S model authoring system.
The GeoGraph 3D Computational Laboratory: Network and Terrain Landscapes for Repast
Dibble, C. and Feldman, P.G. 2004 | JASSS | html | 10 citations in Scholar |
Abstract: Our GeoGraph 3D extensions to the RePast agent-based simulation platform support models in which mobile agents travel and interact on rugged terrain or on network landscapes such as social networks of established organizational teams or spatial networks at any scale from rooms within buildings to urban neighborhoods to large geographic networks of cities. Interactive GeoGraph 3D visualizations allow researchers to zoom and pan within the simulation landscape as the model runs. Model-specific 3D representations of agents flock together on terrain landscapes, and teleport or travel along links on network landscapes. Agents may be displayed on network nodes either as individual agents or as dynamic 3D bar charts that reflect the composition of each node's population. Batch modes support scientific control via fully separated random number series, customized parameter combinations, and automatic data collection for many thousands of simulation runs. This paper introduces the GeoGraph 3D computational laboratory and briefly describes three representative GeoGraph models along with basic GeoGraph 3D capabilities and components.
It has an example of a model of SARS, where individual agents travel between communities and bar charts for each community show the epidemiological status. Green agents are healthy, pink are infected, red are sick, gray are dead, and white are recovered and immune. Gray links are base links, such as highways or trains, yellow links are high-speed shortcuts in the landscape such as airline routes.
Multiple agents per node, and agents to interacting both directly and indirectly. The figure includes an undulating mesh network enhanced by several spatial small-world shortcuts. The ring around each agent shows how far it can see.
Series of classes that allow for the creation and observation of teams of agents that behave as social hierarchies. For each layer of responsibility in the organization, there can be a specific type of Hierarchy Agent that fills that role. These agents have additional capabilities that allow for command and message passing to follow a chain of command. To support this, the simulation can show visualizations of these communication links in a variety of contexts, ranging from lines drawn between the members of the group, to group coloration, to tree views that show the hierarchy by group member name, command, and status.
GeoGraph provides three classes of proto-agents, from which agents may inherit specific geographic capabilities that correspond to classes of GeoGraph landscapes.
- GeoAgent3D: knows how to navigate networks. It may evaluate nodes within a network-specific neighborhood, and may also compute shortest paths from one node to another along multiple links.
- FreeAgent3D: moves between nodes without following links.
- NodelessAgent3D: a free roaming agent. provides the basis for the Flocking agents.
TerraME: just having different neighbourhood types. The problem arises when we have time associated to moving in the space, according to the weight of the link.
GeoGraphs can import network landscapes and corresponding territorial outline maps from shape files. The original version of GeoGraphs was built for Swarm.
Agent-Based Simulation Comes of Age
D A Samuelson and C M Macal, 2006 | ORMS Today |
software toolkits released within the last few years have made agent-based modeling easy enough to be attractive to many practitioners from a variety of subject areas.
Triggering actions
I have two trigger actions in my SynapseAgent class as below. Basically when its neuron is excited (when its potential is equal to 30) synapses are activated to conduct the neuronal signal to postsynaptic neurons with a delay of 2 time steps because of axonal delay and processing time of synapses. However, axonal delay can change is some circumstances. In this sense, how can I re-schedule my SynapseAgent's trigger methods? Or, should I remove this synapse agent and create a new one? There is a DefaultTriggerAction class but I am not sure how to use it. Is there sample codes (I couldn't find one).
Thanks in advace,
Önder.
public class SynapseAgent { /** * Initially, it takes 10 time steps to process the signal. */ @Watch(watcheeClassName = "wiringexperiment001.SensoryNeuronAgent", watcheeFieldNames = "potential", query = "linked_from", triggerCondition = "$watchee.getPotential() == 30", whenToTrigger = WatcherTriggerSchedule.LATER, scheduleTriggerDelta = 2d) public void activate() { System.out.println("activate! " + RunEnvironment.getInstance().getCurrentSchedule().getTickCount()); Network<Object> network = WiringExperiment001Utility.getNetwork(this); Iterable<RepastEdge<Object>> outEdges = network.getOutEdges(this); Iterator<RepastEdge<Object>> outEdgeIterator = outEdges.iterator(); while (outEdgeIterator.hasNext()) { RepastEdge<Object> edge = outEdgeIterator.next(); edge.setWeight(30); } } @Watch(watcheeClassName = "wiringexperiment001.SensoryNeuronAgent", watcheeFieldNames = "potential", query = "linked_from", triggerCondition = "$watchee.getPotential() == -70", whenToTrigger = WatcherTriggerSchedule.LATER, scheduleTriggerDelta = 2d) public void deactivate() { System.out.println("deactivate! " + RunEnvironment.getInstance().getCurrentSchedule().getTickCount()); Network<Object> network = WiringExperiment001Utility.getNetwork(this); Iterable<RepastEdge<Object>> outEdges = network.getOutEdges(this); Iterator<RepastEdge<Object>> outEdgeIterator = outEdges.iterator(); while (outEdgeIterator.hasNext()) { RepastEdge<Object> edge = outEdgeIterator.next(); edge.setWeight(-70); } } }