Hi Jean-Claude<div><br></div><div>One quick thing to try is to put the contents of the loop inside if a function call.  This should make it more obvious to oython's garbage collector that the variables defined inside are temporary.</div>
<div><br></div><div>Nathan<span></span><br><br>On Sunday, March 2, 2014, Jean-Claude Passy <<a href="mailto:jcpassy@gmail.com">jcpassy@gmail.com</a>> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div style="word-wrap:break-word">Hi everyone,<div><br></div><div>I am trying to analyze a unigrid simulation, 512^3 zones. Each dump has a size of ~ 7 GB.</div><div>I use the following script to get the angular momenta:</div>
<div><br></div><div><a href="http://paste.yt-project.org/show/4340/" target="_blank">http://paste.yt-project.org/show/4340/</a></div><div><br></div><div>I am running it on a cluster with 1 core and 16GB. It typically runs fine for the first 2 dumps, then crashes on the third one when asking for AngularMomentumZ. I assume that I must not erase variables correctly. Does someone have any suggestion about how to optimize the script?</div>
<div><br></div><div>Also, would that make sense to run the script in parallel or would the root grid be duplicated on all processors?</div><div><br></div><div>Sorry for the naive questions, and thanks a lot for the help!</div>
<div>Cheers,</div><div><br></div><div>JC</div></div></blockquote></div>