Skip to content

Instantly share code, notes, and snippets.

@DLohn
DLohn / resize.py
Last active February 29, 2024 22:57
Resize all images in a directory
import sys
import os
from PIL import Image
resize_to = 384
target_dir = sys.argv[1]
for file in os.listdir(target_dir):
full_path = os.path.join(target_dir, file)