[yt-svn] commit/yt: brittonsmith: Decreasing verbosity of halo profiler.
Bitbucket
commits-noreply at bitbucket.org
Fri Jun 22 18:26:39 PDT 2012
1 new commit in yt:
https://bitbucket.org/yt_analysis/yt/changeset/1fca3c207443/
changeset: 1fca3c207443
branch: yt
user: brittonsmith
date: 2012-06-23 03:26:12
summary: Decreasing verbosity of halo profiler.
affected #: 2 files
diff -r efa0d8be8d6503222c750018d8545005ff8f0db8 -r 1fca3c20744392aff4a8e5b20e4b5efa420d72fc yt/analysis_modules/halo_profiler/halo_filters.py
--- a/yt/analysis_modules/halo_profiler/halo_filters.py
+++ b/yt/analysis_modules/halo_profiler/halo_filters.py
@@ -111,11 +111,11 @@
if (not (na.array(overDensity) >= virial_overdensity).any()) and \
must_be_virialized:
- mylog.error("This halo is not virialized!")
+ mylog.debug("This halo is not virialized!")
return [False, {}]
if (len(overDensity) < 2):
- mylog.error("Skipping halo with no valid points in profile.")
+ mylog.debug("Skipping halo with no valid points in profile.")
return [False, {}]
if (overDensity[1] <= virial_overdensity):
@@ -133,7 +133,7 @@
for field in fields:
if (overDensity[index+1] - overDensity[index]) == 0:
- mylog.error("Overdensity profile has slope of zero.")
+ mylog.debug("Overdensity profile has slope of zero.")
return [False, {}]
else:
slope = (temp_profile[field][index+1] - temp_profile[field][index]) / \
diff -r efa0d8be8d6503222c750018d8545005ff8f0db8 -r 1fca3c20744392aff4a8e5b20e4b5efa420d72fc 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
@@ -1105,7 +1105,10 @@
"Read radial profile from file. Return None if it doesn't have all the fields requested."
profile = {}
- in_file = h5py.File(profileFile, 'r')
+ try:
+ in_file = h5py.File(profileFile, 'r')
+ except IOError:
+ return None
if not 'RadiusMpc-1d' in in_file:
return None
my_group = in_file['RadiusMpc-1d']
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