160 likes | 480 Views
ABM: Frameworks. Dr Andy Evans. ABM Frameworks. What are they? Pieces of software to help people build ABMs. Often offer the functions outlined. Wide range of tools: Pre-written functions. Entire graphical environment. Somewhere in the middle. Why use them?. For non-programmers:
E N D
ABM: Frameworks Dr Andy Evans
ABM Frameworks What are they? Pieces of software to help people build ABMs. Often offer the functions outlined. Wide range of tools: Pre-written functions. Entire graphical environment. Somewhere in the middle
Why use them? For non-programmers: Graphical “point-and-click” model development. Easier than having to learn a programming language. For programmers: No need to write ‘external’ functionality (e.g. drawing graphs, scheduling events, creating displays). Can concentrate on model logic. Save time (?)
Commonly Used Platforms Netlogo: http://ccl.northwestern.edu/netlogo/ Repast: http://repast.sourceforge.net/ MASON: http://cs.gmu.edu/~eclab/projects/mason/ Ascape: http://ascape.sourceforge.net/ ABLE: http://www.research.ibm.com/able/ Modelling4All: http://www.modelling4all.org/ SecondLife: http://secondlife.com/ Agent Analyst: http://www.spatial.redlands.edu/agentanalyst/
Recursive Porous Agent Simulation Toolkit (RePast) Argonne National Laboratory. Based on Swarm. Includes a Logo-based language, ReLogo and graphical programming. Imports NetLogo. Largely Java programmed. Includes 3D GIS using GeoTools. Two main versions: Simphony (Java etc.) RePast for HPC (C++) (MPI based) Based on Eclipse.
Functionality Flexible scheduling including synchronised and event-based scheduling. Randomisation toolkit. Monte Carlo simulation framework. Different spaces and boundaries, including multiple spaces at once.
Functionality Links with R, Weka, GRASS, Pajek. Libraries for genetic algorithms, neural networks, regression, random number generation, and specialized mathematics: http://repast.sourceforge.net/docs/RepastSimphonyFAQ.pdf Exports model shapefiles. Exports applications.
Integration with other java import repast.simphony.runtime.RepastMain; String[] args = new String[]{"C:/myModel/scenario.rs"}; RepastMain.main(args);
Example Predictive Model: Burglary Simulation GIS/ABM Crime Model Burglar agents situated in an environment that mimics Leeds Agents use roads, railways and public transport to travel around the city burgling real buildings
Repast SimphonyContexts and Projections Organise agents and their relationships. Contexts A ‘bucket’ to hold all agents. No relationships, “agent soup”. Sub-contexts allow more fine-grained control. Projections Define relationships between agents in a context. Can be spatial, social etc. All relationships external to the agents themselves.
Contexts and Projections Agents can have multiple Projections at once.
Loose Coupling GIS prepare input for model and display/analyse results. Model does not need to communicate with GIS directly. Quick: ABM not constrained by speed of GIS. e.g. Repast Simphony
Tight Coupling GIS and ABM communicate directly. At each iteration the ABM updates GIS on new system state. GIS can display model state dynamically. e.g. Agent Analyst in ArcGIS http://www.institute.redlands.edu/AgentAnalyst/ Integrates RePast into ArcGIS.
RePast HPC Utilises MPI rather than shared memory. Ticks are synchronised across all machines. Can program in a logo-like version of C++ or C++.
Why not use a framework? Overheads: sometimes there are better ways of doing the same job if that’s all you have to do. For example, RePast’s watch timing is quite heavy but makes sense as a general framework. Constraints: sometimes it is hard to squeeze a model into a Framework’s way of doing things, let alone then move it to a different framework.