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

commits-noreply at bitbucket.org commits-noreply at bitbucket.org
Thu Jan 15 14:56:09 PST 2015


2 new commits in yt:

https://bitbucket.org/yt_analysis/yt/commits/bf6cfd550f1e/
Changeset:   bf6cfd550f1e
Branch:      yt
User:        MatthewTurk
Date:        2015-01-15 18:35:07+00:00
Summary:     RAMSES has incorrectly-ordered blocks.

This conditionally reorders blocks if they need to be; as RAMSES seems to be
the only frontend that has internally F-ordered blocks, it currently only
applies to RAMSES.
Affected #:  2 files

diff -r e29ff6c5259c8ecae04e30bac953325df5b58645 -r bf6cfd550f1e825a23972864de38ff33e4e7924c yt/data_objects/octree_subset.py
--- a/yt/data_objects/octree_subset.py
+++ b/yt/data_objects/octree_subset.py
@@ -54,6 +54,7 @@
     _con_args = ('base_region', 'domain', 'ds')
     _domain_offset = 0
     _cell_count = -1
+    _block_reorder = None
 
     def __init__(self, base_region, domain, ds, over_refine_factor = 1):
         self._num_zones = 1 << (over_refine_factor)
@@ -435,7 +436,10 @@
         pass
 
     def __getitem__(self, key):
-        return self.octree_subset[key][:,:,:,self.ind]
+        rv = self.octree_subset[key][:,:,:,self.ind]
+        if self.octree_subset._block_reorder:
+            rv = rv.copy(order=self.octree_subset._block_reorder)
+        return rv
 
     def get_vertex_centered_data(self, *args, **kwargs):
         raise NotImplementedError

diff -r e29ff6c5259c8ecae04e30bac953325df5b58645 -r bf6cfd550f1e825a23972864de38ff33e4e7924c yt/frontends/ramses/data_structures.py
--- a/yt/frontends/ramses/data_structures.py
+++ b/yt/frontends/ramses/data_structures.py
@@ -304,6 +304,7 @@
 class RAMSESDomainSubset(OctreeSubset):
 
     _domain_offset = 1
+    _block_reorder = "F"
 
     def fill(self, content, fields, selector):
         # Here we get a copy of the file, which we skip through and read the


https://bitbucket.org/yt_analysis/yt/commits/d8422e8e79c7/
Changeset:   d8422e8e79c7
Branch:      yt
User:        ngoldbaum
Date:        2015-01-15 22:56:00+00:00
Summary:     Merged in MatthewTurk/yt (pull request #1410)

Fix RAMSES block ordering
Affected #:  2 files

diff -r 5c027fcfa0473fe86a66b2cc4c6fc272c41cb14d -r d8422e8e79c7100aabf71f7a0f7cfc9367eee177 yt/data_objects/octree_subset.py
--- a/yt/data_objects/octree_subset.py
+++ b/yt/data_objects/octree_subset.py
@@ -54,6 +54,7 @@
     _con_args = ('base_region', 'domain', 'ds')
     _domain_offset = 0
     _cell_count = -1
+    _block_reorder = None
 
     def __init__(self, base_region, domain, ds, over_refine_factor = 1):
         self._num_zones = 1 << (over_refine_factor)
@@ -435,7 +436,10 @@
         pass
 
     def __getitem__(self, key):
-        return self.octree_subset[key][:,:,:,self.ind]
+        rv = self.octree_subset[key][:,:,:,self.ind]
+        if self.octree_subset._block_reorder:
+            rv = rv.copy(order=self.octree_subset._block_reorder)
+        return rv
 
     def get_vertex_centered_data(self, *args, **kwargs):
         raise NotImplementedError

diff -r 5c027fcfa0473fe86a66b2cc4c6fc272c41cb14d -r d8422e8e79c7100aabf71f7a0f7cfc9367eee177 yt/frontends/ramses/data_structures.py
--- a/yt/frontends/ramses/data_structures.py
+++ b/yt/frontends/ramses/data_structures.py
@@ -304,6 +304,7 @@
 class RAMSESDomainSubset(OctreeSubset):
 
     _domain_offset = 1
+    _block_reorder = "F"
 
     def fill(self, content, fields, selector):
         # Here we get a copy of the file, which we skip through and read the

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