studio-lab-examples
studio-lab-examples copied to clipboard
tensorflow is not built with CUDA
Describe the bug
Even with GPU instance, tensorflow ( from sagemaker-distribution conda environment ) can't recognize the GPU.
nvidia-smi show I'm using GPU instance, and pytorch can recognize the GPU.
To Reproduce Steps to reproduce the behavior:
- Start GPU runtime.
- launch jupyter notebook ( with sagemaker-distribution kernel )
- type
import tensorflow as tf
import torch
tf.config.list_physical_devices('GPU') # []
tf.test.is_built_with_cuda() # False
torch.cuda.is_available() # True
- See error TensorFlow can't recognize GPU, and is not even built with CUDA.
Expected behavior
tf.config.list_physical_devices('GPU') # at least one GPU should be in the list
tf.test.is_built_with_cuda() # True
Screenshots
If applicable, add screenshots to help explain your problem.
Desktop (please complete the following information):
- OS: windows 11
- Browser : chrome
- Version : 126.0.6478.127 (Official Build) (64-bit)