[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Swarm-Support] Optimisation of Simulations
From: |
K a |
Subject: |
Re: [Swarm-Support] Optimisation of Simulations |
Date: |
Tue, 07 Jun 2005 02:40:47 -0800 |
Hi,
Paul, what you suggested there has improved the performation of my model
drastically! Thanks very much!
A further question about performance. It seems like, now, what's dragging the
performance is updating of the graphs (including EZGraph and Graph). This may
be because I'm giving it an agent list as such to plot the average:
graph.createAverageSequence$withFeedFrom$andSelector("Average", agentList, sel);
...
graph.step();
...
I was wondering if there's a similar way which can improve the speed when
plotting these.
Any help would be great. Thanks!
Kel
>
> Greetings from Sunny Italy, Where SwarmFest 2005 is in session. It
> is the Funnest Meeting Ever.
>
> I don't know about the crash you are seeing, but instead of fixing
> it, I suggest you just redesign.
>
> I THINK the slowdown you are noticing is recognized and can be
> addressed in other ways. The slowdown results from the fact that
> Swarm does not know what type of agents you have. So one approach
> is to change your model to use the homogeneous nature of the
> collection to accelerate processing.
>
> http://www.ku.edu/~pauljohn/SwarmFaq/WorkingExampleCode/java/ActionForEachHomogeneous.txt
>
> Also consult here:
>
> http://www.ku.edu/~pauljohn/SwarmFaq/Memos/
>
> See files "MarcusCreateActions..."
>
> Honestly, it might be the easiest thing to just keep your
> collection away from the schedule altogether. Write a method in
> ModelSwarm that loops over the agents. Then put that method on the
> schedule. This is generally much much faster than any variant of
> createActionForEach.
>
> pj
>
> K a wrote:
> > Hello All,
> >
> > -Swarm2.2, Java, Windows
> > Having built a model and run, I get the following error:
> >
> > ==================================================
> > *** event raised for error: InvalidArgument
> > *** function: _i_Object_s__doesNotRecognize_(), file:
> > /src/swarm/src/defobj/DefObject.m, line: 825
> > JavaClassProxy does not recognize interact
> > *** execution terminating due to error
> > /src/swarm/src/defobj/Symbol.m:187 -[Error(c) _raiseEvent:]
> > ==================================================
> >
> > Please could anyone advise on what is going on with this error?
> >
> > Note: I only get this error when, in my ModelSwarm class, I build
> > action messages sent individually to every object in a List,
> > using createActionTo$message. When I use
> > createActionForEach$message on the collection, it seems to work.
> >
> > The reason why I'm trying with createActionTo$message is because
> > I think my simulation runs considerably faster this way. Using
> > the ForEach initialisation seems to be slower.
> >
> > Any advice welcome. Thanks a lot.
> > Kel
> >
> >
>
>
> -- Paul E. Johnson email: address@hidden
> Dept. of Political Science http://lark.cc.ku.edu/~pauljohn
> 1541 Lilac Lane, Rm 504
> University of Kansas Office: (785) 864-9086
> Lawrence, Kansas 66044-3177 FAX: (785) 864-5700
> _______________________________________________
> Support mailing list
> address@hidden
> http://www.swarm.org/mailman/listinfo/support
--
_______________________________________________
NEW! Lycos Dating Search. The only place to search multiple dating sites at
once.
http://datingsearch.lycos.com
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Re: [Swarm-Support] Optimisation of Simulations,
K a <=