[yt-svn] commit/yt: 3 new changesets
commits-noreply at bitbucket.org
commits-noreply at bitbucket.org
Wed Sep 21 13:05:02 PDT 2016
3 new commits in yt:
https://bitbucket.org/yt_analysis/yt/commits/622db9a56038/
Changeset: 622db9a56038
Branch: yt
User: MatthewTurk
Date: 2016-09-09 17:53:40+00:00
Summary: Don't try to read non-existent files in Tipsy.
Affected #: 1 file
diff -r c07d12bf5903b40c0c6e65a8ea8f28a82f142e1d -r 622db9a56038743a16a3f278a4c48ca2fdf1076f yt/frontends/tipsy/io.py
--- a/yt/frontends/tipsy/io.py
+++ b/yt/frontends/tipsy/io.py
@@ -325,6 +325,7 @@
for f in glob.glob(data_file.filename + '.*')]
for afield in self._aux_fields:
filename = data_file.filename + '.' + afield
+ if not os.path.exists(filename): continue
# We need to do some fairly ugly detection to see what format the
# auxiliary files are in. They can be either ascii or binary, and
# the binary files can be either floats, ints, or doubles. We're
https://bitbucket.org/yt_analysis/yt/commits/fdb8c94bd145/
Changeset: fdb8c94bd145
Branch: yt
User: MatthewTurk
Date: 2016-09-09 20:40:52+00:00
Summary: Change this to avoid adding to _aux_fields at all
Affected #: 1 file
diff -r 622db9a56038743a16a3f278a4c48ca2fdf1076f -r fdb8c94bd1454e58e031657c37e8dfa023080bdf yt/frontends/tipsy/io.py
--- a/yt/frontends/tipsy/io.py
+++ b/yt/frontends/tipsy/io.py
@@ -321,11 +321,14 @@
tot_parts = np.sum(list(data_file.total_particles.values()))
endian = data_file.ds.endian
self._aux_pdtypes = {}
- self._aux_fields = [f.rsplit('.')[-1]
- for f in glob.glob(data_file.filename + '.*')]
+ self._aux_fields = []
+ for f in glob.glob(data_file.filename + '.*'):
+ afield = f.rsplit('.')[-1]
+ filename = data_file.filename + '.' + afield
+ if not os.path.exists(filename): continue
+ self._aux_fields.append(afield)
for afield in self._aux_fields:
filename = data_file.filename + '.' + afield
- if not os.path.exists(filename): continue
# We need to do some fairly ugly detection to see what format the
# auxiliary files are in. They can be either ascii or binary, and
# the binary files can be either floats, ints, or doubles. We're
https://bitbucket.org/yt_analysis/yt/commits/3c53eabd6afd/
Changeset: 3c53eabd6afd
Branch: yt
User: ngoldbaum
Date: 2016-09-21 20:04:34+00:00
Summary: Merged in MatthewTurk/yt (pull request #2370)
Don't try to read non-existent tipsy auxiliarry files
Affected #: 1 file
diff -r 779b91714ae713783313de0932f459f78bd34a31 -r 3c53eabd6afdccb7bfc120884ff5014dfa599a2d yt/frontends/tipsy/io.py
--- a/yt/frontends/tipsy/io.py
+++ b/yt/frontends/tipsy/io.py
@@ -321,8 +321,12 @@
tot_parts = np.sum(list(data_file.total_particles.values()))
endian = data_file.ds.endian
self._aux_pdtypes = {}
- self._aux_fields = [f.rsplit('.')[-1]
- for f in glob.glob(data_file.filename + '.*')]
+ self._aux_fields = []
+ for f in glob.glob(data_file.filename + '.*'):
+ afield = f.rsplit('.')[-1]
+ filename = data_file.filename + '.' + afield
+ if not os.path.exists(filename): continue
+ self._aux_fields.append(afield)
for afield in self._aux_fields:
filename = data_file.filename + '.' + afield
# We need to do some fairly ugly detection to see what format the
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