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

commits-noreply at bitbucket.org commits-noreply at bitbucket.org
Thu May 25 05:52:35 PDT 2017


2 new commits in yt:

https://bitbucket.org/yt_analysis/yt/commits/106ddfd5e2f1/
Changeset:   106ddfd5e2f1
User:        John Zuhone
Date:        2017-05-24 20:15:03+00:00
Summary:     Make sure we create the particle_ones field even if we don't have a particle_mass field
Affected #:  1 file

diff -r 24e049078e06a910fd24d8a24faf970196ae178c -r 106ddfd5e2f10788c8f510e18d08b04aa0874265 yt/fields/particle_fields.py
--- a/yt/fields/particle_fields.py
+++ b/yt/fields/particle_fields.py
@@ -190,7 +190,7 @@
     # Now some translation functions.
 
     def particle_ones(field, data):
-        v = np.ones(data[ptype, mass_name].shape, dtype="float64")
+        v = np.ones(data[ptype, coord_name].shape[0], dtype="float64")
         return data.apply_units(v, field.units)
 
     registry.add_field((ptype, "particle_ones"),


https://bitbucket.org/yt_analysis/yt/commits/ad734750c432/
Changeset:   ad734750c432
User:        ngoldbaum
Date:        2017-05-25 12:52:25+00:00
Summary:     Merge pull request #1424 from jzuhone/particle_ones_fix

[bugfix] Create the particle_ones field even if we don't have a particle mass field
Affected #:  1 file

diff -r 24e049078e06a910fd24d8a24faf970196ae178c -r ad734750c43236b14d3a19f4eff5389a63eb4524 yt/fields/particle_fields.py
--- a/yt/fields/particle_fields.py
+++ b/yt/fields/particle_fields.py
@@ -190,7 +190,7 @@
     # Now some translation functions.
 
     def particle_ones(field, data):
-        v = np.ones(data[ptype, mass_name].shape, dtype="float64")
+        v = np.ones(data[ptype, coord_name].shape[0], dtype="float64")
         return data.apply_units(v, field.units)
 
     registry.add_field((ptype, "particle_ones"),

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