Softology Software Gallery Contact Blog
You MUST have an Nvidia GPU for the TensorFlow related modes to work in Visions of Chaos. If you are unsure, check your graphics card is listed here.
If your graphics card is listed, check the "Compute Capability" version next to it. Your card MUST support version 3.5 or later for TensorFlow to work. If your card shows 3.0 or earlier these steps will not work.
If you do not have a supported Nvidia GPU stop now and don't bother with the rest of this page.
Version numbers are important. If these instructions specify a version number make sure you download and install that version.
These steps only seem to work on Windows 10 64-bit. I have not yet been able to get them working on earlier versions of Windows.

Movie Tutorial
The following movie explains the steps on this page in more detail.
NOTE that I missed covering the add to path step that is covered on this page. That must be done after the other steps.

Installing Python and TensorFlow for Visions of Chaos
Python and TensorFlow enable the machine learning and neural network features of Visions of Chaos.
Follow these steps to get TensorFlow working on your PC so Visions of Chaos can make use of it.

Download Python from here. v3.7.4 worked for me but I also confirmed v3.7.5. Newer versions cause TensorFlow to fail so use the older version. Make sure it is the 64 bit version. If the first setup page shows 32-bit, cancel and download the 64-bit version.
Install it making sure you check the "Add Python to PATH" checkbox.
Python Install Dialog
If you also install Python outside the "Program Files" directory (eg to C:\Python\) it saves potential security rights hassles in the next stage.

Update Python Libraries
If you installed Python to a directory outside "Program Files" you can copy the following commands into a command prompt windows. If you did install Python to the default subdirectory under "Program Files" you will need to run the following commands from an Administrator command prompt.
To prevent other possible access errors make sure there are no instances of python.exe running in task manager before trying these commands.
The commands can all be copied and pasted into the command line in one go and will execute one after the other.
python -m pip install --upgrade pip
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall pyyaml==5.1.2
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall tensorflow-gpu==1.14
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall tensorflow-datasets==1.2.0
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall keras==2.2.4
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall matplotlib==3.1.1
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall pillow==6.1.0
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall pydot==1.4.1
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall opencv-python==
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall scipy==1.3.1
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall pandas==0.25.1
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall music21==5.7.0
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall imageio==2.6.1

Download CUDA v10.0 from here and install it.
NOTE: by default the Nvidia installer wants to install extra drivers etc, you only need the libraries option checked, ie
CUDA Install Dialog

1. Download cuDNN v10.0 from here. Make sure you get the version for CUDA 10.0, ie "Download cuDNN v7.6.4 (September 27, 2019), for CUDA 10.0"
You do have to register, but if you do not want to use your real name and email to register, use a fake name and a free temp mail service like temp mail or 10 minute mail to get the verification email.
2. Extract the cuDNN zip to a temp folder.
3. Copy the \cuda\bin\cudnn64_7.dll into the C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.0\bin\ folder.
The C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.0\bin\ folder should now have a bunch of DLLs and look like the following
4. Add the CUDA bin folder (ie C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.0\bin) to your path.

Add CUDA to Path
1. Hold the Windows key and press Pause to bring up the System Control Panel.
2. Click Advanced system settings.
3. Click the Environment Variables button.
System Properties
4. Highlight Path in the lower "System variables" section as above and click Edit.
Environment Variables
5. Click New and add C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.0\bin as follows.
6. Click OK, OK, OK to close all dialogs.
7. Reboot Windows.

Test TensorFlow Support in Visions of Chaos
Start Visions of Chaos, click the Options menu and then select Options to open the Options dialog. Under the TensorFlow tab, click the "Check and enable TensorFlow" button.
Visions of Chaos TensorFlow detection
If the installs went OK then TensorFlow should be detected and the TensorFlow functionality will be enabled in Visions of Chaos.
TensorFlow and CUDA may fail if another program is using it. If you have a problem, try rebooting and then running only Visions of Chaos and try again. If you are rendering a long movie it is best to have only Visions of Chaos running for the best chance of a trouble free result.

How Can You Use TensorFlow in Visions of Chaos
1. Cellular automata searching Select Mode->Cellular Automata->2D->2D Cellular Automata. You should see a "Search" button. Clicking that uses TensorFlow Convolutional Neural Networks to detect interesting CA rules.
2. Style Transfer GANs Select Image->Image Procesing->Style Transfer
3. LSTM Music Composer Select Mode->Music->LSTM Composer
4. DeepDream Select Image->Image Procesing->DeepDream