[yt-svn] commit/yt: samskillman: Changing array to asarray to save a memory copy
commits-noreply at bitbucket.org
commits-noreply at bitbucket.org
Sun Nov 23 15:35:55 PST 2014
1 new commit in yt:
https://bitbucket.org/yt_analysis/yt/commits/a4ada3e56dfb/
Changeset: a4ada3e56dfb
Branch: yt
User: samskillman
Date: 2014-11-23 21:06:04+00:00
Summary: Changing array to asarray to save a memory copy
Affected #: 1 file
diff -r ced032076b2023a9365e33838d1a215fdbeacb09 -r a4ada3e56dfb45de2e6a85c5069cf4b11d7238f0 yt/frontends/stream/data_structures.py
--- a/yt/frontends/stream/data_structures.py
+++ b/yt/frontends/stream/data_structures.py
@@ -492,7 +492,7 @@
data = new_data
elif all([iterable(val) for val in data.values()]):
field_units = {field:'' for field in data.keys()}
- data = dict((field, np.array(val)) for field, val in data.iteritems())
+ data = dict((field, np.asarray(val)) for field, val in data.iteritems())
else:
raise RuntimeError("The data dict appears to be invalid. "
"The data dictionary must map from field "
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