Skip to content

Commit fbb4ef9

Browse files
ryoppippiayooshkathuria
authored andcommitted
Load only image
1 parent e42aa2f commit fbb4ef9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

detect.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ def arg_parse():
134134
read_dir = time.time()
135135
#Detection phase
136136
try:
137-
imlist = [osp.join(osp.realpath('.'), images, img) for img in os.listdir(images)]
137+
imlist = [osp.join(osp.realpath('.'), images, img) for img in os.listdir(images) if os.path.splitext(img)[1] == '.png' or os.path.splitext(img)[1] =='.jpeg' or os.path.splitext(img)[1] =='.jpg']
138138
except NotADirectoryError:
139139
imlist = []
140140
imlist.append(osp.join(osp.realpath('.'), images))

0 commit comments

Comments
 (0)