[yt-svn] commit/yt-3.0: 3 new changesets
commits-noreply at bitbucket.org
commits-noreply at bitbucket.org
Tue Mar 19 14:08:26 PDT 2013
3 new commits in yt-3.0:
https://bitbucket.org/yt_analysis/yt-3.0/commits/0e5c5352ce0d/
changeset: 0e5c5352ce0d
branch: yt-3.0
user: MatthewTurk
date: 2013-03-19 19:54:05
summary: Go back to just_one for data['dx']. Fixes #532.
affected #: 2 files
diff -r e4852e262442f29c5b2b30b8c5b8d38a2750ebef -r 0e5c5352ce0dd97d2b629d0ea21c4172ac54d0aa yt/data_objects/universal_fields.py
--- a/yt/data_objects/universal_fields.py
+++ b/yt/data_objects/universal_fields.py
@@ -946,7 +946,7 @@
data["particle_position_x"].size,
blank, np.array(data.LeftEdge).astype(np.float64),
np.array(data.ActiveDimensions).astype(np.int32),
- np.float64(data['dx']))
+ just_one(data['dx']))
return blank
add_field("particle_density", function=_pdensity,
validators=[ValidateGridType()], convert_function=_convertDensity,
diff -r e4852e262442f29c5b2b30b8c5b8d38a2750ebef -r 0e5c5352ce0dd97d2b629d0ea21c4172ac54d0aa yt/frontends/enzo/fields.py
--- a/yt/frontends/enzo/fields.py
+++ b/yt/frontends/enzo/fields.py
@@ -361,7 +361,7 @@
np.int64(np.where(filter)[0].size),
blank, np.array(data.LeftEdge).astype(np.float64),
np.array(data.ActiveDimensions).astype(np.int32),
- np.float64(data['dx']))
+ just_one(data['dx']))
return blank
add_field("star_density", function=_spdensity,
validators=[ValidateSpatial(0)], convert_function=_convertDensity)
@@ -383,7 +383,7 @@
num,
blank, np.array(data.LeftEdge).astype(np.float64),
np.array(data.ActiveDimensions).astype(np.int32),
- np.float64(data['dx']))
+ just_one(data['dx']))
return blank
add_field("dm_density", function=_dmpdensity,
validators=[ValidateSpatial(0)], convert_function=_convertDensity)
@@ -404,7 +404,7 @@
data["particle_position_x"].size,
top, np.array(data.LeftEdge).astype(np.float64),
np.array(data.ActiveDimensions).astype(np.int32),
- np.float64(data['dx']))
+ just_one(data['dx']))
del particle_field_data
bottom = np.zeros(data.ActiveDimensions, dtype='float32')
@@ -415,7 +415,7 @@
data["particle_position_x"].size,
bottom, np.array(data.LeftEdge).astype(np.float64),
np.array(data.ActiveDimensions).astype(np.int32),
- np.float64(data['dx']))
+ just_one(data['dx']))
top[bottom == 0] = 0.0
bnz = bottom.nonzero()
top[bnz] /= bottom[bnz]
@@ -445,7 +445,7 @@
np.int64(np.where(filter)[0].size),
top, np.array(data.LeftEdge).astype(np.float64),
np.array(data.ActiveDimensions).astype(np.int32),
- np.float64(data['dx']))
+ just_one(data['dx']))
del particle_field_data
bottom = np.zeros(data.ActiveDimensions, dtype='float32')
@@ -456,7 +456,7 @@
np.int64(np.where(filter)[0].size),
bottom, np.array(data.LeftEdge).astype(np.float64),
np.array(data.ActiveDimensions).astype(np.int32),
- np.float64(data['dx']))
+ just_one(data['dx']))
top[bottom == 0] = 0.0
bnz = bottom.nonzero()
top[bnz] /= bottom[bnz]
https://bitbucket.org/yt_analysis/yt-3.0/commits/ac8bc6a91206/
changeset: ac8bc6a91206
branch: yt-3.0
user: MatthewTurk
date: 2013-03-19 22:02:21
summary: Adding suggestion from Nathan for the filter = None fix.
affected #: 1 file
diff -r 0e5c5352ce0dd97d2b629d0ea21c4172ac54d0aa -r ac8bc6a9120690f7e8223fa1bc7f32c9eced7805 yt/frontends/enzo/fields.py
--- a/yt/frontends/enzo/fields.py
+++ b/yt/frontends/enzo/fields.py
@@ -374,7 +374,7 @@
if not filter.any(): return blank
num = filter.sum()
else:
- filter = None
+ filter = Ellipsis
num = data["particle_position_x"].size
amr_utils.CICDeposit_3(data["particle_position_x"][filter].astype(np.float64),
data["particle_position_y"][filter].astype(np.float64),
https://bitbucket.org/yt_analysis/yt-3.0/commits/cc46e0009c84/
changeset: cc46e0009c84
branch: yt-3.0
user: ngoldbaum
date: 2013-03-19 22:08:20
summary: Merged in MatthewTurk/yt-3.0 (pull request #22)
Go back to just_one for data['dx']. Fixes #532.
affected #: 2 files
diff -r e13c58124602c20675ac73b5b3e9548b5f5b034b -r cc46e0009c84f96b6a3f85836b97a06a9eabd846 yt/data_objects/universal_fields.py
--- a/yt/data_objects/universal_fields.py
+++ b/yt/data_objects/universal_fields.py
@@ -948,7 +948,7 @@
data["particle_position_x"].size,
blank, np.array(data.LeftEdge).astype(np.float64),
np.array(data.ActiveDimensions).astype(np.int32),
- np.float64(data['dx']))
+ just_one(data['dx']))
return blank
add_field("particle_density", function=_pdensity,
validators=[ValidateGridType()], convert_function=_convertDensity,
diff -r e13c58124602c20675ac73b5b3e9548b5f5b034b -r cc46e0009c84f96b6a3f85836b97a06a9eabd846 yt/frontends/enzo/fields.py
--- a/yt/frontends/enzo/fields.py
+++ b/yt/frontends/enzo/fields.py
@@ -361,7 +361,7 @@
np.int64(np.where(filter)[0].size),
blank, np.array(data.LeftEdge).astype(np.float64),
np.array(data.ActiveDimensions).astype(np.int32),
- np.float64(data['dx']))
+ just_one(data['dx']))
return blank
add_field("star_density", function=_spdensity,
validators=[ValidateSpatial(0)], convert_function=_convertDensity)
@@ -374,7 +374,7 @@
if not filter.any(): return blank
num = filter.sum()
else:
- filter = None
+ filter = Ellipsis
num = data["particle_position_x"].size
amr_utils.CICDeposit_3(data["particle_position_x"][filter].astype(np.float64),
data["particle_position_y"][filter].astype(np.float64),
@@ -383,7 +383,7 @@
num,
blank, np.array(data.LeftEdge).astype(np.float64),
np.array(data.ActiveDimensions).astype(np.int32),
- np.float64(data['dx']))
+ just_one(data['dx']))
return blank
add_field("dm_density", function=_dmpdensity,
validators=[ValidateSpatial(0)], convert_function=_convertDensity)
@@ -404,7 +404,7 @@
data["particle_position_x"].size,
top, np.array(data.LeftEdge).astype(np.float64),
np.array(data.ActiveDimensions).astype(np.int32),
- np.float64(data['dx']))
+ just_one(data['dx']))
del particle_field_data
bottom = np.zeros(data.ActiveDimensions, dtype='float32')
@@ -415,7 +415,7 @@
data["particle_position_x"].size,
bottom, np.array(data.LeftEdge).astype(np.float64),
np.array(data.ActiveDimensions).astype(np.int32),
- np.float64(data['dx']))
+ just_one(data['dx']))
top[bottom == 0] = 0.0
bnz = bottom.nonzero()
top[bnz] /= bottom[bnz]
@@ -445,7 +445,7 @@
np.int64(np.where(filter)[0].size),
top, np.array(data.LeftEdge).astype(np.float64),
np.array(data.ActiveDimensions).astype(np.int32),
- np.float64(data['dx']))
+ just_one(data['dx']))
del particle_field_data
bottom = np.zeros(data.ActiveDimensions, dtype='float32')
@@ -456,7 +456,7 @@
np.int64(np.where(filter)[0].size),
bottom, np.array(data.LeftEdge).astype(np.float64),
np.array(data.ActiveDimensions).astype(np.int32),
- np.float64(data['dx']))
+ just_one(data['dx']))
top[bottom == 0] = 0.0
bnz = bottom.nonzero()
top[bnz] /= bottom[bnz]
Repository URL: https://bitbucket.org/yt_analysis/yt-3.0/
--
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