python - tensorflow 总是向我显示这些行

标签 python tensorflow

2020-08-26 00:03:56.687961: I tensorflow/stream_executor/platform/default/dso_loader.cc:48] Successfully opened dynamic library cudart64_101.dll
2020-08-26 00:03:58.340406: I tensorflow/stream_executor/platform/default/dso_loader.cc:48] Successfully opened dynamic library nvcuda.dll
2020-08-26 00:03:58.378127: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1716] Found device 0 with properties: 
pciBusID: 0000:01:00.0 name: GeForce GTX 1650 Ti computeCapability: 7.5
coreClock: 1.485GHz coreCount: 16 deviceMemorySize: 4.00GiB deviceMemoryBandwidth: 178.84GiB/s
2020-08-26 00:03:58.378299: I tensorflow/stream_executor/platform/default/dso_loader.cc:48] Successfully opened dynamic library cudart64_101.dll
2020-08-26 00:03:58.382043: I tensorflow/stream_executor/platform/default/dso_loader.cc:48] Successfully opened dynamic library cublas64_10.dll
2020-08-26 00:03:58.385656: I tensorflow/stream_executor/platform/default/dso_loader.cc:48] Successfully opened dynamic library cufft64_10.dll
2020-08-26 00:03:58.386883: I tensorflow/stream_executor/platform/default/dso_loader.cc:48] Successfully opened dynamic library curand64_10.dll
2020-08-26 00:03:58.392017: I tensorflow/stream_executor/platform/default/dso_loader.cc:48] Successfully opened dynamic library cusolver64_10.dll
2020-08-26 00:03:58.394241: I tensorflow/stream_executor/platform/default/dso_loader.cc:48] Successfully opened dynamic library cusparse64_10.dll
2020-08-26 00:03:58.403788: I tensorflow/stream_executor/platform/default/dso_loader.cc:48] Successfully opened dynamic library cudnn64_7.dll
2020-08-26 00:03:58.404082: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1858] Adding visible gpu devices: 0
2020-08-26 00:03:58.404778: I tensorflow/core/platform/cpu_feature_guard.cc:142] This TensorFlow binary is optimized with oneAPI Deep Neural Network Library (oneDNN)to use the following CPU instructions in performance-critical operations:  AVX2
To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags.
2020-08-26 00:03:58.414602: I tensorflow/compiler/xla/service/service.cc:168] XLA service 0x18940170110 initialized for platform Host (this does not guarantee that XLA will be used). Devices:
2020-08-26 00:03:58.414776: I tensorflow/compiler/xla/service/service.cc:176]   StreamExecutor device (0): Host, Default Version
2020-08-26 00:03:58.415042: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1716] Found device 0 with properties: 
pciBusID: 0000:01:00.0 name: GeForce GTX 1650 Ti computeCapability: 7.5
coreClock: 1.485GHz coreCount: 16 deviceMemorySize: 4.00GiB deviceMemoryBandwidth: 178.84GiB/s
2020-08-26 00:03:58.415268: I tensorflow/stream_executor/platform/default/dso_loader.cc:48] Successfully opened dynamic library cudart64_101.dll
2020-08-26 00:03:58.415381: I tensorflow/stream_executor/platform/default/dso_loader.cc:48] Successfully opened dynamic library cublas64_10.dll
2020-08-26 00:03:58.415477: I tensorflow/stream_executor/platform/default/dso_loader.cc:48] Successfully opened dynamic library cufft64_10.dll
2020-08-26 00:03:58.415588: I tensorflow/stream_executor/platform/default/dso_loader.cc:48] Successfully opened dynamic library curand64_10.dll
2020-08-26 00:03:58.415696: I tensorflow/stream_executor/platform/default/dso_loader.cc:48] Successfully opened dynamic library cusolver64_10.dll
2020-08-26 00:03:58.415800: I tensorflow/stream_executor/platform/default/dso_loader.cc:48] Successfully opened dynamic library cusparse64_10.dll
2020-08-26 00:03:58.415949: I tensorflow/stream_executor/platform/default/dso_loader.cc:48] Successfully opened dynamic library cudnn64_7.dll
2020-08-26 00:03:58.416126: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1858] Adding visible gpu devices: 0
2020-08-26 00:03:59.149169: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1257] Device interconnect StreamExecutor with strength 1 edge matrix:
2020-08-26 00:03:59.149272: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1263]      0 
2020-08-26 00:03:59.149331: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1276] 0:   N 
2020-08-26 00:03:59.149561: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1402] Created TensorFlow device (/job:localhost/replica:0/task:0/device:GPU:0 with 2905 MB memory) -> physical GPU (device: 0, name: GeForce GTX 1650 Ti, pci bus id: 0000:01:00.0, compute capability: 7.5)

在Python中运行tensorflow程序时,我已经安装了所有正确的东西.......它首先向我显示这个然后是输出。它不是警告或错误
请有人帮我解决它......

最佳答案

在文件顶部写入以下两行。

import os
os.environ['TF_CPP_MIN_LOG_LEVEL'] = '3'
import tensorflow as tf

使用上面的代码禁用所有日志记录。 这是三个级别

0 = all messages are logged (default behavior)
1 = INFO messages are not logged
2 = INFO, WARNING messages are not logged
3 = INFO, WARNING, and ERROR messages are not logged

您可以选择所需的日志记录级别。

关于python - tensorflow 总是向我显示这些行,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/63585403/

相关文章:

python - 如何根据一列的先前值和另一列的当前值计算列

python - 如何使用 python 和 bs4 修复抓取 web 表输出 csv

python - peewee 的 get 方法如何知道如何生成 where 子句?

tensorflow - Keras 自定义损失函数打印张量值

python - GPyOpt - 如何进行物理实验?

python - 获取当前的 python 模块对象(按名称或其他方式)

tensorflow - 以 double 运行 Keras 失败

tensorflow - 使用 Sigmoid 激活函数代替线性激活与在损失中使用 sigmoid 的区别

tensorflow - 二元和多类分类代码更改

tensorflow - 如何使用 tensorflow 旋转 3D 图像?