Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.soft-sys.math.mathematica > #5581

Re: ParallelMap in FindMinimum getting slower

From Oliver Ruebenkoenig <ruebenko@wolfram.com>
Newsgroups comp.soft-sys.math.mathematica
Subject Re: ParallelMap in FindMinimum getting slower
Date 2011-10-10 09:54 +0000
Organization Steven M. Christensen and Associates, Inc and MathTensor, Inc.
Message-ID <j6ufbq$gfe$1@smc.vnet.net> (permalink)
References <201110070848.EAA07424@smc.vnet.net> <Pine.LNX.4.63.1110070439250.26775@wopr.wolfram.com>

Show all headers | View raw


On Fri, 7 Oct 2011, Rafael Reiter wrote:

> Hi,
>
> find the file attached. You can just hit "Evaluate Notebook".
> I noticed in top that the used memory is also increasing all the time. I 
> guess the distributed data gets bigger and bigger, but what is it?
>
> Rafael


I do not have the time to read you notebook in all detail. Here are some 
random ideas:

- Use $HistoryLength = 0 (also evaluated via ParallelEvaluate)
- Some of the data you pass around are not packed arrays: e.g. try


Bloch[nkx_, nky_] := Developer`ToPackedArray[N[BlochH /. kx -> nkx /. ky 
-> nky]];

- Also the path data contains integer and reals. Perhaps that could be 
avoided.

- After //Chop use //N//Developer`ToPackedArray

- Perhaps replace the Module with Block

Hope this contains the right clue.
Oliver

>
> On 07.10.2011 11:39, Oliver Ruebenkoenig wrote:
>> On Fri, 7 Oct 2011, Rafael Reiter wrote:
>> 
>>> Hi everyone,
>>> 
>>> I use ParallelMap with Mathematica on Linux to solve 100 eigenvalue
>>> problems on 4 kernels. This operation ist repeated very often by
>>> FindMinimum, and over the course of time the performance drops
>>> significantly. Using top, you can see that the CPU used by the master
>>> kernel increases, and the CPU used by the slave kernels decreases from
>>> 70 to appr. 20 percent. Has anyone else experienced this phenomenon?
>>> 
>>> Best wishes,
>>> Rafael
>>> 
>>> 
>> 
>> Can you send the example?
>> 
>> Oliver
>
>

Back to comp.soft-sys.math.mathematica | Previous | Next | Find similar | Unroll thread


Thread

Re: ParallelMap in FindMinimum getting slower Oliver Ruebenkoenig <ruebenko@wolfram.com> - 2011-10-10 09:54 +0000

csiph-web