MathGroup Archive 2011

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: ParallelMap in FindMinimum getting slower

  • To: mathgroup at smc.vnet.net
  • Subject: [mg122044] Re: ParallelMap in FindMinimum getting slower
  • From: Oliver Ruebenkoenig <ruebenko at wolfram.com>
  • Date: Mon, 10 Oct 2011 05:53:21 -0400 (EDT)
  • Delivered-to: l-mathgroup@mail-archive0.wolfram.com
  • References: <201110070848.EAA07424@smc.vnet.net> <Pine.LNX.4.63.1110070439250.26775@wopr.wolfram.com>

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
>
>



  • Prev by Date: Re: Rank of a matrix depending on a
  • Next by Date: Re: Inequality
  • Previous by thread: Re: ParallelMap in FindMinimum getting slower
  • Next by thread: Re: ParallelMap in FindMinimum getting slower