Unverified Commit 02d40e9f authored by Mark Daoust's avatar Mark Daoust Committed by GitHub
Browse files

Merge pull request #3843 from akshayka/gpu_fix

Fix eager demo's GPU cell
parents a0e3604f 7bfa87ea
...@@ -282,9 +282,10 @@ ...@@ -282,9 +282,10 @@
}, },
"cell_type": "code", "cell_type": "code",
"source": [ "source": [
"if tf.test.is_gpu_available() > 0:\n", "if tf.test.is_gpu_available():\n",
" with tf.device(tf.test.gpu_device_name()):\n", " with tf.device(tf.test.gpu_device_name()):\n",
" print(tf.matmul(A, A))" " B = tf.constant([[2.0, 0.0], [0.0, 3.0]])\n",
" print(tf.matmul(B, B))"
], ],
"execution_count": 0, "execution_count": 0,
"outputs": [] "outputs": []
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment