||
# -*- coding: utf-8 -*-
import tensorflow as tf
hello = tf.constant('Hello, tensorflow')
sess = tf.Session()
# 打印当前tf的版本号
print("###########version###########", tf.__version__)
# 返回True,说明是可用的
print("++++++++++is_gpu_available+++++++++++", tf.test.is_gpu_available())
# 结果如下图
Archiver|手机版|科学网 ( 京ICP备07017567号-12 )
GMT+8, 2025-1-5 13:15
Powered by ScienceNet.cn
Copyright © 2007- 中国科学报社