/image-collage-filter

A python script to make images that consist of more images!

Primary LanguagePython

banner

image_collage_filter.py is a python script that recreates an image as an image made up of smaller 32x32 images (like an image collage but the collage itself is an image). Explaining it is a bit rough, so just try it yourself and see!

Usage

The script has 3 subcommands:

# shows the help message
python image_collage_filter.py help
# applies the filter to image.png
python image_collage_filter.py apply ./image.png
# profiles one iteration of the script on image.png
python image_collage_filter.py profile ./image.png

Here is an example image (the Hungarian Parliament Building in Budapest) in it's original form:

parliament

And here it is ran trhough the script (download the image and zoom in for disturbing detail):

parliament_out

Dataset Generation

For the image_collage_filter.py script to work, it needs 32x32 images categorized by their average colors. The cifar_100_preprocessor.py categorizes CIFAR-100 images by their median colors and exports them to ./generated-set as png images.