解决:Not creating XLA devices, tf_xla_enable_xla_devices not set
解决:Not creating XLA devices, tf_xla_enable_xla_devices not set
- 实验环境
- 提示如下
- 分析原因
- 解决方法
实验环境
- Windows 10
- NVIDIA GeForce GTX 1050
- CUDA11.0
- CUDNN 8.0
- Tesorflow-gpu 2.4.1
提示如下
分析原因
据说是Tesorflow-gpu 2.4.1,默认情况下,不再注册XLA:CPU和XLA:GPU设备。如果确实需要它们,请可使用
os.environ['TF_XLA_FLAGS'] = '--tf_xla_enable_xla_devices'
但是此标志最终将在后续发行版中删除。
解决方法
将
import tensorflow as tf
import os
os.environ['TF_CPP_MIN_LOG_LEVEL']='2'print(tf.__version__)
a = tf.constant(1.)
b = tf.constant(2.)
print(a+b)
print('GPU:', tf.test.is_gpu_available())
改为
import tensorflow as tf
import os
os.environ['TF_XLA_FLAGS'] = '--tf_xla_enable_xla_devices'
os.environ['TF_CPP_MIN_LOG_LEVEL']='2'
print(tf.__version__)
a = tf.constant(1.)
b = tf.constant(2.)
print(a+b)
print('GPU:', tf.test.is_gpu_available())
即可!
你将会发现,在代码开头加了
os.environ['TF_XLA_FLAGS'] = '--tf_xla_enable_xla_devices'
将不会有
Not creating XLA devices, tf_xla_enable_xla_devices not set
提示!
解决:Not creating XLA devices, tf_xla_enable_xla_devices not set相关推荐
- Ubuntu18解决:Not creating XLA devices, tf_xla_enable_xla_devices not set
实验环境 ubuntu18 NVIDIA GeForce GTX 1050 CUDA11.0 CUDNN 8.0 Tesorflow-gpu 2.4.1 问题 分析原因 据说是Tesorflow-gp ...
- win10系统tensorflow2.4.0-gpu安装“Not creating XLA devices, tf_xla_enable_xla_devices not set”解决方法
未解决前报错 最近在安装tensorflow2.4.0-gpu版本后的项目开发过程中出现了"Not creating XLA devices, tf_xla_enable_xla_dev ...
- 【Error】解决:Not creating XLA devices, tf_xla_enable_xla_devices not set
提示如下 分析原因 据说是Tesorflow-gpu 2.4.1,默认情况下,不再注册XLA:CPU和XLA:GPU设备.如果确实需要它们,请可使用 os.environ['TF_XLA_FLAGS' ...
- 彻底解决conda环境下 tensorflow gpu版本出现的问题:Not creating XLA devices, tf_xla_enable_xla_devices not set
问题说明 tf.test.is_gpu_available()结果为TRUE,但有Not creating XLA devices, tf_xla_enable_xla_devices not set ...
- tensorflow:Not creating XLA devices, tf_xla_enable_xla_devices not set
运行代码出现 I tensorflow/compiler/jit/xla_cpu_device.cc:41] Not creating XLA devices, tf_xla_enable_xla_d ...
- Linux conda tensorflow-gpu安装及Not creating XLA devices, tf_xla_enable_xla_devices not set相关问题解决
0.首先介绍一下conda创建虚拟环境的基本操作. (1)创建Python的虚拟环境,并指定Python版本,不指定的话会使用默认的版本(Conda Base 环境中的Python版本). conda ...
- 安装Tensorflow 报错false Not creating XLA devices, tf_xla_enable_xla_devices not set
学习图像识别配置环境 https://blog.csdn.net/weixin_44170512/article/details/103990592 一步一步按照博主配置 执行到这两句 import ...
- Not creating XLA devices, tf_xla_enable_xla_devices not set错误求助
在pycharm中跑代码出现 在调试的时候出现了Not creating XLA devices, tf_xla_enable_xla_devices not set,但是测试的时候却是显示true ...
- CUDA安装 + tensorflow gpu版本出现的问题:Not creating XLA devices, tf_xla_enable_xla_devices not set
装完后用以下两行代码测试,结果竟然是False,输出了图片中的报错,肯定是哪装的有问题 import tensorflow as tf tf.test.is_gpu_available() 我的ten ...
最新文章
- HDLBits 系列(29)PS/2 mouse protocol(PS/2 packet parser and datapath)
- 软件工程师技术面试一面真题
- sift计算描述子代码详解_代码详解——如何计算横向误差?
- mybaits三:全局配置文件
- Mathematica 对曲线进行拟合
- promise在promise情况下进行使用async与await
- [CF475E]Strongly Connected City 2
- 机器人出魔切还是三相_魔切冷却流机器人,暗夜收割者一招致命!
- Coolite Toolkit学习笔记一:AjaxEvent、AjaxMethod和Listeners
- android共享元素动画_Android共享元素过渡动画
- 双麦阵列回音消除及降噪模块 A-47
- 4D 语义分割——TemporalLidarSeg
- chrome浏览器扩展打包成crx
- 计算机图片颜色是红色怎么办,电脑变色是怎么回事?(有图片)
- 如何UNI-APP中使用iconfont彩色图标
- 论文翻译:混合维在庞加莱几何三维骨架的动作识别
- 怎样解锁CAD图纸中被锁定的图层?
- opencv图像对齐与图像相减python
- 旅游攻略小程序毕业设计毕设作品开题报告答辩PPT
- kotlin教程4:函数进阶