<commit_before>
## SRK-Lasagne

This dockerfile is destined for research and development of machine learning technologies especially deep learning. It can be use with mesos cluster.
SRK-lasagne is based on:
- debian
- cuda 7.5.18
- miniconda
- bokeh
- lasagne
- theano

### Requirements

- CUDA drivers should be installed for the kernel module on the host using binary package (not deb).

### Usage

One or more NVIDIA devices should be attached to the container

1. Standalone
```
docker run -it --device /dev/nvidiactl --device /dev/nvidia-uvm --device /dev/nvidia0 krot/srk-lasagne
docker run -it --device /dev/nvidiactl --device /dev/nvidia-uvm --device /dev/nvidia0 --device /dev/nvidia1 ... --device /dev/nvidia# krot/srk-lasagne 
```
  where # is number of the NVIDIA device

2. For greater performance, you can also install cuDNN.
  - Download from the cuDNN website
  - Unpack cuDNN in somewhere on the host, e.g. /home/user/cudnn
  - Map the files directly into your container using -v docker option

```
-v /home/user/cudnn/libcudnn.so:/usr/local/cuda/lib64/libcudnn.so:ro \
-v /home/user/cudnn/libcudnn.so.7.0:/usr/local/cuda/lib64/libcudnn.so.7.0:ro \
-v /home/user/cudnn/libcudnn.so.7.0.64:/usr/local/cuda/lib64/libcudnn.so.7.0.64:ro \
-v /home/user/cudnn/libcudnn_static.a:/usr/local/cuda/lib64/libcudnn_static.a:ro \
-v /home/user/cudnn/cudnn.h:/usr/local/cuda/include/libcudnn_static.a:ro \

```
3. Example of a marathon json for mesos
```
{
    "id": "rnn-53",
    "container": {
        "docker": {
            "image": "krot/srk-lasagne",
            "forcePullImage": true,
            "privileged": true
        },
        "type": "DOCKER",
        "volumes": [
          {
           "containerPath": "/data",
           "hostPath": "/mnt/data/repl/rnn",
           "mode": "RW"
          }
       ]
    },
    "args": ["/bin/sh", "-c", "/data/run.sh"],
    "cpus": 4.0,
    "mem": 4000.0,
    "gpu": 1.0,
    "instances": 1
}
```
*Comments.* Mesos custom resources like "gpu" are not supported by marathon and other mesos frameworks yet. 
<commit_msg>Fix markdown<commit_after>
## SRK-Lasagne

This dockerfile is destined for research and development of machine learning technologies especially deep learning. It can be use with mesos cluster.
SRK-lasagne is based on:
- debian
- cuda 7.5.18
- miniconda
- bokeh
- lasagne
- theano

### Requirements

- CUDA drivers should be installed for the kernel module on the host using binary package (not deb).

### Usage

One or more NVIDIA devices should be attached to the container

#### Standalone
```
docker run -it --device /dev/nvidiactl --device /dev/nvidia-uvm --device /dev/nvidia0 krot/srk-lasagne
docker run -it --device /dev/nvidiactl --device /dev/nvidia-uvm --device /dev/nvidia0 --device /dev/nvidia1 ... --device /dev/nvidia# krot/srk-lasagne 
```
  where # is number of the NVIDIA device

#### For greater performance, you can also install cuDNN.
  - Download from the cuDNN website
  - Unpack cuDNN in somewhere on the host, e.g. /home/user/cudnn
  - Map the files directly into your container using -v docker option

```
-v /home/user/cudnn/libcudnn.so:/usr/local/cuda/lib64/libcudnn.so:ro \
-v /home/user/cudnn/libcudnn.so.7.0:/usr/local/cuda/lib64/libcudnn.so.7.0:ro \
-v /home/user/cudnn/libcudnn.so.7.0.64:/usr/local/cuda/lib64/libcudnn.so.7.0.64:ro \
-v /home/user/cudnn/libcudnn_static.a:/usr/local/cuda/lib64/libcudnn_static.a:ro \
-v /home/user/cudnn/cudnn.h:/usr/local/cuda/include/libcudnn_static.a:ro \

```
#### Example of a marathon json for mesos
```
{
    "id": "rnn-53",
    "container": {
        "docker": {
            "image": "krot/srk-lasagne",
            "forcePullImage": true,
            "privileged": true
        },
        "type": "DOCKER",
        "volumes": [
          {
           "containerPath": "/data",
           "hostPath": "/mnt/data/repl/rnn",
           "mode": "RW"
          }
       ]
    },
    "args": ["/bin/sh", "-c", "/data/run.sh"],
    "cpus": 4.0,
    "mem": 4000.0,
    "gpu": 1.0,
    "instances": 1
}
```
*Comments.* Mesos custom resources like "gpu" are not supported by marathon and other mesos frameworks yet. 

{'fraction_non_alphanumeric': 0.14938657685831128, 'fraction_numerical': 0.019485205677171036, 'mean_word_length': 2.6125108601216334, 'pattern_counts': {'":': 32, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2187342', 'n_tokens_mistral': 1618, 'n_tokens_neox': 1500, 'n_words': 392}