Search code examples
python-3.xtensorflowgpuspacynamed-entity-recognition

Spacy CLI Training Unable to Activate GPU


I am trying to train a NER Spacy model on the CLI. Following all the steps necessary I finally created a correct input file, however when trying to train on the GPU I get the message that spacy is unable to activate the GPU, other programs actually are able to use my GPU and cuda is set up correctly. Still it doesn't seem to work, I only have 1 GPU in my computer so I selected -g 0 on the CLI. I can't find any further information as why the GPU cannot be activated, searching the internet has led to nothing either.

Training pipeline: ['ner']
⚠ Unable to activate GPU: 0
Using CPU only
  • NVIDIA-driver-version: 440.64
  • CUDA-verion: 10.2
  • GPU GeForce RTX 2060

Image showing the nvidia-smi output


Solution

  • Check that you have the correct version of cupy (from your CUDA version above: cupy-cuda102) installed.