was getting started with tensor flow. I dont have any external gpu expect the built in intel 5000. so when I ran this I got 0 . Should that be the desired output? Should I not get 1? If that's the case, should I limit CPU space to ensure it doesn't take much of memory? In that case what should be the approach?
gpus = tf.config.experimental.list_physical_devices('GPU')
len(gpus)
The output is 0
for more context, when I tried the following code the output was []
gpus = tf.config.experimental.list_physical_devices('GPU')
for gpu in gpus:
tf.config.experimental.set_memory_growth(gpu, True)
tf.config.list_physical_devices('GPU')
Output:
[]
So here is my code:
!pip install tensorflow tensorflow-gpu opencv-python matplotlib
!pip list
import cv2
import numpy as np
import tensorflow as tf
import os
gpus = tf.config.experimental.list_physical_devices('GPU')
for gpu in gpus:
tf.config.experimental.set_memory_growth(gpu, True)
tf.config.list_physical_devices('GPU')
So, incase this is correct how do I Limit CPU memory, and is that necessary