Softology Software Gallery Contact Blog
IMPORTANT POINTS
You MUST have an Nvidia GPU for the TensorFlow related modes to work in Visions of Chaos.
If you do have an Nvidia brand GPU, check its "Compute Capability" version here. 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.
I have tested and confirmed these steps work on PCs using a 2080 Super and 3090 RTX GPU.

Python
Download Python v3.9.3 from here. 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 pip install stage.

Visual Studio Community Edition
Download Visual Studio Community Edition from here.
Start the installer and check "Desktop developement with C++"
VS Installation
Click the "Individual Components" tab, scroll down and check the most recent "C++/CLI support" checkbox
VS Installation
Click Install.
Once the install is finished, you do not have to start Visual Studio or create an account to sign in. Just close it.
Reboot.

Update Python Packages
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 sub-directory 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 tensorflow-gpu==2.5.0rc
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall tensorflow-datasets==4.2.0
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall tf-nightly-gpu
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall keras==2.4.3
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall matplotlib==3.4.1
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall pillow==8.2.0
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall pydot==1.4.2
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall opencv-python==4.5.1.48
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall scipy==1.6.2
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall pandas==1.2.3
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall music21==6.7.1
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall imageio==2.9.0
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall fire==0.4.0
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall pyyaml==5.4.1
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall h5py==3.1.0
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall numpy==1.19.2
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall regex==2021.3.17
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall requests==2.25.1
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall tqdm==4.59.0
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall click==7.1.2
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall psutil==5.8.0
pip install --no-cache-dir --ignore-installed --upgrade --force-reinstall ninja==1.10.0.post2
pip install torch==1.8.1+cu111 torchvision==0.9.1+cu111 torchaudio===0.8.1 -f https://download.pytorch.org/whl/torch_stable.html
pip install deep-daze
pip install big-sleep

Note: if you get errors about dependency conflicts they can be ignored. If you are unsure, try the rest of the steps first and then try running one of the TensorFlow functions. If you get unsolvable errors with the pip install commands you can try uninstalling Python, deleting the Python directory, rebooting, reinstalling Python and then running the above pip install commands again.

CUDA
CUDA
Download CUDA v11.2.2 March 2021 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

cuDNN
1. Download cuDNN v8.1.0 (January 26th, 2021) for CUDA 11.0,11.1 and 11.2 from here.
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 all the the \cuda\bin\ DLLs into the C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v11.2\bin\ folder.

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\v11.2\bin as follows.
Path
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
5. GPT-2 text generation Select Mode->Machine Learning->GPT-2 Text Generator
6. Text-To-Image Select Mode->Machine Learning->PyTorch->GPT-2 Text Generator