This script runs the Deep Dream neural visualization on camera input to produce live output. Motion detection is used as a high latency interaction channel. Keyboard input allows dynamic control of neural parameters as the network dreams. My investigation building an engaging experience with this system is the subject of my GDC 2016 Poster Session: Find Your Spirit Animal In A Deep Dream Vision Quest
Neural visualization is computationally intensive and the Caffe/OpenCV/CUDA implementation isn't designed for real time output of neural visualization. 30fps output seems out of reach - even at lower resolutions, with reduced iteration rates, running on a fast GPU (TITAN X). From a performance perspective, there would appear to be quite a bit of headroom available. My CPU rarely goes above 20%, and the GPU Load remains under 70%. Is Python itself the bottleneck? Many aspects of this technology are a black box to me, so perhaps further optimizations are possible.
- Capture a video frame and dream about that frame indefinitely, using the output of the last cycle as the input of the next cycle, zooming in slightly each time
- Detail supplied by the neural network is amplified and aggregated by repeated passes of the source image through the network.
- With each iteration, grab another frame from the webcam
- Detect motion by comparing a rolling queue of the last 3 captured frames.
- When motion is detected, stop dreaming and grab another camera image to begin the "REM cycle" again.
- Keyboard input allows adjustments to amplification and neural activation while the software dreams.
- An Xbox game controller mapped to the keyboard makes controls easily discoverable and increases user mobility
Yes
samim23:DeepDream Animator
graphific: DeepDream Video
Diving Deeper into Deep Dreams
A Visual Introduction to Machine Learning
Inceptionism: Going Deeper into Neural Networks
What are deep dream images? How do I make my own?
Running Google’s Deep Dream on Windows – The Easy Way
Gary Boodhoo | skinjester.com | sciencefictionthriller.com | @skinjester