Skip to content

Commit

Permalink
Merge pull request #18 from kouwenhovenlab/master
Browse files Browse the repository at this point in the history
sync from lab repo
  • Loading branch information
wpfff committed Jan 6, 2019
2 parents dc628b3 + 588e34f commit 00083ea
Showing 1 changed file with 3 additions and 8 deletions.
11 changes: 3 additions & 8 deletions plottr/node/grid.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ class ShapeSpecification(QtGui.QWidget):
def __init__(self, parent=None):
super().__init__(parent)

self._axes = None
self._axes = []
self._widgets = {}

self.layout = QtGui.QFormLayout()
Expand Down Expand Up @@ -256,7 +256,7 @@ def process(self, **kw):
data = super().process(**kw)
if data is None:
return None

data = data['dataOut']
if self.ui is not None:
self.updateUiDataIn(data)
Expand All @@ -268,8 +268,6 @@ def process(self, **kw):
return None

if self._grid is None:
if isinstance(data, MeshgridDataDict):
shape = data.shape
dout = data

elif self._grid is False and isinstance(data, DataDict):
Expand All @@ -280,20 +278,17 @@ def process(self, **kw):

elif self._grid == 'guess' and isinstance(data, DataDict):
dout = dd.datadict_to_meshgrid(data)
shape = dout.shape

elif self._grid == 'guess' and isinstance(data, MeshgridDataDict):
shape = data.shape
dout = data

elif isinstance(self._grid, tuple):
shape = self._grid
dout = dd.datadict_to_meshgrid(data, target_shape=self._grid)

else:
self.logger().error(f"Unknown grid option {self._grid}. Most likely a bug :/")
return None

if dout is None:
return None

Expand Down

0 comments on commit 00083ea

Please sign in to comment.