[yt-svn] commit/yt: 3 new changesets
commits-noreply at bitbucket.org
commits-noreply at bitbucket.org
Mon Dec 8 09:56:17 PST 2014
3 new commits in yt:
https://bitbucket.org/yt_analysis/yt/commits/59fe69fa6fbe/
Changeset: 59fe69fa6fbe
Branch: yt
User: ngoldbaum
Date: 2014-12-04 01:09:26+00:00
Summary: Avoid triggering a FutureWarning in numpy when comparing with None.
Affected #: 1 file
diff -r 9d96ac2cfc308468239e99e88552a704168291e0 -r 59fe69fa6fbe1b20850823b3e0e22cd54a84b0ab yt/data_objects/static_output.py
--- a/yt/data_objects/static_output.py
+++ b/yt/data_objects/static_output.py
@@ -681,7 +681,8 @@
self.length_unit / self.time_unit)
self.unit_registry.modify("code_velocity", vel_unit)
# domain_width does not yet exist
- if None not in (self.domain_left_edge, self.domain_right_edge):
+ if (self.domain_left_edge is not None and
+ self.domain_right_edge is not None):
DW = self.arr(self.domain_right_edge - self.domain_left_edge, "code_length")
self.unit_registry.add("unitary", float(DW.max() * DW.units.cgs_value),
DW.units.dimensions)
https://bitbucket.org/yt_analysis/yt/commits/92578327669e/
Changeset: 92578327669e
Branch: yt
User: ngoldbaum
Date: 2014-12-04 01:09:54+00:00
Summary: Avoid triggering a Unicode error in matplotlib by passing a float instead of a numpy flaot
Affected #: 1 file
diff -r 59fe69fa6fbe1b20850823b3e0e22cd54a84b0ab -r 92578327669e859d5d605a5dc5711250882f8818 yt/visualization/plot_window.py
--- a/yt/visualization/plot_window.py
+++ b/yt/visualization/plot_window.py
@@ -701,8 +701,8 @@
# This will likely be replaced at some point by the coordinate handler
# setting plot aspect.
if self.aspect is None:
- self.aspect = np.float64((self.ds.quan(1.0, unit_y) /
- self.ds.quan(1.0, unit_x)).in_cgs())
+ self.aspect = float((self.ds.quan(1.0, unit_y) /
+ self.ds.quan(1.0, unit_x)).in_cgs())
extentx = [(self.xlim[i] - xc).in_units(unit_x) for i in (0, 1)]
extenty = [(self.ylim[i] - yc).in_units(unit_y) for i in (0, 1)]
https://bitbucket.org/yt_analysis/yt/commits/e2419cd7c329/
Changeset: e2419cd7c329
Branch: yt
User: MatthewTurk
Date: 2014-12-08 17:56:08+00:00
Summary: Merged in ngoldbaum/yt (pull request #1334)
Avoid triggering warnings in recent versions of NumPy and matplotlib
Affected #: 2 files
diff -r 134ea7c1c9e8cba1d8845449a000a282ce201a99 -r e2419cd7c32929d3fdfa8d4077f280dfaa17bbcf yt/data_objects/static_output.py
--- a/yt/data_objects/static_output.py
+++ b/yt/data_objects/static_output.py
@@ -681,7 +681,8 @@
self.length_unit / self.time_unit)
self.unit_registry.modify("code_velocity", vel_unit)
# domain_width does not yet exist
- if None not in (self.domain_left_edge, self.domain_right_edge):
+ if (self.domain_left_edge is not None and
+ self.domain_right_edge is not None):
DW = self.arr(self.domain_right_edge - self.domain_left_edge, "code_length")
self.unit_registry.add("unitary", float(DW.max() * DW.units.cgs_value),
DW.units.dimensions)
diff -r 134ea7c1c9e8cba1d8845449a000a282ce201a99 -r e2419cd7c32929d3fdfa8d4077f280dfaa17bbcf yt/visualization/plot_window.py
--- a/yt/visualization/plot_window.py
+++ b/yt/visualization/plot_window.py
@@ -701,8 +701,8 @@
# This will likely be replaced at some point by the coordinate handler
# setting plot aspect.
if self.aspect is None:
- self.aspect = np.float64((self.ds.quan(1.0, unit_y) /
- self.ds.quan(1.0, unit_x)).in_cgs())
+ self.aspect = float((self.ds.quan(1.0, unit_y) /
+ self.ds.quan(1.0, unit_x)).in_cgs())
extentx = [(self.xlim[i] - xc).in_units(unit_x) for i in (0, 1)]
extenty = [(self.ylim[i] - yc).in_units(unit_y) for i in (0, 1)]
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