[yt-svn] commit/yt: MatthewTurk: Fixing Dark Sky bounding box specification so that regions can work.
commits-noreply at bitbucket.org
commits-noreply at bitbucket.org
Thu Feb 23 15:27:10 PST 2017
1 new commit in yt:
https://bitbucket.org/yt_analysis/yt/commits/25651334863b/
Changeset: 25651334863b
Branch: yt
User: MatthewTurk
Date: 2017-02-23 22:33:54+00:00
Summary: Fixing Dark Sky bounding box specification so that regions can work.
Also, update the `None` check so that we don't do elementwise object
comparison in the future.
Affected #: 1 file
diff -r ff20b94f7f7b5bba93a0fa1f26beeebf82ecf8ae -r 25651334863bc48cb35ca88070de8aa8c5ffd855 yt/frontends/sdf/data_structures.py
--- a/yt/frontends/sdf/data_structures.py
+++ b/yt/frontends/sdf/data_structures.py
@@ -78,7 +78,7 @@
unit_system="cgs"):
if bounding_box is not None:
self._subspace = True
- bbox = np.array(bounding_box, dtype="float32")
+ bbox = np.array(bounding_box, dtype="float64")
if bbox.shape == (2, 3):
bbox = bbox.transpose()
self.domain_left_edge = bbox[:,0]
@@ -121,8 +121,7 @@
except:
self.unique_identifier = time.time()
-
- if None in (self.domain_left_edge, self.domain_right_edge):
+ if self.domain_left_edge is None or self.domain_right_edge is None:
R0 = self.parameters['R0']
if 'offset_center' in self.parameters and self.parameters['offset_center']:
self.domain_left_edge = np.array([0, 0, 0], dtype=np.float64)
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