亚洲一区精品自拍_2021年国内精品久久_男同十八禁gv在线观看_免费观看a级性爱黄片

Article / 文章中心

深度學(xué)習(xí):Mac下Tensorflow安裝及報錯解決

發(fā)布時間:2021-11-24 點擊數(shù):940

深度學(xué)習(xí)tensorflow

使用:

  • 圖像識別
  • 自然語言處理
  • 情感分析
人工智能  - 機器學(xué)習(xí)  - 深度學(xué)習(xí)  機器學(xué)習(xí):  -神經(jīng)網(wǎng)絡(luò)(簡單)  -回歸  深度學(xué)習(xí):  -神經(jīng)網(wǎng)絡(luò)(深度)  -圖像:卷積神經(jīng)網(wǎng)絡(luò)  -自然語言處理:循環(huán)神經(jīng)網(wǎng)絡(luò)

CPU/GPU/TPU

安裝:

CPU版本

pip install tensorflow

GPU版本

pip install tensorflow-gpu

運行報錯:

ImportError: dlopen(/.virtualenvs/py3/lib/python3.6/ site-packages/tensorflow/python/_pywrap_tensorflow_internal.so, 6): Symbol not found: _clock_gettime

解決:

查看版本

python3.6

tensorflow-1.12.0

mac OS 10.11.6

macOS<10.12的需要卸載后安裝1.5版本

pip install tensorflow==1.5

參考

https://github.com/tensorflow/tensorflow/issues/24642

運行警告

1.采用源碼安裝

2.設(shè)置日志級別

# 取消警告 import os os.environ["TF_CPP_MIN_LOG_LEVEL"] = "2" 

tensorflow實現(xiàn)加法運算

 import tensorflow as tf  # 取消警告 import os os.environ["TF_CPP_MIN_LOG_LEVEL"] = "2"  a = tf.constant(5.0) b = tf.constant(6.0)  value = tf.add(a, b)  with tf.Session() as session:  print(session.run(value)) # 11.0