当前位置:网站首页>Tensorflow 1.14 specify GPU running settings
Tensorflow 1.14 specify GPU running settings
2022-07-07 01:00:00 【The mountain of ignorance, the valley of despair, the slope of 】
Be careful :allow_soft_placement=True indicate : Computing devices are optional , If you don't have this parameter , Will report a mistake .
Because not all operations can be placed in GPU On , If forced will not be able to put in GPU The operation on is assigned to GPU On , Will be an error .
os.environ["CUDA_DEVICE_ORDER"] = "PCI_BUS_ID"
os.environ["CUDA_VISIBLE_DEVICES"] = "0" # Here is gpu The serial number of , Designated to use gpu object
gpu_options = tf.GPUOptions()
gpu_options.allow_growth = True
config_photo = tf.ConfigProto(allow_soft_placement=True, gpu_options=gpu_options, log_device_placement=True)
self.sess = tf.Session(config=config_photo)
边栏推荐
- Meet the level 3 requirements of ISO 2.0 with the level B construction standard of computer room | hybrid cloud infrastructure
- 「精致店主理人」青年创业孵化营·首期顺德场圆满结束!
- Stm32f407 ------- SPI communication
- Rainstorm effect in levels - ue5
- 省市区三级坐标边界数据csv转JSON
- Batch obtain the latitude coordinates of all administrative regions in China (to the county level)
- 用tkinter做一个简单图形界面
- tensorflow 1.14指定gpu运行设置
- [batch dos-cmd command - summary and summary] - string search, search, and filter commands (find, findstr), and the difference and discrimination between find and findstr
- 新手如何入门学习PostgreSQL?
猜你喜欢
随机推荐
from .cv2 import * ImportError: libGL.so.1: cannot open shared object file: No such file or direc
第六篇,STM32脉冲宽度调制(PWM)编程
Part IV: STM32 interrupt control programming
Web project com mysql. cj. jdbc. Driver and com mysql. jdbc. Driver differences
C9高校,博士生一作发Nature!
用tkinter做一个简单图形界面
Zynq transplant ucosiii
Data processing of deep learning
Installation and testing of pyflink
「精致店主理人」青年创业孵化营·首期顺德场圆满结束!
Chenglian premium products has completed the first step to enter the international capital market by taking shares in halber international
[software reverse automation] complete collection of reverse tools
What is time
ActiveReportsJS 3.1中文版|||ActiveReportsJS 3.1英文版
Advanced learning of MySQL -- basics -- multi table query -- subquery
建立自己的网站(17)
详解OpenCV的矩阵规范化函数normalize()【范围化矩阵的范数或值范围(归一化处理)】,并附NORM_MINMAX情况下的示例代码
【JVM调优实战100例】04——方法区调优实战(上)
pyflink的安装和测试
以机房B级建设标准满足等保2.0三级要求 | 混合云基础设施