how to check if system has gpu in tensorflow code example Example: tensorflow check gpu tf.config.list_physical_devices('GPU')