diff --git a/pc.py b/pc.py index 71f9e47..37c5cf0 100644 --- a/pc.py +++ b/pc.py @@ -38,7 +38,6 @@ cell_w, cell_h = w//m, h//m c = 1 # Color channels fps = 24 kf = 1 # Keyframes (every kf-th source frame is a cell frame candidate) -start, stop = 3275, 97701 ts, ti = 1, 0 # Number of threads, current thread index cache = {} @@ -69,9 +68,8 @@ def load_image(fn): def read_images(): def save_data(): np.save(data_fn, data) - src_fn = f'{src_dn}/{stop:08d}.jpg' if not os.path.exists(src_dn): - os.makedirs(src_dn, exist_ok=True) + os.makedirs(src_dn) os.system(f'ffmpeg -i "{video_fn}" -q:v 1 "{src_dn}/%08d.jpg"') cell_dn = f'{src_dn}_{cell_w}x{cell_h}' os.makedirs(cell_dn, exist_ok=True)