import glob
for filename in glob.glob(r'/backup/home2/caffe-ssd/data/VOCdevkit/VOC2007/JPEGImages/*.jpg'):
print filename
import cv2
for each in range(len(filename)):
img=cv2.imread('/backup/home2/caffe-ssd/data/VOCdevkit/VOC2007/JPEGImages/000009.jpg')
cv2.imshow('test.jpg',img)
if cv2.waitKey(10)>=0:
break
Python读取文件夹下的所有图片并用waitKey控制退出
最新推荐文章于 2024-08-29 02:17:04 发布