当前位置:网站首页>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)
边栏推荐
- 随时随地查看远程试验数据与记录——IPEhub2与IPEmotion APP
- 用tkinter做一个简单图形界面
- Dell Notebook Periodic Flash Screen Fault
- Data sharing of the 835 postgraduate entrance examination of software engineering in Hainan University in 23
- What kind of experience is it to realize real-time collaboration in jupyter
- Cause of handler memory leak
- 什么是时间
- Learning notes 5: ram and ROM
- Advanced learning of MySQL -- basics -- multi table query -- external connection
- Return to blowing marshland -- travel notes of zhailidong, founder of duanzhitang
猜你喜欢
Dell Notebook Periodic Flash Screen Fault
学习光线跟踪一样的自3D表征Ego3RT
Zynq transplant ucosiii
pyflink的安装和测试
详解OpenCV的矩阵规范化函数normalize()【范围化矩阵的范数或值范围(归一化处理)】,并附NORM_MINMAX情况下的示例代码
Deeply explore the compilation and pile insertion technology (IV. ASM exploration)
重上吹麻滩——段芝堂创始人翟立冬游记
做微服务研发工程师的一年来的总结
Data sharing of the 835 postgraduate entrance examination of software engineering in Hainan University in 23
Learn to use code to generate beautiful interface documents!!!
随机推荐
[Niuke classic question 01] bit operation
Data sharing of the 835 postgraduate entrance examination of software engineering in Hainan University in 23
Make a simple graphical interface with Tkinter
How do novices get started and learn PostgreSQL?
《安富莱嵌入式周报》第272期:2022.06.27--2022.07.03
【软件逆向-求解flag】内存获取、逆变换操作、线性变换、约束求解
Part 7: STM32 serial communication programming
【批處理DOS-CMD命令-匯總和小結】-字符串搜索、查找、篩選命令(find、findstr),Find和findstr的區別和辨析
Part VI, STM32 pulse width modulation (PWM) programming
Linear algebra of deep learning
5种不同的代码相似性检测,以及代码相似性检测的发展趋势
Advanced learning of MySQL -- basics -- basic operation of transactions
Data processing of deep learning
Link sharing of STM32 development materials
学习使用代码生成美观的接口文档!!!
代码克隆的优缺点
Advanced learning of MySQL -- basics -- multi table query -- joint query
[user defined type] structure, union, enumeration
做微服务研发工程师的一年来的总结
Slam d'attention: un slam visuel monoculaire appris de l'attention humaine