Live data from Hacker News

NetLogo – A multi-agent programmable modeling environment

ccl.northwestern.edu

21–30 of 35 posts

Re: NetLogo – A multi-agent programmable modeling environment

#21
post #13
post #6

> NetLogo is a multi-agent programmable modeling environment. What does that even mean? That description fits nearly every commonly used programming language and runtime.

Most programming languages don't use the multi-agent paradigm. It's a different way of thinking about problems, in which you describe how each type of agent should interact with others, and then you let them run and play out the scenario. It's true that you can implement multi-agent programming in other languages, but it's very natural and clear in NetLogo. PS: I did my PhD in the group that produces NetLogo, and con…

I am in a research group that does ecological modelling, so I've heard a fair bit about NetLogo, though I haven't used it myself.

I quite like its approach - like you say, it's a very natural way to do agent-based modelling. I also think its a good beginners' language for modellers who know their field (e.g. ecology) but haven't yet learnt how to program. Lastly, I like it's GUI integration.

However, I am somewhat put off by its verbose "toy language" syntax; and I really can't afford its performance. (We are currently working on a model in Julia, and even that can take up to several weeks to compute a single run on our HPC...) So I guess my opinion is that its a fantastic language to learn about modelling, but not well suited to constructing large, complex and resource-intensive models.

Re: NetLogo – A multi-agent programmable modeling environment

#22
post #11

I worked with a grad student in college who was building models in NetLogo for modeling drug overdoses. It was pretty janky and slow. They had to run the model millions of times so I had to build NetLogo on our HPC cluster running Rocks OS and write some magic config in slurm to run it and it took for ever because about 1/3 of the jobs would fail because they ran out of ram and would need to be run again. I’m not sur…

As for the performance aspect, these kinds of simulations (typically using fixed time steps and with per-agent decision-making) are a natural fit for many-core devices. We recently did a survey on that subject [1]. There is a lot of work being done along these lines right now. Some groups are also trying to target sequential, parallel and, say, GPU execution from the same model specification language, which could act…

This is interesting. We've been thinking quite a bit about parallelising our model, but haven't managed it yet. The problem is that although our agents are mostly independent of each other, they all depend on the shared state of the world (and modify this, too).

Therefore, if we were to use a multiprocessing setup, we would have to be able to lock the world object when a process is writing to it; and furthermore, find a way to pass it around in memory so that all processes have read access to it. While we know that it should be technically doable, the latency overhead of the latter has proven prohibitively high.

Re: NetLogo – A multi-agent programmable modeling environment

#23
post #16

For anyone who'd like to try out NetLogo without installing it, you can run example models and play with the code online in NetLogo Web: https://www.netlogoweb.org/launch#https://www.netlogoweb.org...

Ironically, if I click that link on mobile it downloads a file

Re: NetLogo – A multi-agent programmable modeling environment

#24
post #21
post #13

Earlier quoted context omitted.

Most programming languages don't use the multi-agent paradigm. It's a different way of thinking about problems, in which you describe how each type of agent should interact with others, and then you let them run and play out the scenario. It's true that you can implement multi-agent programming in other languages, but it's very natural and clear in NetLogo. PS: I did my PhD in the group that produces NetLogo, and con…

I am in a research group that does ecological modelling, so I've heard a fair bit about NetLogo, though I haven't used it myself. I quite like its approach - like you say, it's a very natural way to do agent-based modelling. I also think its a good beginners' language for modellers who know their field (e.g. ecology) but haven't yet learnt how to program. Lastly, I like it's GUI integration. However, I am somewhat pu…

Is there a language you would recommend as the next step for someone who has learned NetLogo? One with better syntax and performance? Maybe a Julia library?

Re: NetLogo – A multi-agent programmable modeling environment

#25
post #22

Earlier quoted context omitted.

As for the performance aspect, these kinds of simulations (typically using fixed time steps and with per-agent decision-making) are a natural fit for many-core devices. We recently did a survey on that subject [1]. There is a lot of work being done along these lines right now. Some groups are also trying to target sequential, parallel and, say, GPU execution from the same model specification language, which could act…

This is interesting. We've been thinking quite a bit about parallelising our model, but haven't managed it yet. The problem is that although our agents are mostly independent of each other, they all depend on the shared state of the world (and modify this, too). Therefore, if we were to use a multiprocessing setup, we would have to be able to lock the world object when a process is writing to it; and furthermore, fin…

Yeah, for some models, especially small-scale ones, it can be hard to get a performance gain. There are actually ways of avoiding the locking, e.g., by staging the desired actions and then carrying them out afterwards, resolving conflicts as needed. We actually have a paper on this as well, but I'm going to stop pushing my research at this point ;)

Re: NetLogo – A multi-agent programmable modeling environment

#26
During our graduation period we used Netlogo for projects of distributed networks. It was lots of fun to do different simulations. I remember writing Ant Colongy Optimization and Firefly Synchronization with it and being able to visually see and tweak parameters.

Re: NetLogo – A multi-agent programmable modeling environment

#27
Years ago I wrote an application which was essentially a neural circuit of a sea slug (they only eat and forage) with my now wife.

https://austingwalters.com/modeling-and-building-robotic-sea...

We then showed how (using netlogo) how when another neural circuit for aggressive behavior was added (but the connections of the markov chain had yet to be trained) the sea slugs. After adding the aggressive circuit and letting generations live and die using a genetic algorithm - it appeared to observers like the animals became social. I.e. only the territorial sea slugs remained, and they wouldn’t attack ones of the same species, this proved to be the best for “survival”.

The goal of the work was to provide insight into what neural circuits can lead to social behavior. Specifically, what environmental conditions can lead to an evolutionary trait that triggers social like behaviors.

Honestly, idk if you can make any “claims”, but it was a fun undergraduate project. The best part is we exported the trained models from the Netlogo program, then imported them into a lego robot. At which point our robot had learned to be aggressive - I.e. would “chase” people away from the food source.

Re: NetLogo – A multi-agent programmable modeling environment

#28
post #2

What other languages provide this kind of model output? It's very interesting.

There is a GPU accelerated particle simulator from Yoshiki Oshima and a few other people. It can run in browsers.

http://tinlizzie.org/~ohshima/shadama2/live2017/

A bit tricky due to shader limitations, but very fast. You can use a million particles at a time. This is a product of HARC/VPRI cooperation, from what I understand.

Re: NetLogo – A multi-agent programmable modeling environment

#29
post #13
post #6

> NetLogo is a multi-agent programmable modeling environment. What does that even mean? That description fits nearly every commonly used programming language and runtime.

Most programming languages don't use the multi-agent paradigm. It's a different way of thinking about problems, in which you describe how each type of agent should interact with others, and then you let them run and play out the scenario. It's true that you can implement multi-agent programming in other languages, but it's very natural and clear in NetLogo. PS: I did my PhD in the group that produces NetLogo, and con…

Would you mind explaining the difference and comparing with the Actor Model paradigm?

Re: NetLogo – A multi-agent programmable modeling environment

#30
post #2

What other languages provide this kind of model output? It's very interesting.

You can use the RePast Suite ( https://repast.github.io/ ).

I used both of them about 10 years ago when I was in academia in a PostDoc. I taught Agent Based Modelling and Simulation to Social Sciences PhD Students. I also had the opportunity to work with Klaus Troitzsch ( https://en.wikipedia.org/wiki/Klaus_G._Troitzsch).

These kind of models yield really interesting results. But people have to be VERY careful on how to interpret their outcomes, as some people make the mistake to try to take them as direct forecasting. Also, they suffer very much from the garbage-in/garbage-out problem.

Post reply on HN