[PYTHON] Try deepdream on Mac

What is deepdream

An open source image recognition network using deep learning published by google, the repository is here. If there is an area similar to the pattern that was being learned in the input image, it will try to restore the original image and synthesize an image that is far from the human imagination. I think there are many people who have seen it because it is a topic recently.

0002.jpg

You can do this locally! , Needs to install Caffe, which is a deep learning framework, so please install it. The introduction method of Caffe is summarized in this article, so please refer to it if you like.

procedure

It works with ipython notebook, so put it in.

pip install ipython "ipython[notebook]"

Clone the source published from the repository next to Caffe.

cd /path/to/caffe
cd ../
git clone [email protected]:google/deepdream.git

Since you need a trained caffe model, download it from caffemodel_url here and save it in models / bvlc_googlenet / in Caffe.

Go to deepdream and launch ipython notebook.

cd deepdream
ipython trust dream.ipynb
ipython notebook

I think the browser has been launched. Select dream.ipynb and press the play button at the top. If you go to the end, deepdream will be executed based on the image sky1024px.jpg, and the image converted todeepdream / frames /will be saved.

With this, I was able to output the dream of the neural network (I say dream, but it's not a dream at all, I feel like I just forced it to recognize it), if you want to deepdream your favorite image, you can do it If you save it as sky1024px.jpg, it will be loaded (because I don't want to mess with the contents, I wear it sideways).

When uploading the created image to SNS etc., add the #deepdream tag because the people who made deepdream will be pleased.

Recommended Posts

Try deepdream on Mac
python on mac
Try moving deepdream
Try running PlaidML image judgment on Mac
Install Tensorflow on Mac
Install pyenv on mac
Pyenv + virtualenv on Mac
Install Python on Mac
Install Python 3 on Mac
numba installation on mac
Try working with Mongo in Python on Mac
Run OpenMVG on Mac
Try FEniCS on Windows!
Try NeosVR on Linux
Install Python 3.4 on Mac
Install Caffe on Mac
Install mecab on mac
Install mecab-python on Mac
Try importing MLB data on Mac and Python
Try using E-Cell 4 on Windows 7 or Mac OS X
Notes on installing dlib on mac
Pyramid + mongodb environment on Mac
Install pygame on python3.4 on mac
Try using OpenCV on Windows
Install module on Anaconda (Mac)
Install OpenPose on mac (Catalina)
Install numba on your Mac
Handling of python on mac
Try "100 knocks on data science" ①
Update python on Mac to 3.7-> 3.8
Install pandas 0.14 on python3.4 [on Mac]
Launch local server on mac
Notes on installing Python on Mac
Install Django on your Mac
Install pillow on Mac OSX 10.9
[Mac] Tips: Install pyquery on Mac [pyquery]
Use matplot libwidget on mac
Memo on Mac OS X
Notes on installing pipenv on Mac
Catalina on Mac and pyenv
Building a Python environment on Mac
If python on mac goes missing
Try running tensorflow on Docker + anaconda
Try using Pillow on iPython (Part 1)
tensor flow with anaconda on mac
Install anaconda on Mac → Add Library
MQTT on Raspberry Pi and Mac
How to install mysql-connector-python on mac
Implement TensorFlow Lite on Mac [2019 Edition]
Try installing OpenAM on Amazon Linux
Steps to install matplotlib on Mac
Anaconda environment construction on Mac (2018 version)
Try using Pillow on iPython (Part 2)
Create a Python environment on Mac (2017/4)
Install Sphinx on Mac OS X
Python environment construction memo on Mac
Install Python 3.7 Anaconda on MAC, but Python 2
Install Scipy on Mac OS Sierra
Try implementing k-NN on your own
Install python3 on Mac (El Capitan)
Try using ArUco on Raspberry Pi