terminate called after throwing an instance of dmlc::Error

在python中使用MxNet时在代码

 self.module.bind(data_shapes=[data_name_shape],
                         for_training=False)
报出一下错误
terminate called after throwing an instance of 'dmlc::Error'
  what():  [07:08:37] src/storage/storage.cc:119: Compile with USE_CUDA=1 to enable GPU usage
Stack trace:

主要原因是使用

pip install mxnet

默认安装得不是gpu版得,应该安装对应cuda版本得mxnet就应该没有问题了。

cuda10.1得下载地址  https://pypi.org/project/mxnet-cu101/#files

posted on 2021-01-20 18:30  NLP实践者  阅读(743)  评论(0编辑  收藏  举报