Skip to content

Commit 79b6d6e

Browse files
authored
minor bug in preprocess function
bug reported by [@sydney0zq](#10)
1 parent 1a8b35d commit 79b6d6e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

goturn/network/regressor.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ def preprocess(self, image):
6565
image_out = cv2.cvtColor(image, cv2.COLOR_BGRA2GRAY)
6666
elif num_channels == 3 and image.shape[2] == 4:
6767
image_out = cv2.cvtColor(image, cv2.COLOR_BGRA2BGR)
68-
elif num_channels == 3 and image.shape[2] == 2:
68+
elif num_channels == 3 and image.shape[2] == 1:
6969
image_out = cv2.cvtColor(image, cv2.COLOR_GRAY2BGR)
7070
else:
7171
image_out = image

0 commit comments

Comments
 (0)