Skip to content
Snippets Groups Projects

WIP: Graph datahandling

Closed Stephan Seitz requested to merge seitz/pystencils:graph-datahandling into master
Files
2
@@ -42,6 +42,9 @@ class DataTransfer:
@@ -42,6 +42,9 @@ class DataTransfer:
self.field = field
self.field = field
self.kind = kind
self.kind = kind
 
def __str__(self):
 
return f'DataTransferKind: {self.kind} with {self.field}'
 
class Swap(DataTransfer):
class Swap(DataTransfer):
def __init__(self, source, destination, gpu):
def __init__(self, source, destination, gpu):
@@ -49,6 +52,9 @@ class Swap(DataTransfer):
@@ -49,6 +52,9 @@ class Swap(DataTransfer):
self.field = source
self.field = source
self.destination = destination
self.destination = destination
 
def __str__(self):
 
return f'Swap: {self.field} with {self.destination}'
 
class Communication(DataTransfer):
class Communication(DataTransfer):
def __init__(self, field, stencil, gpu):
def __init__(self, field, stencil, gpu):
@@ -80,6 +86,10 @@ class TimeloopRun:
@@ -80,6 +86,10 @@ class TimeloopRun:
+ '\nPost:\n'
+ '\nPost:\n'
+ '\n '.join(str(f) for f in self.timeloop._post_run_functions))
+ '\n '.join(str(f) for f in self.timeloop._post_run_functions))
 
@property
 
def asts(self):
 
return self.timeloop._single_step_asts
 
class GraphDataHandling(pystencils.datahandling.SerialDataHandling):
class GraphDataHandling(pystencils.datahandling.SerialDataHandling):