ab-101
commited on
Commit
•
c32b0af
1
Parent(s):
a5359f6
Update detect.py (#2167)
Browse filesWithout this cv2.imshow opens a window but nothing is visible
detect.py
CHANGED
@@ -118,6 +118,7 @@ def detect(save_img=False):
|
|
118 |
# Stream results
|
119 |
if view_img:
|
120 |
cv2.imshow(str(p), im0)
|
|
|
121 |
|
122 |
# Save results (image with detections)
|
123 |
if save_img:
|
|
|
118 |
# Stream results
|
119 |
if view_img:
|
120 |
cv2.imshow(str(p), im0)
|
121 |
+
cv2.waitKey(1) # 1 millisecond
|
122 |
|
123 |
# Save results (image with detections)
|
124 |
if save_img:
|