qqc1989's picture
initial this repo
a3b1a17 verified
raw
history blame
285 Bytes
import cv2
from glob import glob
import os
paths = sorted(glob("demo/*.jpg"))
print(paths)
outdir = "demo_cv308"
os.makedirs(outdir, exist_ok=True)
for p in paths:
img = cv2.imread(p)
img = cv2.resize(img, (308,308))
cv2.imwrite(f"{outdir}/{os.path.basename(p)}", img)