Guided Deep Dreams

Google recently updated the example of how to use their image recognition neural net to create “dreamy images” with some information on how to use a guide image  to look for, and emphasize things found in the guide image in the target. (We still use the original data set meaning that there’s still the unfortunate bias for dogs in the higher layers of dreaming, but we also find that they can be suppressed by careful use of a guide image). Adapting the code was not such a simple task as I assumed (naively) at first- I ended up storing the guide image in an array with the long side scaled down to 224 pixels (as had apparently been used in training data) when loaded, and using the main image itself as a “guide” if no guide image has been loaded.

In the example below, the trained network has been left to ponder an image of cumulus clouds against a blue sky, but with the following guide images (in order): Cogwheels, a cat, an analog clock face, an owl, a lighthouse on a beach, and finally a rubber duck 🙂

Do you see it?

Guided dreams

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s