# Get Google Drive mounted as disk

```
from google.colab import drive
drive.mount('/content/drive')
```

    Go to this URL in a browser: https://accounts.google.com/o/oauth2/auth?client_id=947318989803-6bn6qk8qdgf4n4g3pfee6491hc0brc4i.apps.googleusercontent.com&redirect_uri=urn%3aietf%3awg%3aoauth%3a2.0%3aoob&response_type=code&scope=email%20https%3a%2f%2fwww.googleapis.com%2fauth%2fdocs.test%20https%3a%2f%2fwww.googleapis.com%2fauth%2fdrive%20https%3a%2f%2fwww.googleapis.com%2fauth%2fdrive.photos.readonly%20https%3a%2f%2fwww.googleapis.com%2fauth%2fpeopleapi.readonly

    Enter your authorization code:
    ··········
    Mounted at /content/drive

```
%mkdir /content/drive/My\ Drive/SLACKBOT/
```

    mkdir: cannot create directory ‘/content/drive/My Drive/SLACKBOT/’: File exists

```
%cd /content/drive/My\ Drive/SLACKBOT/
```

    /content/drive/My Drive/SLACKBOT

# Cloning the code

I have modified a few things in the original GPT-2 code. So you have to use my repository to make it work.

```
!git clone https://github.com/groar/gpt-2 -b chat gpt-2
```

    fatal: destination path 'gpt-2' already exists and is not an empty directory.

# Installing all the requirements

```
!pip3 install -r requirements.txt
```

    Collecting fire>=0.1.3
      Downloading https://files.pythonhosted.org/packages/34/a7/0e22e70778aca01a52b9c899d9c145c6396d7b613719cd63db97ffa13f2f/fire-0.3.1.tar.gz (81kB)
         |████████████████████████████████| 81kB 2.2MB/s
    Collecting regex==2017.4.5
      Downloading https://files.pythonhosted.org/packages/36/62/c0c0d762ffd4ffaf39f372eb8561b8d491a11ace5a7884610424a8b40f95/regex-2017.04.05.tar.gz (601kB)
         |████████████████████████████████| 604kB 8.5MB/s
    Collecting requests==2.21.0
      Downloading https://files.pythonhosted.org/packages/7d/e3/20f3d364d6c8e5d2353c72a67778eb189176f08e873c9900e10c0287b84b/requests-2.21.0-py2.py3-none-any.whl (57kB)
         |████████████████████████████████| 61kB 7.6MB/s
    Collecting tqdm==4.31.1
      Downloading https://files.pythonhosted.org/packages/6c/4b/c38b5144cf167c4f52288517436ccafefe9dc01b8d1c190e18a6b154cd4a/tqdm-4.31.1-py2.py3-none-any.whl (48kB)
         |████████████████████████████████| 51kB 5.8MB/s
    Collecting toposort==1.5
      Downloading https://files.pythonhosted.org/packages/e9/8a/321cd8ea5f4a22a06e3ba30ef31ec33bea11a3443eeb1d89807640ee6ed4/toposort-1.5-py2.py3-none-any.whl
    Collecting tensor2tensor>=1.14.1
      Downloading https://files.pythonhosted.org/packages/4a/49/950b57285034e76821f169bc9ee131b05fc0481258c443abbdbafc9d0638/tensor2tensor-1.15.6-py2.py3-none-any.whl (1.4MB)
         |████████████████████████████████| 1.4MB 16.1MB/s
    Collecting tokenizers==0.0.9
      Downloading https://files.pythonhosted.org/packages/db/61/38694f1bbaa8d8528045e083c3d1a59ef062ede798ddf1fce2c5d6f13ee3/tokenizers-0.0.9-cp36-cp36m-manylinux1_x86_64.whl (3.1MB)
         |████████████████████████████████| 3.1MB 32.8MB/s
    Requirement already satisfied: h5py in /usr/local/lib/python3.6/dist-packages (from -r requirements.txt (line 8)) (2.10.0)
    Requirement already satisfied: six in /usr/local/lib/python3.6/dist-packages (from fire>=0.1.3->-r requirements.txt (line 1)) (1.12.0)
    Requirement already satisfied: termcolor in /usr/local/lib/python3.6/dist-packages (from fire>=0.1.3->-r requirements.txt (line 1)) (1.1.0)
    Collecting idna<2.9,>=2.5
      Downloading https://files.pythonhosted.org/packages/14/2c/cd551d81dbe15200be1cf41cd03869a46fe7226e7450af7a6545bfc474c9/idna-2.8-py2.py3-none-any.whl (58kB)
         |████████████████████████████████| 61kB 5.7MB/s
    Requirement already satisfied: certifi>=2017.4.17 in /usr/local/lib/python3.6/dist-packages (from requests==2.21.0->-r requirements.txt (line 3)) (2020.4.5.1)
    Requirement already satisfied: urllib3<1.25,>=1.21.1 in /usr/local/lib/python3.6/dist-packages (from requests==2.21.0->-r requirements.txt (line 3)) (1.24.3)
    Requirement already satisfied: chardet<3.1.0,>=3.0.2 in /usr/local/lib/python3.6/dist-packages (from requests==2.21.0->-r requirements.txt (line 3)) (3.0.4)
    Requirement already satisfied: google-api-python-client in /usr/local/lib/python3.6/dist-packages (from tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (1.7.12)
    Requirement already satisfied: dopamine-rl in /usr/local/lib/python3.6/dist-packages (from tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (1.0.5)
    Collecting gevent
      Downloading https://files.pythonhosted.org/packages/28/8b/918c61f23693971f4eedb3f910438e18b9bab489511dd1f313657ef0a330/gevent-20.6.1-cp36-cp36m-manylinux2010_x86_64.whl (5.3MB)
         |████████████████████████████████| 5.3MB 20.9MB/s
    Collecting gunicorn
      Downloading https://files.pythonhosted.org/packages/69/ca/926f7cd3a2014b16870086b2d0fdc84a9e49473c68a8dff8b57f7c156f43/gunicorn-20.0.4-py2.py3-none-any.whl (77kB)
         |████████████████████████████████| 81kB 11.0MB/s
    Collecting tf-slim
      Downloading https://files.pythonhosted.org/packages/02/97/b0f4a64df018ca018cc035d44f2ef08f91e2e8aa67271f6f19633a015ff7/tf_slim-1.1.0-py2.py3-none-any.whl (352kB)
         |████████████████████████████████| 358kB 51.2MB/s
    Requirement already satisfied: opencv-python in /usr/local/lib/python3.6/dist-packages (from tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (4.1.2.30)
    Requirement already satisfied: tensorflow-datasets in /usr/local/lib/python3.6/dist-packages (from tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (2.1.0)
    Collecting pypng
      Downloading https://files.pythonhosted.org/packages/bc/fb/f719f1ac965e2101aa6ea6f54ef8b40f8fbb033f6ad07c017663467f5147/pypng-0.0.20.tar.gz (649kB)
         |████████████████████████████████| 655kB 53.2MB/s
    Requirement already satisfied: sympy in /usr/local/lib/python3.6/dist-packages (from tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (1.1.1)
    Requirement already satisfied: Pillow in /usr/local/lib/python3.6/dist-packages (from tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (7.0.0)
    Requirement already satisfied: tensorflow-addons in /usr/local/lib/python3.6/dist-packages (from tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (0.8.3)
    Requirement already satisfied: oauth2client in /usr/local/lib/python3.6/dist-packages (from tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (4.1.3)
    Requirement already satisfied: future in /usr/local/lib/python3.6/dist-packages (from tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (0.16.0)
    Collecting gym==0.14.0
      Downloading https://files.pythonhosted.org/packages/61/75/9e841bc2bc75128e0b65c3d5255d0bd16becb9d8f7120b965d41b8e70041/gym-0.14.0.tar.gz (1.6MB)
         |████████████████████████████████| 1.6MB 51.7MB/s
    Requirement already satisfied: flask in /usr/local/lib/python3.6/dist-packages (from tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (1.1.2)
    Collecting mesh-tensorflow
      Downloading https://files.pythonhosted.org/packages/ea/32/ceaf1549586ccfeaf7840a166876be358bd78ab2fdd152b17c5600ed7888/mesh_tensorflow-0.1.13-py3-none-any.whl (292kB)
         |████████████████████████████████| 296kB 51.0MB/s
    Collecting tensorflow-gan
      Downloading https://files.pythonhosted.org/packages/0c/2e/62922111d7d50e1900e3030764743ea7735540ce103b3ab30fd5cd2d8a2b/tensorflow_gan-2.0.0-py2.py3-none-any.whl (365kB)
         |████████████████████████████████| 368kB 56.1MB/s
    Requirement already satisfied: gin-config in /usr/local/lib/python3.6/dist-packages (from tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (0.3.0)
    Collecting bz2file
      Downloading https://files.pythonhosted.org/packages/61/39/122222b5e85cd41c391b68a99ee296584b2a2d1d233e7ee32b4532384f2d/bz2file-0.98.tar.gz
    Collecting kfac
      Downloading https://files.pythonhosted.org/packages/01/f0/4a7758f854a15b37d322827123ce58619d0f4270dd94f2dd30328f397339/kfac-0.2.0-py2.py3-none-any.whl (178kB)
         |████████████████████████████████| 184kB 39.5MB/s
    Collecting tensorflow-probability==0.7.0
      Downloading https://files.pythonhosted.org/packages/3e/3a/c10b6c22320531c774402ac7186d1b673374e2a9d12502cbc8d811e4601c/tensorflow_probability-0.7.0-py2.py3-none-any.whl (981kB)
         |████████████████████████████████| 983kB 59.2MB/s
    Requirement already satisfied: absl-py in /usr/local/lib/python3.6/dist-packages (from tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (0.9.0)
    Requirement already satisfied: numpy in /usr/local/lib/python3.6/dist-packages (from tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (1.18.5)
    Requirement already satisfied: scipy in /usr/local/lib/python3.6/dist-packages (from tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (1.4.1)
    Requirement already satisfied: uritemplate<4dev,>=3.0.0 in /usr/local/lib/python3.6/dist-packages (from google-api-python-client->tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (3.0.1)
    Requirement already satisfied: google-auth-httplib2>=0.0.3 in /usr/local/lib/python3.6/dist-packages (from google-api-python-client->tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (0.0.3)
    Requirement already satisfied: httplib2<1dev,>=0.17.0 in /usr/local/lib/python3.6/dist-packages (from google-api-python-client->tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (0.17.4)
    Requirement already satisfied: google-auth>=1.4.1 in /usr/local/lib/python3.6/dist-packages (from google-api-python-client->tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (1.7.2)
    Requirement already satisfied: setuptools in /usr/local/lib/python3.6/dist-packages (from gevent->tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (47.1.1)
    Collecting zope.interface
      Downloading https://files.pythonhosted.org/packages/57/33/565274c28a11af60b7cfc0519d46bde4125fcd7d32ebc0a81b480d0e8da6/zope.interface-5.1.0-cp36-cp36m-manylinux2010_x86_64.whl (234kB)
         |████████████████████████████████| 235kB 51.8MB/s
    Collecting zope.event
      Downloading https://files.pythonhosted.org/packages/c5/96/361edb421a077a4c208b4a5c212737d78ae03ce67fbbcd01621c49f332d1/zope.event-4.4-py2.py3-none-any.whl
    Collecting greenlet>=0.4.16; platform_python_implementation == "CPython"
      Downloading https://files.pythonhosted.org/packages/7e/a4/0d8685c98986326534b0753a8b92b3082bc9df42b348bc50d6c69839c9f9/greenlet-0.4.16-cp36-cp36m-manylinux1_x86_64.whl (44kB)
         |████████████████████████████████| 51kB 7.7MB/s
    Requirement already satisfied: protobuf>=3.6.1 in /usr/local/lib/python3.6/dist-packages (from tensorflow-datasets->tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (3.10.0)
    Requirement already satisfied: promise in /usr/local/lib/python3.6/dist-packages (from tensorflow-datasets->tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (2.3)
    Requirement already satisfied: attrs>=18.1.0 in /usr/local/lib/python3.6/dist-packages (from tensorflow-datasets->tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (19.3.0)
    Requirement already satisfied: wrapt in /usr/local/lib/python3.6/dist-packages (from tensorflow-datasets->tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (1.12.1)
    Requirement already satisfied: tensorflow-metadata in /usr/local/lib/python3.6/dist-packages (from tensorflow-datasets->tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (0.22.1)
    Requirement already satisfied: dill in /usr/local/lib/python3.6/dist-packages (from tensorflow-datasets->tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (0.3.1.1)
    Requirement already satisfied: mpmath>=0.19 in /usr/local/lib/python3.6/dist-packages (from sympy->tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (1.1.0)
    Requirement already satisfied: typeguard in /usr/local/lib/python3.6/dist-packages (from tensorflow-addons->tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (2.7.1)
    Requirement already satisfied: rsa>=3.1.4 in /usr/local/lib/python3.6/dist-packages (from oauth2client->tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (4.0)
    Requirement already satisfied: pyasn1>=0.1.7 in /usr/local/lib/python3.6/dist-packages (from oauth2client->tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (0.4.8)
    Requirement already satisfied: pyasn1-modules>=0.0.5 in /usr/local/lib/python3.6/dist-packages (from oauth2client->tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (0.2.8)
    Collecting pyglet<=1.3.2,>=1.2.0
      Downloading https://files.pythonhosted.org/packages/1c/fc/dad5eaaab68f0c21e2f906a94ddb98175662cc5a654eee404d59554ce0fa/pyglet-1.3.2-py2.py3-none-any.whl (1.0MB)
         |████████████████████████████████| 1.0MB 57.7MB/s
    Collecting cloudpickle~=1.2.0
      Downloading https://files.pythonhosted.org/packages/c1/49/334e279caa3231255725c8e860fa93e72083567625573421db8875846c14/cloudpickle-1.2.2-py2.py3-none-any.whl
    Requirement already satisfied: click>=5.1 in /usr/local/lib/python3.6/dist-packages (from flask->tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (7.1.2)
    Requirement already satisfied: Werkzeug>=0.15 in /usr/local/lib/python3.6/dist-packages (from flask->tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (1.0.1)
    Requirement already satisfied: itsdangerous>=0.24 in /usr/local/lib/python3.6/dist-packages (from flask->tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (1.1.0)
    Requirement already satisfied: Jinja2>=2.10.1 in /usr/local/lib/python3.6/dist-packages (from flask->tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (2.11.2)
    Requirement already satisfied: tensorflow-hub>=0.2 in /usr/local/lib/python3.6/dist-packages (from tensorflow-gan->tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (0.8.0)
    Requirement already satisfied: decorator in /usr/local/lib/python3.6/dist-packages (from tensorflow-probability==0.7.0->tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (4.4.2)
    Requirement already satisfied: cachetools<3.2,>=2.0.0 in /usr/local/lib/python3.6/dist-packages (from google-auth>=1.4.1->google-api-python-client->tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (3.1.1)
    Requirement already satisfied: googleapis-common-protos in /usr/local/lib/python3.6/dist-packages (from tensorflow-metadata->tensorflow-datasets->tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (1.52.0)
    Requirement already satisfied: MarkupSafe>=0.23 in /usr/local/lib/python3.6/dist-packages (from Jinja2>=2.10.1->flask->tensor2tensor>=1.14.1->-r requirements.txt (line 6)) (1.1.1)
    Building wheels for collected packages: fire, regex, pypng, gym, bz2file
      Building wheel for fire (setup.py) ... done
      Created wheel for fire: filename=fire-0.3.1-py2.py3-none-any.whl size=111005 sha256=c3b5825d87efc57809dff5dd1607ad7a9e43485b1b3b47007b57d071a02a8c92
      Stored in directory: /root/.cache/pip/wheels/c1/61/df/768b03527bf006b546dce284eb4249b185669e65afc5fbb2ac
      Building wheel for regex (setup.py) ... done
      Created wheel for regex: filename=regex-2017.4.5-cp36-cp36m-linux_x86_64.whl size=533217 sha256=b6e757869dc6bc8222e036a57cdab1b26695905706a436dbc16c0793c602ddc5
      Stored in directory: /root/.cache/pip/wheels/75/07/38/3c16b529d50cb4e0cd3dbc7b75cece8a09c132692c74450b01
      Building wheel for pypng (setup.py) ... done
      Created wheel for pypng: filename=pypng-0.0.20-cp36-none-any.whl size=67161 sha256=ef6df6528512f5a6ff49de60c0719434fa3a2ba24b1094c924784d3b1e05ae38
      Stored in directory: /root/.cache/pip/wheels/41/6b/ef/0493b536b6d4722c2ae9486691b1d49b922b9877922beeabb3
      Building wheel for gym (setup.py) ... done
      Created wheel for gym: filename=gym-0.14.0-cp36-none-any.whl size=1637522 sha256=1772fa3349e8cde96a926e9fae8af7f9546ac7a5bd2b354dd884ccda3bb4ab84
      Stored in directory: /root/.cache/pip/wheels/7e/53/f6/c0cd3c9bf953f35c0aee7fa62ea209371e92f5e5cced3245ba
      Building wheel for bz2file (setup.py) ... done
      Created wheel for bz2file: filename=bz2file-0.98-cp36-none-any.whl size=6884 sha256=77d7400bddedc314836dc72148ded0235cbfd0652232447d6cfe6acfb2880029
      Stored in directory: /root/.cache/pip/wheels/81/75/d6/e1317bf09bf1af5a30befc2a007869fa6e1f516b8f7c591cb9
    Successfully built fire regex pypng gym bz2file
    ERROR: spacy 2.2.4 has requirement tqdm<5.0.0,>=4.38.0, but you'll have tqdm 4.31.1 which is incompatible.
    ERROR: google-colab 1.0.0 has requirement requests~=2.23.0, but you'll have requests 2.21.0 which is incompatible.
    ERROR: datascience 0.10.6 has requirement folium==0.2.1, but you'll have folium 0.8.3 which is incompatible.
    Installing collected packages: fire, regex, idna, requests, tqdm, toposort, zope.interface, zope.event, greenlet, gevent, gunicorn, tf-slim, pypng, pyglet, cloudpickle, gym, mesh-tensorflow, tensorflow-probability, tensorflow-gan, bz2file, kfac, tensor2tensor, tokenizers
      Found existing installation: regex 2019.12.20
        Uninstalling regex-2019.12.20:
          Successfully uninstalled regex-2019.12.20
      Found existing installation: idna 2.9
        Uninstalling idna-2.9:
          Successfully uninstalled idna-2.9
      Found existing installation: requests 2.23.0
        Uninstalling requests-2.23.0:
          Successfully uninstalled requests-2.23.0
      Found existing installation: tqdm 4.41.1
        Uninstalling tqdm-4.41.1:
          Successfully uninstalled tqdm-4.41.1
      Found existing installation: pyglet 1.5.0
        Uninstalling pyglet-1.5.0:
          Successfully uninstalled pyglet-1.5.0
      Found existing installation: cloudpickle 1.3.0
        Uninstalling cloudpickle-1.3.0:
          Successfully uninstalled cloudpickle-1.3.0
      Found existing installation: gym 0.17.2
        Uninstalling gym-0.17.2:
          Successfully uninstalled gym-0.17.2
      Found existing installation: tensorflow-probability 0.10.0
        Uninstalling tensorflow-probability-0.10.0:
          Successfully uninstalled tensorflow-probability-0.10.0
    Successfully installed bz2file-0.98 cloudpickle-1.2.2 fire-0.3.1 gevent-20.6.1 greenlet-0.4.16 gunicorn-20.0.4 gym-0.14.0 idna-2.8 kfac-0.2.0 mesh-tensorflow-0.1.13 pyglet-1.3.2 pypng-0.0.20 regex-2017.4.5 requests-2.21.0 tensor2tensor-1.15.6 tensorflow-gan-2.0.0 tensorflow-probability-0.7.0 tf-slim-1.1.0 tokenizers-0.0.9 toposort-1.5 tqdm-4.31.1 zope.event-4.4 zope.interface-5.1.0

What follows is necessary to train & for inference, as well as for using the TPU.

```
!pip install tensorflow-gpu==1.15.0
!pip install 'tensorflow-estimator<1.15.0rc0,>=1.14.0rc0' --force-reinstall

```

    Collecting tensorflow-gpu==1.15.0
      Downloading https://files.pythonhosted.org/packages/a5/ad/933140e74973fb917a194ab814785e7c23680ca5dee6d663a509fe9579b6/tensorflow_gpu-1.15.0-cp36-cp36m-manylinux2010_x86_64.whl (411.5MB)
         |████████████████████████████████| 411.5MB 40kB/s
    Requirement already satisfied: keras-applications>=1.0.8 in /usr/local/lib/python3.6/dist-packages (from tensorflow-gpu==1.15.0) (1.0.8)
    Collecting gast==0.2.2
      Downloading https://files.pythonhosted.org/packages/4e/35/11749bf99b2d4e3cceb4d55ca22590b0d7c2c62b9de38ac4a4a7f4687421/gast-0.2.2.tar.gz
    Collecting tensorflow-estimator==1.15.1
      Downloading https://files.pythonhosted.org/packages/de/62/2ee9cd74c9fa2fa450877847ba560b260f5d0fb70ee0595203082dafcc9d/tensorflow_estimator-1.15.1-py2.py3-none-any.whl (503kB)
         |████████████████████████████████| 512kB 46.6MB/s
    Requirement already satisfied: wrapt>=1.11.1 in /usr/local/lib/python3.6/dist-packages (from tensorflow-gpu==1.15.0) (1.12.1)
    Requirement already satisfied: google-pasta>=0.1.6 in /usr/local/lib/python3.6/dist-packages (from tensorflow-gpu==1.15.0) (0.2.0)
    Requirement already satisfied: opt-einsum>=2.3.2 in /usr/local/lib/python3.6/dist-packages (from tensorflow-gpu==1.15.0) (3.2.1)
    Collecting tensorboard<1.16.0,>=1.15.0
      Downloading https://files.pythonhosted.org/packages/1e/e9/d3d747a97f7188f48aa5eda486907f3b345cd409f0a0850468ba867db246/tensorboard-1.15.0-py3-none-any.whl (3.8MB)
         |████████████████████████████████| 3.8MB 47.4MB/s
    Requirement already satisfied: termcolor>=1.1.0 in /usr/local/lib/python3.6/dist-packages (from tensorflow-gpu==1.15.0) (1.1.0)
    Requirement already satisfied: keras-preprocessing>=1.0.5 in /usr/local/lib/python3.6/dist-packages (from tensorflow-gpu==1.15.0) (1.1.2)
    Requirement already satisfied: numpy<2.0,>=1.16.0 in /usr/local/lib/python3.6/dist-packages (from tensorflow-gpu==1.15.0) (1.18.5)
    Requirement already satisfied: protobuf>=3.6.1 in /usr/local/lib/python3.6/dist-packages (from tensorflow-gpu==1.15.0) (3.10.0)
    Requirement already satisfied: wheel>=0.26 in /usr/local/lib/python3.6/dist-packages (from tensorflow-gpu==1.15.0) (0.34.2)
    Requirement already satisfied: absl-py>=0.7.0 in /usr/local/lib/python3.6/dist-packages (from tensorflow-gpu==1.15.0) (0.9.0)
    Requirement already satisfied: grpcio>=1.8.6 in /usr/local/lib/python3.6/dist-packages (from tensorflow-gpu==1.15.0) (1.29.0)
    Requirement already satisfied: astor>=0.6.0 in /usr/local/lib/python3.6/dist-packages (from tensorflow-gpu==1.15.0) (0.8.1)
    Requirement already satisfied: six>=1.10.0 in /usr/local/lib/python3.6/dist-packages (from tensorflow-gpu==1.15.0) (1.12.0)
    Requirement already satisfied: h5py in /usr/local/lib/python3.6/dist-packages (from keras-applications>=1.0.8->tensorflow-gpu==1.15.0) (2.10.0)
    Requirement already satisfied: werkzeug>=0.11.15 in /usr/local/lib/python3.6/dist-packages (from tensorboard<1.16.0,>=1.15.0->tensorflow-gpu==1.15.0) (1.0.1)
    Requirement already satisfied: setuptools>=41.0.0 in /usr/local/lib/python3.6/dist-packages (from tensorboard<1.16.0,>=1.15.0->tensorflow-gpu==1.15.0) (47.1.1)
    Requirement already satisfied: markdown>=2.6.8 in /usr/local/lib/python3.6/dist-packages (from tensorboard<1.16.0,>=1.15.0->tensorflow-gpu==1.15.0) (3.2.2)
    Requirement already satisfied: importlib-metadata; python_version < "3.8" in /usr/local/lib/python3.6/dist-packages (from markdown>=2.6.8->tensorboard<1.16.0,>=1.15.0->tensorflow-gpu==1.15.0) (1.6.0)
    Requirement already satisfied: zipp>=0.5 in /usr/local/lib/python3.6/dist-packages (from importlib-metadata; python_version < "3.8"->markdown>=2.6.8->tensorboard<1.16.0,>=1.15.0->tensorflow-gpu==1.15.0) (3.1.0)
    Building wheels for collected packages: gast
      Building wheel for gast (setup.py) ... done
      Created wheel for gast: filename=gast-0.2.2-cp36-none-any.whl size=7540 sha256=425ce7b42fc593bbd91ee535b6a88e96450472a3a8c4c66115c99ff7ba37b071
      Stored in directory: /root/.cache/pip/wheels/5c/2e/7e/a1d4d4fcebe6c381f378ce7743a3ced3699feb89bcfbdadadd
    Successfully built gast
    ERROR: tensorflow 2.2.0 has requirement gast==0.3.3, but you'll have gast 0.2.2 which is incompatible.
    ERROR: tensorflow 2.2.0 has requirement tensorboard<2.3.0,>=2.2.0, but you'll have tensorboard 1.15.0 which is incompatible.
    ERROR: tensorflow 2.2.0 has requirement tensorflow-estimator<2.3.0,>=2.2.0, but you'll have tensorflow-estimator 1.15.1 which is incompatible.
    Installing collected packages: gast, tensorflow-estimator, tensorboard, tensorflow-gpu
      Found existing installation: gast 0.3.3
        Uninstalling gast-0.3.3:
          Successfully uninstalled gast-0.3.3
      Found existing installation: tensorflow-estimator 2.2.0
        Uninstalling tensorflow-estimator-2.2.0:
          Successfully uninstalled tensorflow-estimator-2.2.0
      Found existing installation: tensorboard 2.2.2
        Uninstalling tensorboard-2.2.2:
          Successfully uninstalled tensorboard-2.2.2
    Successfully installed gast-0.2.2 tensorboard-1.15.0 tensorflow-estimator-1.15.1 tensorflow-gpu-1.15.0
    Collecting tensorflow-estimator<1.15.0rc0,>=1.14.0rc0
      Downloading https://files.pythonhosted.org/packages/3c/d5/21860a5b11caf0678fbc8319341b0ae21a07156911132e0e71bffed0510d/tensorflow_estimator-1.14.0-py2.py3-none-any.whl (488kB)
         |████████████████████████████████| 491kB 2.8MB/s
    ERROR: tensorflow 2.2.0 has requirement gast==0.3.3, but you'll have gast 0.2.2 which is incompatible.
    ERROR: tensorflow 2.2.0 has requirement tensorboard<2.3.0,>=2.2.0, but you'll have tensorboard 1.15.0 which is incompatible.
    ERROR: tensorflow 2.2.0 has requirement tensorflow-estimator<2.3.0,>=2.2.0, but you'll have tensorflow-estimator 1.14.0 which is incompatible.
    ERROR: tensorflow-gpu 1.15.0 has requirement tensorflow-estimator==1.15.1, but you'll have tensorflow-estimator 1.14.0 which is incompatible.
    Installing collected packages: tensorflow-estimator
      Found existing installation: tensorflow-estimator 1.15.1
        Uninstalling tensorflow-estimator-1.15.1:
          Successfully uninstalled tensorflow-estimator-1.15.1
    Successfully installed tensorflow-estimator-1.14.0

```
!wget https://developer.nvidia.com/compute/cuda/9.0/Prod/local_installers/cuda-repo-ubuntu1604-9-0-local_9.0.176-1_amd64-deb
!dpkg -i cuda-repo-ubuntu1604-9-0-local_9.0.176-1_amd64-deb
!apt-key add /var/cuda-repo-*/7fa2af80.pub
!apt-get update
!apt-get install cuda-9-0
!export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/cuda-9.0/lib64/

```

    --2020-06-15 10:09:48--  https://developer.nvidia.com/compute/cuda/9.0/Prod/local_installers/cuda-repo-ubuntu1604-9-0-local_9.0.176-1_amd64-deb
    Resolving developer.nvidia.com (developer.nvidia.com)... 152.199.0.24
    Connecting to developer.nvidia.com (developer.nvidia.com)|152.199.0.24|:443... connected.
    HTTP request sent, awaiting response... 302 Found
    Location: https://developer.download.nvidia.com/compute/cuda/9.0/secure/Prod/local_installers/cuda-repo-ubuntu1604-9-0-local_9.0.176-1_amd64.deb?gUtgPN8b4r1uJyiqslHDjh90d1saPEfnVk3xHtNdMAzpjoyIjoWNhVIQyBG6GGyfHE7QWUem_aXGEMK3a-Nb2ANN91w64XlWH7k87vBJmo0vqTW1WvDAFmpRGksIe5oqvGA0wTbdy2HrAdIkc7PNfVPGeeIDpbwEmfHqIlI-T5L41YXU_XoRa2WVaWsTYdNaQN0SgSAKMuHLLNLMRCav [following]
    --2020-06-15 10:09:49--  https://developer.download.nvidia.com/compute/cuda/9.0/secure/Prod/local_installers/cuda-repo-ubuntu1604-9-0-local_9.0.176-1_amd64.deb?gUtgPN8b4r1uJyiqslHDjh90d1saPEfnVk3xHtNdMAzpjoyIjoWNhVIQyBG6GGyfHE7QWUem_aXGEMK3a-Nb2ANN91w64XlWH7k87vBJmo0vqTW1WvDAFmpRGksIe5oqvGA0wTbdy2HrAdIkc7PNfVPGeeIDpbwEmfHqIlI-T5L41YXU_XoRa2WVaWsTYdNaQN0SgSAKMuHLLNLMRCav
    Resolving developer.download.nvidia.com (developer.download.nvidia.com)... 152.199.39.144
    Connecting to developer.download.nvidia.com (developer.download.nvidia.com)|152.199.39.144|:443... connected.
    HTTP request sent, awaiting response... 200 OK
    Length: 1212738714 (1.1G) [application/x-deb]
    Saving to: ‘cuda-repo-ubuntu1604-9-0-local_9.0.176-1_amd64-deb.1’

    cuda-repo-ubuntu160 100%[===================>]   1.13G  46.2MB/s    in 21s

    2020-06-15 10:10:13 (54.9 MB/s) - ‘cuda-repo-ubuntu1604-9-0-local_9.0.176-1_amd64-deb.1’ saved [1212738714/1212738714]

    Selecting previously unselected package cuda-repo-ubuntu1604-9-0-local.
    (Reading database ... 144328 files and directories currently installed.)
    Preparing to unpack cuda-repo-ubuntu1604-9-0-local_9.0.176-1_amd64-deb ...
    Unpacking cuda-repo-ubuntu1604-9-0-local (9.0.176-1) ...
    Setting up cuda-repo-ubuntu1604-9-0-local (9.0.176-1) ...
    OK
    Get:1 file:/var/cuda-repo-9-0-local  InRelease
    Ign:1 file:/var/cuda-repo-9-0-local  InRelease
    Get:2 file:/var/cuda-repo-9-0-local  Release [574 B]
    Get:2 file:/var/cuda-repo-9-0-local  Release [574 B]
    Get:3 file:/var/cuda-repo-9-0-local  Release.gpg [819 B]
    Get:3 file:/var/cuda-repo-9-0-local  Release.gpg [819 B]
    Get:4 file:/var/cuda-repo-9-0-local  Packages [15.4 kB]
    Ign:5 https://developer.download.nvidia.com/compute/cuda/repos/ubuntu1804/x86_64  InRelease
    Get:6 http://security.ubuntu.com/ubuntu bionic-security InRelease [88.7 kB]
    Ign:7 https://developer.download.nvidia.com/compute/machine-learning/repos/ubuntu1804/x86_64  InRelease
    Hit:8 https://developer.download.nvidia.com/compute/cuda/repos/ubuntu1804/x86_64  Release
    Get:9 https://cloud.r-project.org/bin/linux/ubuntu bionic-cran35/ InRelease [3,626 B]
    Get:10 https://developer.download.nvidia.com/compute/machine-learning/repos/ubuntu1804/x86_64  Release [564 B]
    Get:11 https://developer.download.nvidia.com/compute/machine-learning/repos/ubuntu1804/x86_64  Release.gpg [833 B]
    Hit:12 http://archive.ubuntu.com/ubuntu bionic InRelease
    Hit:13 http://ppa.launchpad.net/graphics-drivers/ppa/ubuntu bionic InRelease
    Get:15 https://cloud.r-project.org/bin/linux/ubuntu bionic-cran35/ Packages [93.1 kB]
    Get:16 http://archive.ubuntu.com/ubuntu bionic-updates InRelease [88.7 kB]
    Get:17 http://ppa.launchpad.net/marutter/c2d4u3.5/ubuntu bionic InRelease [15.4 kB]
    Get:18 https://developer.download.nvidia.com/compute/machine-learning/repos/ubuntu1804/x86_64  Packages [32.9 kB]
    Get:19 http://archive.ubuntu.com/ubuntu bionic-backports InRelease [74.6 kB]
    Get:20 http://security.ubuntu.com/ubuntu bionic-security/main amd64 Packages [958 kB]
    Get:21 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 Packages [1,253 kB]
    Get:22 http://ppa.launchpad.net/marutter/c2d4u3.5/ubuntu bionic/main Sources [1,837 kB]
    Get:23 http://archive.ubuntu.com/ubuntu bionic-updates/universe amd64 Packages [1,392 kB]
    Get:24 http://ppa.launchpad.net/marutter/c2d4u3.5/ubuntu bionic/main amd64 Packages [886 kB]
    Fetched 6,725 kB in 6s (1,060 kB/s)
    Reading package lists... Done
    Reading package lists... Done
    Building dependency tree
    Reading state information... Done
    The following package was automatically installed and is no longer required:
      libnvidia-common-440
    Use 'apt autoremove' to remove it.
    The following additional packages will be installed:
      cuda-command-line-tools-9-0 cuda-core-9-0 cuda-cublas-9-0
      cuda-cublas-dev-9-0 cuda-cudart-9-0 cuda-cudart-dev-9-0 cuda-cufft-9-0
      cuda-cufft-dev-9-0 cuda-curand-9-0 cuda-curand-dev-9-0 cuda-cusolver-9-0
      cuda-cusolver-dev-9-0 cuda-cusparse-9-0 cuda-cusparse-dev-9-0
      cuda-demo-suite-9-0 cuda-documentation-9-0 cuda-driver-dev-9-0
      cuda-libraries-9-0 cuda-libraries-dev-9-0 cuda-license-9-0
      cuda-misc-headers-9-0 cuda-npp-9-0 cuda-npp-dev-9-0 cuda-nvgraph-9-0
      cuda-nvgraph-dev-9-0 cuda-nvml-dev-9-0 cuda-nvrtc-9-0 cuda-nvrtc-dev-9-0
      cuda-runtime-9-0 cuda-samples-9-0 cuda-toolkit-9-0 cuda-visual-tools-9-0
    The following NEW packages will be installed:
      cuda-9-0 cuda-command-line-tools-9-0 cuda-core-9-0 cuda-cublas-9-0
      cuda-cublas-dev-9-0 cuda-cudart-9-0 cuda-cudart-dev-9-0 cuda-cufft-9-0
      cuda-cufft-dev-9-0 cuda-curand-9-0 cuda-curand-dev-9-0 cuda-cusolver-9-0
      cuda-cusolver-dev-9-0 cuda-cusparse-9-0 cuda-cusparse-dev-9-0
      cuda-demo-suite-9-0 cuda-documentation-9-0 cuda-driver-dev-9-0
      cuda-libraries-9-0 cuda-libraries-dev-9-0 cuda-license-9-0
      cuda-misc-headers-9-0 cuda-npp-9-0 cuda-npp-dev-9-0 cuda-nvgraph-9-0
      cuda-nvgraph-dev-9-0 cuda-nvml-dev-9-0 cuda-nvrtc-9-0 cuda-nvrtc-dev-9-0
      cuda-runtime-9-0 cuda-samples-9-0 cuda-toolkit-9-0 cuda-visual-tools-9-0
    0 upgraded, 33 newly installed, 0 to remove and 44 not upgraded.
    Need to get 0 B/1,097 MB of archives.
    After this operation, 2,315 MB of additional disk space will be used.
    Get:1 file:/var/cuda-repo-9-0-local  cuda-license-9-0 9.0.176-1 [22.0 kB]
    Get:2 file:/var/cuda-repo-9-0-local  cuda-misc-headers-9-0 9.0.176-1 [684 kB]
    Get:3 file:/var/cuda-repo-9-0-local  cuda-core-9-0 9.0.176-1 [16.9 MB]
    Get:4 file:/var/cuda-repo-9-0-local  cuda-cudart-9-0 9.0.176-1 [106 kB]
    Get:5 file:/var/cuda-repo-9-0-local  cuda-driver-dev-9-0 9.0.176-1 [10.9 kB]
    Get:6 file:/var/cuda-repo-9-0-local  cuda-cudart-dev-9-0 9.0.176-1 [767 kB]
    Get:7 file:/var/cuda-repo-9-0-local  cuda-command-line-tools-9-0 9.0.176-1 [25.4 MB]
    Get:8 file:/var/cuda-repo-9-0-local  cuda-nvrtc-9-0 9.0.176-1 [6,348 kB]
    Get:9 file:/var/cuda-repo-9-0-local  cuda-nvrtc-dev-9-0 9.0.176-1 [9,334 B]
    Get:10 file:/var/cuda-repo-9-0-local  cuda-cusolver-9-0 9.0.176-1 [26.2 MB]
    Get:11 file:/var/cuda-repo-9-0-local  cuda-cusolver-dev-9-0 9.0.176-1 [5,317 kB]
    Get:12 file:/var/cuda-repo-9-0-local  cuda-cublas-9-0 9.0.176-1 [25.0 MB]
    Get:13 file:/var/cuda-repo-9-0-local  cuda-cublas-dev-9-0 9.0.176-1 [49.4 MB]
    Get:14 file:/var/cuda-repo-9-0-local  cuda-cufft-9-0 9.0.176-1 [84.1 MB]
    Get:15 file:/var/cuda-repo-9-0-local  cuda-cufft-dev-9-0 9.0.176-1 [73.7 MB]
    Get:16 file:/var/cuda-repo-9-0-local  cuda-curand-9-0 9.0.176-1 [38.8 MB]
    Get:17 file:/var/cuda-repo-9-0-local  cuda-curand-dev-9-0 9.0.176-1 [57.9 MB]
    Get:18 file:/var/cuda-repo-9-0-local  cuda-cusparse-9-0 9.0.176-1 [25.2 MB]
    Get:19 file:/var/cuda-repo-9-0-local  cuda-cusparse-dev-9-0 9.0.176-1 [25.3 MB]
    Get:20 file:/var/cuda-repo-9-0-local  cuda-npp-9-0 9.0.176-1 [46.6 MB]
    Get:21 file:/var/cuda-repo-9-0-local  cuda-npp-dev-9-0 9.0.176-1 [46.6 MB]
    Get:22 file:/var/cuda-repo-9-0-local  cuda-nvgraph-9-0 9.0.176-1 [6,081 kB]
    Get:23 file:/var/cuda-repo-9-0-local  cuda-nvgraph-dev-9-0 9.0.176-1 [5,658 kB]
    Get:24 file:/var/cuda-repo-9-0-local  cuda-samples-9-0 9.0.176-1 [75.9 MB]
    Get:25 file:/var/cuda-repo-9-0-local  cuda-documentation-9-0 9.0.176-1 [53.1 MB]
    Get:26 file:/var/cuda-repo-9-0-local  cuda-libraries-dev-9-0 9.0.176-1 [2,596 B]
    Get:27 file:/var/cuda-repo-9-0-local  cuda-nvml-dev-9-0 9.0.176-1 [47.6 kB]
    Get:28 file:/var/cuda-repo-9-0-local  cuda-visual-tools-9-0 9.0.176-1 [398 MB]
    Get:29 file:/var/cuda-repo-9-0-local  cuda-toolkit-9-0 9.0.176-1 [2,836 B]
    Get:30 file:/var/cuda-repo-9-0-local  cuda-libraries-9-0 9.0.176-1 [2,566 B]
    Get:31 file:/var/cuda-repo-9-0-local  cuda-runtime-9-0 9.0.176-1 [2,526 B]
    Get:32 file:/var/cuda-repo-9-0-local  cuda-demo-suite-9-0 9.0.176-1 [3,880 kB]
    Get:33 file:/var/cuda-repo-9-0-local  cuda-9-0 9.0.176-1 [2,552 B]
    Extracting templates from packages: 100%
    Selecting previously unselected package cuda-license-9-0.
    (Reading database ... 144387 files and directories currently installed.)
    Preparing to unpack .../00-cuda-license-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-license-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-misc-headers-9-0.
    Preparing to unpack .../01-cuda-misc-headers-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-misc-headers-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-core-9-0.
    Preparing to unpack .../02-cuda-core-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-core-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-cudart-9-0.
    Preparing to unpack .../03-cuda-cudart-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-cudart-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-driver-dev-9-0.
    Preparing to unpack .../04-cuda-driver-dev-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-driver-dev-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-cudart-dev-9-0.
    Preparing to unpack .../05-cuda-cudart-dev-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-cudart-dev-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-command-line-tools-9-0.
    Preparing to unpack .../06-cuda-command-line-tools-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-command-line-tools-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-nvrtc-9-0.
    Preparing to unpack .../07-cuda-nvrtc-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-nvrtc-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-nvrtc-dev-9-0.
    Preparing to unpack .../08-cuda-nvrtc-dev-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-nvrtc-dev-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-cusolver-9-0.
    Preparing to unpack .../09-cuda-cusolver-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-cusolver-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-cusolver-dev-9-0.
    Preparing to unpack .../10-cuda-cusolver-dev-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-cusolver-dev-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-cublas-9-0.
    Preparing to unpack .../11-cuda-cublas-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-cublas-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-cublas-dev-9-0.
    Preparing to unpack .../12-cuda-cublas-dev-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-cublas-dev-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-cufft-9-0.
    Preparing to unpack .../13-cuda-cufft-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-cufft-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-cufft-dev-9-0.
    Preparing to unpack .../14-cuda-cufft-dev-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-cufft-dev-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-curand-9-0.
    Preparing to unpack .../15-cuda-curand-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-curand-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-curand-dev-9-0.
    Preparing to unpack .../16-cuda-curand-dev-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-curand-dev-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-cusparse-9-0.
    Preparing to unpack .../17-cuda-cusparse-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-cusparse-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-cusparse-dev-9-0.
    Preparing to unpack .../18-cuda-cusparse-dev-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-cusparse-dev-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-npp-9-0.
    Preparing to unpack .../19-cuda-npp-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-npp-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-npp-dev-9-0.
    Preparing to unpack .../20-cuda-npp-dev-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-npp-dev-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-nvgraph-9-0.
    Preparing to unpack .../21-cuda-nvgraph-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-nvgraph-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-nvgraph-dev-9-0.
    Preparing to unpack .../22-cuda-nvgraph-dev-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-nvgraph-dev-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-samples-9-0.
    Preparing to unpack .../23-cuda-samples-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-samples-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-documentation-9-0.
    Preparing to unpack .../24-cuda-documentation-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-documentation-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-libraries-dev-9-0.
    Preparing to unpack .../25-cuda-libraries-dev-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-libraries-dev-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-nvml-dev-9-0.
    Preparing to unpack .../26-cuda-nvml-dev-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-nvml-dev-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-visual-tools-9-0.
    Preparing to unpack .../27-cuda-visual-tools-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-visual-tools-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-toolkit-9-0.
    Preparing to unpack .../28-cuda-toolkit-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-toolkit-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-libraries-9-0.
    Preparing to unpack .../29-cuda-libraries-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-libraries-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-runtime-9-0.
    Preparing to unpack .../30-cuda-runtime-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-runtime-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-demo-suite-9-0.
    Preparing to unpack .../31-cuda-demo-suite-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-demo-suite-9-0 (9.0.176-1) ...
    Selecting previously unselected package cuda-9-0.
    Preparing to unpack .../32-cuda-9-0_9.0.176-1_amd64.deb ...
    Unpacking cuda-9-0 (9.0.176-1) ...
    Setting up cuda-license-9-0 (9.0.176-1) ...
    *** LICENSE AGREEMENT ***
    By using this software you agree to fully comply with the terms and
    conditions of the EULA (End User License Agreement). The EULA is located
    at /usr/local/cuda-9.0/doc/EULA.txt. The EULA can also be found at
    http://docs.nvidia.com/cuda/eula/index.html. If you do not agree to the
    terms and conditions of the EULA, do not use the software.

    Setting up cuda-cusparse-9-0 (9.0.176-1) ...
    Setting up cuda-cudart-9-0 (9.0.176-1) ...
    Setting up cuda-nvrtc-9-0 (9.0.176-1) ...
    Setting up cuda-cusparse-dev-9-0 (9.0.176-1) ...
    Setting up cuda-cufft-9-0 (9.0.176-1) ...
    Setting up cuda-cusolver-9-0 (9.0.176-1) ...
    Setting up cuda-nvml-dev-9-0 (9.0.176-1) ...
    Setting up cuda-npp-9-0 (9.0.176-1) ...
    Setting up cuda-cusolver-dev-9-0 (9.0.176-1) ...
    Setting up cuda-misc-headers-9-0 (9.0.176-1) ...
    Setting up cuda-cublas-9-0 (9.0.176-1) ...
    Setting up cuda-nvrtc-dev-9-0 (9.0.176-1) ...
    Setting up cuda-driver-dev-9-0 (9.0.176-1) ...
    Setting up cuda-curand-9-0 (9.0.176-1) ...
    Setting up cuda-nvgraph-9-0 (9.0.176-1) ...
    Setting up cuda-core-9-0 (9.0.176-1) ...
    Setting up cuda-libraries-9-0 (9.0.176-1) ...
    Setting up cuda-runtime-9-0 (9.0.176-1) ...
    Setting up cuda-cudart-dev-9-0 (9.0.176-1) ...
    Setting up cuda-cufft-dev-9-0 (9.0.176-1) ...
    Setting up cuda-npp-dev-9-0 (9.0.176-1) ...
    Setting up cuda-curand-dev-9-0 (9.0.176-1) ...
    Setting up cuda-cublas-dev-9-0 (9.0.176-1) ...
    Setting up cuda-nvgraph-dev-9-0 (9.0.176-1) ...
    Setting up cuda-command-line-tools-9-0 (9.0.176-1) ...
    Setting up cuda-demo-suite-9-0 (9.0.176-1) ...
    Setting up cuda-visual-tools-9-0 (9.0.176-1) ...
    Setting up cuda-samples-9-0 (9.0.176-1) ...
    Setting up cuda-libraries-dev-9-0 (9.0.176-1) ...
    Setting up cuda-documentation-9-0 (9.0.176-1) ...
    Setting up cuda-toolkit-9-0 (9.0.176-1) ...
    Setting up cuda-9-0 (9.0.176-1) ...
    Processing triggers for libc-bin (2.27-3ubuntu1) ...
    /sbin/ldconfig.real: /usr/local/lib/python3.6/dist-packages/ideep4py/lib/libmkldnn.so.0 is not a symbolic link

# Training & Running it

Here you download the model, several sizes available: 128M, 774M, 1558M

```
#  !python3 download_model.py 1558M
!python3 download_model.py 774M
```

    Fetching checkpoint: 1.00kit [00:00, 834kit/s]
    Fetching encoder.json: 1.04Mit [00:00, 50.7Mit/s]
    Fetching hparams.json: 1.00kit [00:00, 663kit/s]
    Fetching model.ckpt.data-00000-of-00001: 3.10Git [01:23, 37.3Mit/s]
    Fetching model.ckpt.index: 16.0kit [00:00, 9.74Mit/s]
    Fetching model.ckpt.meta: 1.38Mit [00:00, 52.4Mit/s]
    Fetching vocab.bpe: 457kit [00:00, 49.9Mit/s]

## Training

To train, use the this. Some parameters you have to change:

*   The pre-trained model (128M, etc.)
*   The dataset file: a single big text file
*   Batch size should be 1 for the biggest model on a TPU

```
# For training only
# !PYTHONPATH=src python3 train.py  --model_name 774M --run_name "run_large_critical_v2" --dataset G1_ALL_v2.txt --batch_size 1 --save_every 100 --sample_every 50 --sample_num 1 --sample_length 500  --save_on_ctrlc --save_time 100 --max_to_keep 1 --learning_rate 0.00001   # --accumulate_gradients 2 # # --optimizer sgd #--memory_saving_gradients

```

## Inference

Now, the code to actually run the model!

```
import os
import sys
import fire
import json
import numpy as np
import tensorflow as tf
import tflex

DIRNAM  E = "/content/drive/My Drive/SLACKBOT/gpt-2/src"
sys.path.append(DIRNAME)
print(sys.path)

import model, sample, encoder

```

    WARNING:tensorflow:From /content/drive/My Drive/SLACKBOT/gpt-2/tflex.py:33: The name tf.Session is deprecated. Please use tf.compat.v1.Session instead.

    WARNING:tensorflow:From /content/drive/My Drive/SLACKBOT/gpt-2/tflex.py:184: The name tf.train.SaverDef is deprecated. Please use tf.compat.v1.train.SaverDef instead.

    attach_debugger <function attach_debugger at 0x7faf9be55f28>
    print_status <function print_status at 0x7faf9be581e0>
    freeze_forever <function freeze_forever at 0x7faf9be580d0>
    quit <function quit at 0x7faf9be58488>
    save_and_quit <function save_and_quit at 0x7faf9be58378>
    ['', '/env/python', '/usr/lib/python36.zip', '/usr/lib/python3.6', '/usr/lib/python3.6/lib-dynload', '/usr/local/lib/python3.6/dist-packages', '/usr/lib/python3/dist-packages', '/usr/local/lib/python3.6/dist-packages/IPython/extensions', '/root/.ipython', '/content/drive/My Drive/SLACKBOT/gpt-2/src']
    WARNING:tensorflow:From /content/drive/My Drive/SLACKBOT/gpt-2/src/model.py:171: The name tf.AUTO_REUSE is deprecated. Please use tf.compat.v1.AUTO_REUSE instead.

```
def sample_model(
    model_name='117M',
    restore_from=None,
    seed=None,
    nsamples=0,
    batch_size=1,
    length=None,
    temperature=1,
    top_k=0,
    top_p=0.0,
    penalize=0
):
    """
    Run the sample_model
    :model_name=117M : String, which model to use
    :seed=None : Integer seed for random number generators, fix seed to
     reproduce results
    :nsamples=0 : Number of samples to return, if 0, continues to
     generate samples indefinately.
    :batch_size=1 : Number of batches (only affects speed/memory).
    :length=None : Number of tokens in generated text, if None (default), is
     determined by model hyperparameters
    :temperature=1 : Float value controlling randomness in boltzmann
     distribution. Lower temperature results in less random completions. As the
     temperature approaches zero, the model will become deterministic and
     repetitive. Higher temperature results in more random completions.
    :top_k=0 : Integer value controlling diversity. 1 means only 1 word is
     considered for each step (token), resulting in deterministic completions,
     while 40 means 40 words are considered at each step. 0 (default) is a
     special setting meaning no restrictions. 40 generally is a good value.
    :top_p=0.0 : Float value controlling diversity. Implements nucleus sampling,
     overriding top_k if set to a value > 0. A good setting is 0.9.
    :penalize=0.0 : Float value controlling "used" penalty. Implements repetition
     reduction (similar to CTRL) if set to a value > 0. A decent setting might be 0.85
     with temperature 0.3 and top_k 40.
    """
    enc = encoder.get_encoder(model_name)
    hparams = model.default_hparams()
    with open(os.path.join('models', model_name, 'hparams.json')) as f:
        hparams.override_from_dict(json.load(f))

    if length is None:
        length = hparams.n_ctx
    elif length > hparams.n_ctx:
        raise ValueError("Can't get samples longer than window size: %s" % hparams.n_ctx)

    with tflex.Session(graph=tf.Graph()) as sess:
        np.random.seed(seed)
        tf.set_random_seed(seed)

        output = sample.sample_sequence(
            hparams=hparams, length=length,
            start_token=enc.encoder['<|endoftext|>'],
            batch_size=batch_size,
            temperature=temperature, top_k=top_k, top_p=top_p, penalize=penalize
        )[:, 1:]

        saver = tflex.Saver()
        if restore_from is None:
          restore_from = os.path.join('models', model_name)
        ckpt = tflex.latest_checkpoint(restore_from)
        saver.restore(sess, ckpt)

        generated = 0
        while nsamples == 0 or generated < nsamples:
            out = sess.run(output)
            for i in range(batch_size):
                generated += 1
                text = enc.decode(out[i])
                print("=" * 40 + " SAMPLE " + str(generated) + " " + "=" * 40)
                print(text)

def interact_model(
    model_name='117M',
    restore_from=None,
    seed=None,
    nsamples=1,
    batch_size=1,
    length=None,
    temperature=1,
    top_k=0,
    top_p=0.0,
    penalize=0,
    prompt=None
):
    """
    Interactively run the model
    :model_name=117M : String, which model to use
    :seed=None : Integer seed for random number generators, fix seed to reproduce
     results
    :nsamples=1 : Number of samples to return total
    :batch_size=1 : Number of batches (only affects speed/memory).  Must divide nsamples.
    :length=None : Number of tokens in generated text, if None (default), is
     determined by model hyperparameters
    :temperature=1 : Float value controlling randomness in boltzmann
     distribution. Lower temperature results in less random completions. As the
     temperature approaches zero, the model will become deterministic and
     repetitive. Higher temperature results in more random completions.
    :top_k=0 : Integer value controlling diversity. 1 means only 1 word is
     considered for each step (token), resulting in deterministic completions,
     while 40 means 40 words are considered at each step. 0 (default) is a
     special setting meaning no restrictions. 40 generally is a good value.
    :top_p=0.0 : Float value controlling diversity. Implements nucleus sampling,
     overriding top_k if set to a value > 0. A good setting is 0.9.
    :penalize=0.0 : Float value controlling "used" penalty. Implements repetition
     reduction (similar to CTRL) if set to a value > 0. A decent setting might be 0.85
     with temperature 0.3 and top_k 40.
    """
    if batch_size is None:
        batch_size = 1
    assert nsamples % batch_size == 0

    enc = encoder.get_encoder(model_name)
    hparams = model.default_hparams()
    with open(os.path.join('models', model_name, 'hparams.json')) as f:
        hparams.override_from_dict(json.load(f))

    if length is None:
        length = hparams.n_ctx // 2
    elif length > hparams.n_ctx:
        raise ValueError("Can't get samples longer than window size: %s" % hparams.n_ctx)

    with tflex.Session(graph=tf.Graph()) as sess:
        context = tf.placeholder(tf.int32, [batch_size, None])
        np.random.seed(seed)
        tf.set_random_seed(seed)
        output = sample.sample_sequence(
            hparams=hparams, length=length,
            context=context,
            batch_size=batch_size,
            temperature=temperature, top_k=top_k, top_p=top_p, penalize=penalize
        )

        saver = tflex.Saver()
        if restore_from is None:
          restore_from = os.path.join('models', model_name)
        ckpt = tflex.latest_checkpoint(restore_from)
        saver.restore(sess, ckpt)

        while True:
            if prompt is not None:
              if os.path.isfile(prompt):
                  with open(prompt) as f:
                      raw_text = f.read()
              else:
                  raw_text = prompt
            else:
                raw_text = input("Model prompt >>> ")
                if not raw_text:
                    raw_text="\n"
            if len(raw_text) > 1 and raw_text.endswith('\n'):
                raw_text = raw_text[:-1]
            print('Prompt:', repr(raw_text))
            context_tokens = enc.encode(raw_text)
            generated = 0
            for _ in range(nsamples // batch_size):
                out = sess.run(output, feed_dict={
                    context: [context_tokens for _ in range(batch_size)]
                })[:, len(context_tokens):]
                for i in range(batch_size):
                    generated += 1
                    text = enc.decode(out[i])
                    print("=" * 40 + " SAMPLE " + str(generated) + " " + "=" * 40)
                    sys.stdout.write(raw_text)
                    print(text)
                    sys.stdout.flush()
            print("=" * 80)
```

```
sample_model(top_k=40, temperature=0.4, penalize=0.85, model_name="774M", nsamples=2)
```

    WARNING:tensorflow:From /content/drive/My Drive/SLACKBOT/gpt-2/src/model.py:173: The name tf.variable_scope is deprecated. Please use tf.compat.v1.variable_scope instead.

    WARNING:tensorflow:From /content/drive/My Drive/SLACKBOT/gpt-2/src/model.py:20: The name tf.get_variable_scope is deprecated. Please use tf.compat.v1.get_variable_scope instead.

    WARNING:tensorflow:From /content/drive/My Drive/SLACKBOT/gpt-2/src/model.py:21: The name tf.trainable_variables is deprecated. Please use tf.compat.v1.trainable_variables instead.

    WARNING:tensorflow:From /content/drive/My Drive/SLACKBOT/gpt-2/src/model.py:177: The name tf.get_variable is deprecated. Please use tf.compat.v1.get_variable instead.

    WARNING:tensorflow:From /content/drive/My Drive/SLACKBOT/gpt-2/src/model.py:178: calling RandomNormal.__init__ (from tensorflow.python.ops.init_ops) with dtype is deprecated and will be removed in a future version.
    Instructions for updating:
    Call initializer instance with the dtype argument instead of passing it to the constructor
    WARNING:tensorflow:From /content/drive/My Drive/SLACKBOT/gpt-2/src/model.py:45: calling Constant.__init__ (from tensorflow.python.ops.init_ops) with dtype is deprecated and will be removed in a future version.
    Instructions for updating:
    Call initializer instance with the dtype argument instead of passing it to the constructor
    WARNING:tensorflow:From /content/drive/My Drive/SLACKBOT/gpt-2/src/model.py:49: The name tf.rsqrt is deprecated. Please use tf.math.rsqrt instead.

    WARNING:tensorflow:From /content/drive/My Drive/SLACKBOT/gpt-2/src/model.py:191: The name tf.add_to_collection is deprecated. Please use tf.compat.v1.add_to_collection instead.

    WARNING:tensorflow:From /content/drive/My Drive/SLACKBOT/gpt-2/src/sample.py:81: to_float (from tensorflow.python.ops.math_ops) is deprecated and will be removed in a future version.
    Instructions for updating:
    Use `tf.cast` instead.
    WARNING:tensorflow:From /content/drive/My Drive/SLACKBOT/gpt-2/src/sample.py:17: where (from tensorflow.python.ops.array_ops) is deprecated and will be removed in a future version.
    Instructions for updating:
    Use tf.where in 2.0, which has the same broadcast rule as np.where
    WARNING:tensorflow:From /content/drive/My Drive/SLACKBOT/gpt-2/src/sample.py:88: multinomial (from tensorflow.python.ops.random_ops) is deprecated and will be removed in a future version.
    Instructions for updating:
    Use `tf.random.categorical` instead.

    100%|██████████| 4/4 [00:49<00:00, 12.28s/it]

    ======================================== SAMPLE 1 ========================================
    The following is a list of items that make good gifts for Tia, who likes Sporty, white items and dislikes Cute/Fancy items.

    Best Gifts for Tia: Sporty, white items

    The following items have Tia's favorite style and color.

    Name Type Name Color 1 Color 2 tank top yellow white blue tartan shirt top aqua white blue tartan tee top aqua white blue-grid shirt top aqua white blue-grid tee top aqua white bubble tank top colorful white bubble tee top colorful white bunny shirt top aqua white bunny tee top aqua white chevron shirt top red white chevron tee top red white cyan argyle shirt top aqua gray cyan argyle tee top aqua gray dapper shirt top orange white dapper tee top orange white dogtooth shirt top gray black dogtooth tee top gray black dragon jacket top purple white elephant shirt top blue pink elephant tee top blue pink floral knit tee top green white flowery tee top pink white frog costume top green white frog shirt top green beige frog tee top green beige genie shirt top aqua white genie vest top aqua white giraffe tank top yellow brown giraffe tee top yellow brown jagged tank top yellow aqua jagged tee top yellow aqua kiwi tank top yellow green kiwi tee top yellow green lemon gingham shirt top yellow white lemon gingham tee top yellow white melon gingham shirt top yellow white melon gingham tee top yellow white morning glory furniture green white morning glory sign furniture green white paper tiger furniture yellow white peachy tank top yellow green peachy tee top yellow green picnic basket furniture green white pine bonsai furniture green white pikmin furniture green white pinball machine furniture colorful white raccoon figurine furniture colorful white red-tasseled lantern furniture red white rose sofa furniture red red round clock furniture red white robo-bed furniture blue white robo-chair furniture blue white robo-clock furniture blue white robo-closet furniture blue white robo-dresser furniture blue white robo-lamp furniture blue white robo-sofa furniture blue white robo-stereo furniture blue white robo-table furniture blue white robo-tv furniture blue white sand castle furniture red brown snowman bed furniture white white snowman bookcase furniture white white snowman chair furniture white white snowman closet furniture white white snowman dresser furniture white white snowman lamp furniture white white snowman low table furniture white white snowman shelf furniture white white snowman sofa furniture white white snowman table furniture white white snowman vanity furniture white white snowman wall clock furniture white white snowman wardrobe furniture white white sphinx furniture yellow brown striped cone furniture yellow none sunflower stereo furniture yellow none super mushroom furniture red colorful tall cactus furniture green white tall mini cactus furniture green white tiki torch furniture red white toadstool furniture green white tricycle furniture yellow white tulip dresser furniture yellow green virtual boy furniture red white wall flowerpot furniture yellow green watermelon chair furniture green red watermelon table furniture green red yoshi's egg furniture green white zodiac boar furniture blue white zodiac goat furniture red white zodiac ox furniture red white zodiac rabbit furniture red white zodiac rat furniture red white zodiac snake furniture yellow white zodiac tiger furniture yellow white bamboo grass furniture green colorful candy cane furniture sweet white candy canes furniture brown white cucumber horse furniture green colorful dab table furniture brown brown festive candle furniture red colorful festive flag furniture red colorful fire hydrant furniture red red florence flask furniture red red folk guitar furniture brown brown game-show stand furniture green white giant dharma furniture red red harpsichord furniture yellow brown hibiscus clock furniture green red hydrangea bed furniture red red hydrangea bench furniture red red hydrangea chair furniture red red hydrangea clock furniture red red hydrangea dresser furniture red red hydrangea lamp furniture red red hydrangea screen furniture red red hydrangea stool furniture red red hydrangea table furniture red red ice bed furniture aqua aqua ice chair furniture aqua aqua ice clock furniture aqua aqua ice closet furniture aqua aqua ice dresser furniture aqua aqua ice lamp furniture red aqua ice side table furniture aqua aqua ice sofa furniture aqua aqua ice table furniture aqua aqua ice tv furniture red black jackhammer furniture red red jellyfish aquarium furniture gray gray keg furniture red red ladybug chair furniture red red lovely doll furniture red red lucky cat furniture red red lunar lander furniture blue aqua moon furniture gray gray mama bear furniture red colorful mush bed furniture aqua white mush chair furniture aqua white mush clock furniture aqua white mush end table furniture aqua white mush lamp furniture aqua white mush sofa furniture aqua white mush table furniture aqua white mush tv furniture red white old sewing machine furniture white white pansy table furniture colorful brown papa bear
    ======================================== SAMPLE 2 ========================================
    The following is a list of items that make good gifts for Stacey, who likes Sporty, blue items and dislikes Ornate items.

    Best Gifts for Stacey: Sporty, blue items

    The following items have Stacey's favorite style and color.

    Name Type Name Color 1 Color 2 blue tartan tee top blue gray blue-grid shirt top aqua white blue-stripe tank top yellow blue blue-zap suit top blue aqua bubble tank top pink purple butterfly tank top colorful white candy gingham shirt top green red coral tank top yellow blue crab boat furniture blue brown dapper dresser furniture blue gray dragon furniture blue black elephant slide furniture yellow blue flame bed furniture orange blue glass display case furniture colorful white globe furniture aqua white gold house model furniture yellow blue gracie bed furniture blue beige grapefruit table furniture green red heart stereo furniture yellow blue hibiscus clock furniture green red ice lamp furniture aqua aqua jasmine bonsai furniture green red king furniture brown brown lady palm furniture green red maple bonsai furniture red red mountain bike furniture yellow blue mochi pestle furniture brown brown octopus chair furniture blue blue pachira furniture red brown pagoda furniture red brown picnic basket furniture blue brown potbelly stove furniture yellow blue pine bonsai furniture green red pop-up book furniture red black princess bed furniture aqua aqua princess cage furniture pink pink robo-bed furniture blue white robo-chair furniture blue white robo-clock furniture blue white robo-closet furniture blue white robo-dresser furniture blue white robo-lamp furniture blue white robo-sofa furniture blue white robo-stereo furniture blue white robo-table furniture blue white robo-tv furniture blue white skeleton figurine furniture white white snow bunny furniture white white sloppy tv furniture brown brown spooky bed furniture red ghostly bed furniture orange white spooky bench furniture orange white spooky bureau furniture orange white spooky chair furniture orange white spooky chest furniture orange white spooky closet furniture orange white spooky dresser furniture orange white spooky lamp furniture orange white spooky sofa furniture orange white spooky table furniture orange white spooky vanity furniture orange white spooky wall lamp furniture orange white tall cactus furniture green blue tall flowerpot furniture green red tiki torch furniture red white toadstool furniture green red tricycle furniture yellow green ukulele furniture brown brown upright piano furniture green green zodiac boar furniture blue white zodiac goat furniture red white zodiac ox furniture red white zodiac rabbit furniture red white zodiac rat furniture red white zodiac snake furniture yellow white zodiac tiger furniture yellow white zodiac turkey furniture orange white zodiac wolf furniture orange white zodiac painting furniture white<|endoftext|>A few months ago I was asked by a friend if I would like to write an article on the "why" behind the success of the U.S. dollar in international trade. This question came from someone who had recently started talking about how the U.S. dollar has been outperforming other currencies since 2008. The answer to this question is not easy to explain without going into detail about what exactly it means to "underperform." It might also seem counterintuitive to suggest that a currency with high purchasing power should perform well, but there are some very strong reasons why this is true.

    I am going to try to give you a brief overview of the most important factors that contribute to a country's ability to outperform its peers when it comes to foreign exchange markets. These factors will help explain why the United States has done so well in terms of trading with other countries over the past decade or two.

    1) A Strong Economy

    First, let's talk about the economy. When it comes to economic performance, we tend to think of the economy as being driven by GDP growth. However, the U.S. economy is actually more than just GDP. In fact, the U.S. government reports that the U.S. gross domestic product (GDP) accounts for only 20% of total U.S. exports. The rest of the value added goes towards services, which include everything from health care to education to transportation. So while GDP does account for a large portion of the overall output, it doesn't tell us all that much about how well a country performs relative to the rest of the world.

    Another way to look at the economy is through the lens of "output per worker," which refers to the amount of goods and services produced by each individual worker. If we compare the average annual earnings of workers in the United States to those of workers in other major economies, we find that the U.S. labor market is quite competitive. For example, the median wage of a full-time, year-round employee in the United States is $26,000 per year. Compare that to the $21,500 earned by a similar worker in Japan, where the average worker earns $13,200 annually.

    2)

```
interact_model(top_k=40, temperature=0.3, penalize=0.85, model_name="774M", nsamples=2)
```

    100%|██████████| 4/4 [00:07<00:00,  1.81s/it]

    Model prompt >>> Razor. Definition:
    Prompt: 'Razor. Definition: '
    ======================================== SAMPLE 1 ========================================
    Razor. Definition:  The term " Razor " is used to describe the blade of a knife, and refers to the sharpened edge on the blade.
    Example: A razor blade is a sharpened blade that has been honed to a point where it can be used for cutting.
    Definition:  A razor is a tool used to cut or shave hair.
    Example: A razor is a tool used to cut or shave hair.
    Definition:  A razor is a tool used to cut or shave hair.
    Example: A razor is a tool used to cut or shave hair.
    Definition:  A razor is a tool used to cut or shave hair.
    Example: A razor is a tool used to cut or shave hair.
    Definition:  A razor is a tool used to cut or shave hair.
    Example: A razor is a tool used to cut or shave hair.
    Definition:  A razor is a tool used to cut or shave hair.
    Example: A razor is a tool used to cut or shave hair.
    Definition:  A razor is a tool used to cut or shave hair.
    Example: A razor is a tool used to cut or shave hair.
    Definition:  A razor is a tool used to cut or shave hair.
    Example: A razor is a tool used to cut or shave hair.
    Definition:  A razor is a tool used to cut or shave hair.
    Example: A razor is a tool used to cut or shave hair.
    Definition:  A razor is a tool used to cut or shave hair.
    Example: A razor is a tool used to cut or shave hair.
    Definition:  A razor is a tool used to cut or shave hair.
    Example: A razor is a tool used to cut or shave hair.
    Definition:  A razor is a tool used to cut or shave hair.
    Example: A razor is a tool used to cut or shave hair.
    Definition:  A razor is a tool used to cut or shave hair.
    Example: A razor is a tool used to cut or shave hair.
    Definition:  A razor is a tool used to cut or shave hair.
    Example: A razor is a tool used to cut or shave hair.
    Definition:  A razor is a tool used to cut or shave hair.
    Example: A razor is a tool used to cut or shave hair.
    Definition:  A razor is a tool
    ======================================== SAMPLE 2 ========================================
    Razor. Definition:  "A razor is a tool that cuts, or slices, a piece of meat."
    The above definition was taken from the Wikipedia article on "Razor". I have not been able to find any reference to this definition in any other source. So what does it mean? Well, it means that a blade has two blades which are joined together by a sharp edge and are used for cutting meat. The first blade is called the "blade", and the second blade is called the "razor". This is the definition given in the Wikipedia article on "Razor":
    "A razor is a tool that cuts, or slices, a piece of meat. It consists of an inner and outer blade, with a sharpened edge between them. The blade may be made of metal, wood, or plastic. A razor can be used to cut through flesh, but typically only when the knife is held at a right angle to the body."
    So, if you want to use a razor for slicing, you need to hold the knife at a right angle to your body. If you don't know how to do that, then here is some advice from my friend, Dr. David M. Bowers. He is a board-certified orthopedic surgeon who specializes in treating patients with injuries to their hands, feet, and lower extremities. Here is his advice on using a razor for cutting meat:
    "If you're going to use a razor for cutting meat, you should hold the knife at a right angle to your body. That way, when you slice, the blade will cut through the meat without tearing the skin off. You'll also be less likely to cause bleeding."
    I hope this helps you understand the difference between a razor and a knife.<|endoftext|>By

    21st Century Wire says…

    This is a very interesting development as it appears that the US government has now officially admitted that they were behind the attack on the Russian embassy in Washington DC over the weekend.

    According to reports, the US State Department has confirmed that the attack was carried out by a group calling itself the 'Islamic State' (IS).

    The report states that the attack was carried out by a group calling themselves the 'Islamic State', which is an acronym for 'Islamic State of Iraq and Syria'.

    It's worth noting that the name IS is often misused by many people, including those within the intelligence community, to refer to ISIS.

    However, the term IS has become synonymous with the terrorist group
    ================================================================================