Re: [julia-users] Re: PriorityQueue for fast large network simulation

2016-07-12 Thread Rainer J. Engelken
many dimensions has your 'array' (is it a vector, a matrix ..)? >> On each iteration, do you want to find the value of smallest element in >> the array or the location(s) of the smallest element or both? >> On each iteration, are the entries that are to be altered sequential or &g

Re: [julia-users] Re: PriorityQueue for fast large network simulation

2016-07-12 Thread Rainer J. Engelken
distributed in 1:n. In my case k=10^2, n=10^8. Looking forward to suggestions, Regards Rainer > On Thursday, June 30, 2016 at 6:14:57 PM UTC-4, Rainer J. Engelken wrote: >> >> Hi, >> I am trying to implement a fast event-based numerically exact >> simulation of a spa

Re: [julia-users] PriorityQueue for fast large network simulation

2016-07-02 Thread Rainer J. Engelken
> > perhaps you could build a heap out of the > to-be-updated neurons and then perform a "heap-merge." > > http://link.springer.com/article/10.1007%2FBF00264229 > Thanks @Tim, a complexity of *O*(k+log(n)*log(k)) instead of *O*(k*log(n)) would indeed speed things up! I will try it, when I have

Re: [julia-users] PriorityQueue for fast large network simulation

2016-07-01 Thread Rainer J. Engelken
2016-07-01 11:41 GMT+02:00 Tim Holy : > My guess is that you could do better by doing a "batch update" of the > queue, > so that you don't rebalance the heap each time. > > @Tim, thanks for responding, maybe I didn't get your idea. How does changing the priority of x*k keys

[julia-users] PriorityQueue for fast large network simulation

2016-07-01 Thread Rainer J. Engelken
Hi, I am trying to implement a fast event-based numerically exact simulation of a sparse large spiking neural network using a priority queue. It is fast, but not fast enough. Profiling indicates that the bottleneck seem to be the dictionary operations keyindex and setindex! when changing

[julia-users] PriorityQueue for fast large network simulation

2016-06-30 Thread Rainer J. Engelken
Hi, I am trying to implement a fast event-based numerically exact simulation of a sparse large spiking neural network using a priority queue. It is fast, but not fast enough. Profiling indicates that the bottleneck seem to be the dictionary operations keyindex and setindex! when changing priority