Open BucherLi opened 5 years ago
其他程序也是默认不使用GPU么,没遇到过这个bug,可能是你的python中的tf环境有问题。
其他程序也是默认不使用GPU么,没遇到过这个bug,可能是你的python中的tf环境有问题。
google bert 源码的分类训练默认用的GPU,bert-as-service启动的时候默认也是用的Gpu。 你能发下你的环境吗
我也遇到同样的问题,使用bert源码训练,然后部署服务之后就检测不到GPU运行。
我之前也是,后来发现有其他进程在使用GPU的时候,服务就不会使用GPU。把其他进程杀死或者找个没人用的GPU都可以检测到。等服务起好了,其他程序训练测试都没影响的
@hurricanedjp 好的,多谢。
请问楼主的问题解决了么,我现在也不能使用GPU,我也检查了我驱动(410.78),cuda(10.0),python(3.6.9)tensorflow-gpu(1.13.1)
pip install tensorflow-gpu = 1.12 安装tensorflow gpu版本
运行bert-base-ner-train 训练结果 ,为啥没用到gpu,tf版本1.12, python版本3.6
save_checkpoints_steps = 500 save_summary_steps = 500 verbose = False vocab_file =~/chinese_L-12_H-768_A-12/vocab.txt warmup_proportion = 0.1
WARNING:tensorflow:From /data/home/user00/python36.8/lib/python3.6/site-packages/tensorflow/python/framework/op_def_library.py:263: colocate_with (from tensorflow.python.framework.ops) is deprecated and will be removed in a future version. Instructions for updating: Colocations handled automatically by placer. WARNING:tensorflow:From /data/home/user00/python36.8/lib/python3.6/site-packages/bert_base/train/bert_lstm_ner.py:334: to_int32 (from tensorflow.python.ops.math_ops) is deprecated and will be removed in a future version. Instructions for updating: Use tf.cast instead. shape of input_ids (64, 128) WARNING:tensorflow:From /data/home/user00/python36.8/lib/python3.6/site-packages/bert_base/bert/modeling.py:359: calling dropout (from tensorflow.python.ops.nn_ops) with keep_prob is deprecated and will be removed in a future version. Instructions for updating: Please use,
rate
instead ofkeep_prob
. Rate should be set torate = 1 - keep_prob
. WARNING:tensorflow:From /data/home/user00/python36.8/lib/python3.6/site-packages/bert_base/bert/modeling.py:673: dense (from tensorflow.python.layers.core) is deprecated and will be removed in a future version. Instructions for updating: Use keras.layers.dense instead. WARNING:tensorflow:From /data/home/user00/python36.8/lib/python3.6/site-packages/tensorflow/contrib/crf/python/ops/crf.py:213: dynamic_rnn (from tensorflow.python.ops.rnn) is deprecated and will be removed in a future version. Instructions for updating: Please usekeras.layers.RNN(cell)
, which is equivalent to this API WARNING:tensorflow:From /data/home/user00/python36.8/lib/python3.6/site-packages/tensorflow/python/training/learning_rate_decay_v2.py:321: div (from tensorflow.python.ops.math_ops) is deprecated and will be removed in a future version. Instructions for updating: Deprecated in favor of operator or tf.math.divide. 2019-06-25 21:44:04.525045: I tensorflow/core/platform/cpu_feature_guard.cc:141] Your CPU supports instructions that this TensorFlow binary was not compiled to use: AVX2 FMA 2019-06-25 21:44:04.530741: I tensorflow/core/platform/profile_utils/cpu_utils.cc:94] CPU Frequency: 2199860000 Hz 2019-06-25 21:44:04.531249: I tensorflow/compiler/xla/service/service.cc:150] XLA service 0x9587ca0 executing computations on platform Host. Devices: 2019-06-25 21:44:04.531282: I tensorflow/compiler/xla/service/service.cc:158] StreamExecutor device (0):