title: "Compile with USE_CUDA=1 to enable GPU usage" Message with MXNet on AWS Deep Learning AMI
body: <p>I would like to train a neural network whilst utilising all 4 GPU's on my g2.8xarge EC2 instance using MXNet. I am using the following AWS Deep Learning Linux community AMI:</p>
  
  <p>Deep Learning AMI Amazon Linux - 3.3_Oct2017 - ami-999844e0)</p>
  
  <p>As per these <a href="https://aws.amazon.com/about-aws/whats-new/2017/10/aws-deep-learning-ami-now-supports-pytorch-keras-2-and-latest-deep-learning-frameworks/" rel="nofollow noreferrer">instructions</a>, when I connect to the instance I switch to keras v1 with the MXNet backend by issuing this command:</p>
  
  <pre><code>source ~/src/anaconda3/bin/activate keras1.2_p2
  </code></pre>
  
  <p>I have also added the context flag to my python model compile code to utilise the GPU's in MXNet:</p>
  
  <pre><code>model.compile(loss='binary_crossentropy', optimizer='adam', metrics=['accuracy'], context=gpu_list)
  </code></pre>
  
  <p>where gpu_list is meant to utilise all 4 GPU's.</p>
  
  <p>However every time I run my code, I get this error message:</p>
  
  <blockquote>
    <p>Epoch 1/300
    [15:09:52] /home/travis/build/dmlc/mxnet-distro/mxnet-build/dmlc-core/include/dmlc/logging.h:308: [15:09:52] src/storage/storage.cc:113: Compile with USE_CUDA=1 to enable GPU usage</p>
  </blockquote>
  
  <p>and</p>
  
  <blockquote>
    <p>RuntimeError: simple_bind error. Arguments:
    dense_input_1: (25, 34L)
    [15:09:52] src/storage/storage.cc:113: Compile with USE_CUDA=1 to enable GPU usage</p>
  </blockquote>
  
  <p>I have checked the config.mk file in /home/ec2-user/src/mxnet and it contains USE_CUDA=1. I have also issued the 'made' command to try and recompile MXNet with the USE_CUDA=1 flag - no change.</p>
  
  <p>Am I having this issue as I'm using the virtual environment the AWS documentation says to use? Has anyone else had this issue with MXNet on the AWS Deep Learning Ubuntu AMI using this virtual env?</p>
  
  <p>Any suggestions greatly appreciated -</p>