Change data to specified layout.
(self, layout)
| 649 | copyto(self.data, old_data) |
| 650 | |
| 651 | def change_layout(self, layout): |
| 652 | """Change data to specified layout.""" |
| 653 | layout = self.dist.get_layout_object(layout) |
| 654 | # Transform to specified layout |
| 655 | if self.layout.index < layout.index: |
| 656 | while self.layout.index < layout.index: |
| 657 | #self.domain.distributor.increment_layout(self) |
| 658 | self.towards_grid_space() |
| 659 | elif self.layout.index > layout.index: |
| 660 | while self.layout.index > layout.index: |
| 661 | #self.domain.distributor.decrement_layout(self) |
| 662 | self.towards_coeff_space() |
| 663 | |
| 664 | def towards_grid_space(self): |
| 665 | """Change to next layout towards grid space.""" |