We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 958cc1d commit 9dc4d6aCopy full SHA for 9dc4d6a
KerasCNN-CIFAR/keras-cnn-cifar10.ipynb
@@ -41,17 +41,7 @@
41
"tf.random.set_seed(seed)\n",
42
"np.random.seed(seed)\n",
43
"\n",
44
- "os.environ['TF_DETERMINISTIC_OPS'] = '1'\n",
45
- "\n",
46
47
- "gpu_devices = tf.config.list_physical_devices('GPU') # get list of GPUs\n",
48
49
- "if gpu_devices: # if there are any gpu devices use first gpu\n",
50
- " tf.config.experimental.set_visible_devices(gpu_devices[0], 'GPU')\n",
51
- " tf.config.experimental.set_memory_growth(gpu_devices[0], True)\n",
52
- " os.environ['TF_USE_CUDNN'] = \"true\"\n",
53
- "else: # else use CPU\n",
54
- " os.environ[\"CUDA_VISIBLE_DEVICES\"] = \"-1\""
+ "os.environ['TF_DETERMINISTIC_OPS'] = '1'"
55
]
56
},
57
{
0 commit comments