Problems about tensorflow and GPU operation

CSDN Q & A 2022-05-15 04:50:28 阅读数:185

problemstensorflowgpuoperation

Does anyone know why , I'll replace it with CPU Running is running , But by default GPU It doesn't seem to work , Why?

2022-05-04 15:55:27.171897: 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: AVX AVX2
To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags.
2022-05-04 15:55:27.667586: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1510] Created device /job:localhost/replica:0/task:0/device:GPU:0 with 2149 MB memory: -> device: 0, name: NVIDIA GeForce GTX 1650, pci bus id: 0000:01:00.0, compute capability: 7.5
WARNING:tensorflow:From D:/python_project/ neural network /cat_dog_trian.py:56: start_queue_runners (from tensorflow.python.training.queue_runner_impl) is deprecated and will be removed in a future version.
Instructions for updating:
To construct input pipelines, use the tf.data module.
2022-05-04 15:55:31.327242: I tensorflow/stream_executor/cuda/cuda_dnn.cc:369] Loaded cuDNN version 8303
Process finished with exit code -1073740791 (0xC0000409)




Take the answer :

Add... To the file

import osos.environ['CUDA_VISIBLE_DEVICES'] = '1'

Are you like this ?


版权声明:本文为[CSDN Q & A]所创,转载请带上原文链接,感谢。 https://primo.wiki/2022/131/202205041624475684.html