Skip to content
Snippets Groups Projects
Commit ca3becf1 authored by Paul McCarthy's avatar Paul McCarthy :mountain_bicyclist:
Browse files

Silly edge case fix in image wrapper - for images where all dimensions have

length 1
parent 875bab98
No related branches found
No related tags found
No related merge requests found
......@@ -187,6 +187,11 @@ class ImageWrapper(notifier.Notifier):
if d == 1: self.__numRealDims -= 1
else: break
# Degenerate case - if every
# dimension has length 1
if self.__numRealDims == 0:
self.__numRealDims = len(image.shape)
# And save the number of
# 'padding' dimensions too.
self.__numPadDims = len(image.shape) - self.__numRealDims
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment