[yt-svn] commit/yt: 3 new changesets

commits-noreply at bitbucket.org commits-noreply at bitbucket.org
Fri May 24 12:04:57 PDT 2013


3 new commits in yt:

https://bitbucket.org/yt_analysis/yt/commits/fd5f619b47b2/
Changeset:   fd5f619b47b2
Branch:      yt
User:        brittonsmith
Date:        2013-05-24 20:45:58
Summary:     Adding some garbage collecting that seems to cut down on running out of ram.
Affected #:  1 file

diff -r 361d94fa50422ad7a7b966a0d26f8b318228a830 -r fd5f619b47b226524ec0468a85712ca28b30c8d9 yt/analysis_modules/halo_profiler/multi_halo_profiler.py
--- a/yt/analysis_modules/halo_profiler/multi_halo_profiler.py
+++ b/yt/analysis_modules/halo_profiler/multi_halo_profiler.py
@@ -23,6 +23,7 @@
   along with this program.  If not, see <http://www.gnu.org/licenses/>.
 """
 
+import gc
 import numpy as np
 import os
 import h5py
@@ -583,7 +584,7 @@
 
             r_min = 2 * self.pf.h.get_smallest_dx() * self.pf['mpc']
             if (halo['r_max'] / r_min < PROFILE_RADIUS_THRESHOLD):
-                mylog.error("Skipping halo with r_max / r_min = %f." % (halo['r_max']/r_min))
+                mylog.debug("Skipping halo with r_max / r_min = %f." % (halo['r_max']/r_min))
                 return None
 
             # get a sphere object to profile
@@ -630,6 +631,7 @@
                 g.clear_data()
             sphere.clear_data()
             del sphere
+            gc.collect()
 
         return profile
 


https://bitbucket.org/yt_analysis/yt/commits/90656a353747/
Changeset:   90656a353747
Branch:      yt
User:        brittonsmith
Date:        2013-05-24 20:57:40
Summary:     Adding a comment about the reason for inserting a garbage collecting call.
Affected #:  1 file

diff -r fd5f619b47b226524ec0468a85712ca28b30c8d9 -r 90656a3537473693d696ee35544e0df5d29b47e1 yt/analysis_modules/halo_profiler/multi_halo_profiler.py
--- a/yt/analysis_modules/halo_profiler/multi_halo_profiler.py
+++ b/yt/analysis_modules/halo_profiler/multi_halo_profiler.py
@@ -631,6 +631,9 @@
                 g.clear_data()
             sphere.clear_data()
             del sphere
+            # Currently, this seems to be the only way to prevent large 
+            # halo profiling runs from running out of ram.
+            # It would be good to track down the real cause at some point.
             gc.collect()
 
         return profile


https://bitbucket.org/yt_analysis/yt/commits/853203f07769/
Changeset:   853203f07769
Branch:      yt
User:        MatthewTurk
Date:        2013-05-24 21:04:50
Summary:     Merged in brittonsmith/yt (pull request #513)

Adding a call to gc.collect to help with memory issues when profiling large datasets.
Affected #:  1 file

diff -r 60046485a0dc33d42d5b5fa770f098ddc20c2fed -r 853203f07769bae913f3f391bbef64689944d823 yt/analysis_modules/halo_profiler/multi_halo_profiler.py
--- a/yt/analysis_modules/halo_profiler/multi_halo_profiler.py
+++ b/yt/analysis_modules/halo_profiler/multi_halo_profiler.py
@@ -23,6 +23,7 @@
   along with this program.  If not, see <http://www.gnu.org/licenses/>.
 """
 
+import gc
 import numpy as np
 import os
 import h5py
@@ -583,7 +584,7 @@
 
             r_min = 2 * self.pf.h.get_smallest_dx() * self.pf['mpc']
             if (halo['r_max'] / r_min < PROFILE_RADIUS_THRESHOLD):
-                mylog.error("Skipping halo with r_max / r_min = %f." % (halo['r_max']/r_min))
+                mylog.debug("Skipping halo with r_max / r_min = %f." % (halo['r_max']/r_min))
                 return None
 
             # get a sphere object to profile
@@ -630,6 +631,10 @@
                 g.clear_data()
             sphere.clear_data()
             del sphere
+            # Currently, this seems to be the only way to prevent large 
+            # halo profiling runs from running out of ram.
+            # It would be good to track down the real cause at some point.
+            gc.collect()
 
         return profile

Repository URL: https://bitbucket.org/yt_analysis/yt/

--

This is a commit notification from bitbucket.org. You are receiving
this because you have the service enabled, addressing the recipient of
this email.



More information about the yt-svn mailing list