Skip to content

Commit 96154e4

Browse files
Review suggestions
Co-Authored-By: Emil Melnikov <[email protected]>
1 parent 8bfc0cc commit 96154e4

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

volumina/volumeEditorWidget.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -332,9 +332,9 @@ def _updateTileWidth(self):
332332
self.editor.setTileWidth(tile_width)
333333

334334
def _getTileWidthConfigKeyDefault(self):
335-
singletons_spacial = [True for dim in self.editor.posModel.shape if dim == 1]
336-
assert len(singletons_spacial) in range(2)
337-
if len(singletons_spacial) == 0:
335+
singletons_spacial = sum(1 for dim in self.editor.posModel.shape if dim == 1)
336+
assert singletons_spacial in range(2)
337+
if singletons_spacial == 0:
338338
# 3D data
339339
key = "tileWidth3D"
340340
default = 256

0 commit comments

Comments
 (0)