TensorFlow 2 preview is now has tf.__version__ >= "2.0"

main
Aurélien Geron 2019-02-12 20:32:58 +08:00
parent bc01f44075
commit 8d6a55f32c
2 changed files with 1 additions and 1 deletions

View File

@ -39,7 +39,7 @@
"\n", "\n",
"# TensorFlow ≥2.0-preview is required\n", "# TensorFlow ≥2.0-preview is required\n",
"import tensorflow as tf\n", "import tensorflow as tf\n",
"assert hasattr(tf.compat, \"v1\")\n", "assert tf.__version__ >= \"2.0\"\n",
"\n", "\n",
"# Common imports\n", "# Common imports\n",
"import numpy as np\n", "import numpy as np\n",