It is recommended you run this project on a GPU enabled system. If you have access to a GPU, you should follow the Keras instructions for running Keras on GPU.
- Clone the repository, and navigate to the downloaded folder.
git clone https://github.com/ysharc/text-generation.git
cd text-generation
-
Create (and activate) a new environment with Python 3.6 and the
numpy
package.- Linux or Mac:
conda create --name text-generation python=3.6 numpy source activate text-generation
- Windows:
conda create --name text-generation python=3.6 numpy scipy activate text-generation
-
Install/Update TensorFlow (for this project, you may use CPU only).
- Option 1: To install TensorFlow with GPU support, follow the guide to install the necessary NVIDIA software on your system.
pip install tensorflow-gpu==1.3.0
- Option 2: To install TensorFlow with CPU support only:
pip install tensorflow==1.3.0
-
Install/Update Keras.
pip install keras -U
-
Switch Keras backend to TensorFlow.
- Linux or Mac:
KERAS_BACKEND=tensorflow python -c "from keras import backend"
- Windows:
set KERAS_BACKEND=tensorflow python -c "from keras import backend"
-
Install a few required pip packages (including OpenCV).
pip install -r requirements.txt
- Run the notebook and follow instructions
jupyter notebook RNN_project.ipynb