trim-resize-image trims white space from an image and resize with specified size.
- python 3.6
- Pillow
you can just clone this repo and use like below.
$python trim-resize-image.py --img_dir='directory that has images to be trimed' --result_dir='directory that includes images' --width=width --height=height --border='white space around result images'
$python trim-resize-image.py --img_dir=idea --result_dir=idea_trim --width=216 --height=216 --border=20