CLgen: Deep Learning Program Generator.

Documentation Status Build Status Coverage Status Release Version License Badge

CLgen is an open source application for generating runnable programs using deep learning. CLgen learns to program using neural networks which model the semantics and usage from large volumes of program fragments, generating many-core OpenCL programs that are representative of, but distinct from, the programs it learns from.

Requirements

For Ubuntu 16.04 or OS X, the following command will install the CLgen requirements automatically:

$ curl -s https://raw.githubusercontent.com/ChrisCummins/clgen/0.4.1/install-deps.sh | bash

Note that on Ubuntu, sudo privileges are required to install these requirements - you may be prompted for your password.

For other Linux distributions and older versions of Ubuntu, please check each for each of the following requirements:

Optional, but recommended:

Installation - Virtualenv

We recommend using a virtualenv environment to install CLgen. This installs CLgen in its own directory, without impacting any existing programs on the machine. Installing in a virtualenv environment does not require sudo privileges.

Create a virtualenv environment in the directory ~/clgen:

$ virtualenv -p python3 ~/clgen

Activate this environment:

$ source ~/clgen/bin/activate

Install the latest release of CLgen:

# if you have an NVIDIA GPU with CUDA 8.0 and cuDNN:
(clgen)$ curl -s https://raw.githubusercontent.com/ChrisCummins/clgen/0.4.1/install-cuda.sh | bash
# CPU only:
(clgen)$ curl -s https://raw.githubusercontent.com/ChrisCummins/clgen/0.4.1/install-cpu.sh | bash

When you are done using CLgen, deactivate the virtualenv environment:

(clgen)$ deactivate

To use CLgen later you will need to activate the virtualenv environment again:

$ source ~/clgen/bin/activate

Installation - System-wide

A system-wide install allows any user on the machine to run CLgen without activating a virtualenv environment. This may update some of the previously installed Python packages. System-wide installation requires sudo priveledges - you may be prompted for your password.

Install the latest release of CLgen:

# if you have an NVIDIA GPU with CUDA 8.0 and cuDNN:
$ curl -s https://raw.githubusercontent.com/ChrisCummins/clgen/0.4.1/install-cuda.sh | bash
# CPU only:
$ curl -s https://raw.githubusercontent.com/ChrisCummins/clgen/0.4.1/install-cpu.sh | bash

Indices and tables