[yt-svn] commit/yt: chummels: Merged in brittonsmith/yt (pull request #1630)
commits-noreply at bitbucket.org
commits-noreply at bitbucket.org
Thu Jul 9 10:12:23 PDT 2015
1 new commit in yt:
https://bitbucket.org/yt_analysis/yt/commits/a518935d5cfe/
Changeset: a518935d5cfe
Branch: yt
User: chummels
Date: 2015-07-09 17:12:12+00:00
Summary: Merged in brittonsmith/yt (pull request #1630)
[bugfix] Two minor Rockstar bugs (closes Issue #1041 and Issue #1042)
Affected #: 2 files
diff -r 8e7a932ed5cf0b086e38e9527f125b6e47e760a6 -r a518935d5cfec05f3c75c23b68c0f8f715a0391e yt/frontends/rockstar/data_structures.py
--- a/yt/frontends/rockstar/data_structures.py
+++ b/yt/frontends/rockstar/data_structures.py
@@ -73,7 +73,7 @@
int(os.stat(self.parameter_filename)[stat.ST_CTIME])
prefix = ".".join(self.parameter_filename.rsplit(".", 2)[:-2])
self.filename_template = "%s.%%(num)s%s" % (prefix, self._suffix)
- self.file_count = len(glob.glob(prefix + "*" + self._suffix))
+ self.file_count = len(glob.glob(prefix + ".*" + self._suffix))
# Now we can set up things we already know.
self.cosmological_simulation = 1
diff -r 8e7a932ed5cf0b086e38e9527f125b6e47e760a6 -r a518935d5cfec05f3c75c23b68c0f8f715a0391e yt/frontends/rockstar/io.py
--- a/yt/frontends/rockstar/io.py
+++ b/yt/frontends/rockstar/io.py
@@ -91,6 +91,7 @@
morton = np.empty(pcount, dtype='uint64')
mylog.debug("Initializing index % 5i (% 7i particles)",
data_file.file_id, pcount)
+ if pcount == 0: return morton
ind = 0
with open(data_file.filename, "rb") as f:
f.seek(data_file._position_offset, os.SEEK_SET)
@@ -108,7 +109,7 @@
# domain edges. This helps alleviate that.
np.clip(pos, self.ds.domain_left_edge + dx,
self.ds.domain_right_edge - dx, pos)
- #del halos
+ del halos
if np.any(pos.min(axis=0) < self.ds.domain_left_edge) or \
np.any(pos.max(axis=0) > self.ds.domain_right_edge):
raise YTDomainOverflow(pos.min(axis=0),
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