Support running on Kaggle
parent
cbe47c65d5
commit
c3020f1da5
|
@ -44,6 +44,10 @@
|
||||||
"import sys\n",
|
"import sys\n",
|
||||||
"assert sys.version_info >= (3, 5)\n",
|
"assert sys.version_info >= (3, 5)\n",
|
||||||
"\n",
|
"\n",
|
||||||
|
"# Is this notebook running on Colab or Kaggle?\n",
|
||||||
|
"IS_COLAB = \"google.colab\" in sys.modules\n",
|
||||||
|
"IS_KAGGLE = \"kaggle_secrets\" in sys.modules\n",
|
||||||
|
"\n",
|
||||||
"# Scikit-Learn ≥0.20 is required\n",
|
"# Scikit-Learn ≥0.20 is required\n",
|
||||||
"import sklearn\n",
|
"import sklearn\n",
|
||||||
"assert sklearn.__version__ >= \"0.20\"\n",
|
"assert sklearn.__version__ >= \"0.20\"\n",
|
||||||
|
@ -2330,12 +2334,9 @@
|
||||||
"metadata": {},
|
"metadata": {},
|
||||||
"outputs": [],
|
"outputs": [],
|
||||||
"source": [
|
"source": [
|
||||||
"# if running this notebook on Colab, we just pip install urlextract\n",
|
"# if running this notebook on Colab or Kaggle, we just pip install urlextract\n",
|
||||||
"try:\n",
|
"if IS_COLAB or IS_KAGGLE:\n",
|
||||||
" import google.colab\n",
|
" !pip install -q -U urlextract"
|
||||||
" !pip install -q -U urlextract\n",
|
|
||||||
"except ImportError:\n",
|
|
||||||
" pass # not running on Colab"
|
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -2601,7 +2602,7 @@
|
||||||
"name": "python",
|
"name": "python",
|
||||||
"nbconvert_exporter": "python",
|
"nbconvert_exporter": "python",
|
||||||
"pygments_lexer": "ipython3",
|
"pygments_lexer": "ipython3",
|
||||||
"version": "3.7.9"
|
"version": "3.7.10"
|
||||||
},
|
},
|
||||||
"nav_menu": {},
|
"nav_menu": {},
|
||||||
"toc": {
|
"toc": {
|
||||||
|
|
|
@ -44,18 +44,18 @@
|
||||||
"import sys\n",
|
"import sys\n",
|
||||||
"assert sys.version_info >= (3, 5)\n",
|
"assert sys.version_info >= (3, 5)\n",
|
||||||
"\n",
|
"\n",
|
||||||
|
"# Is this notebook running on Colab or Kaggle?\n",
|
||||||
|
"IS_COLAB = \"google.colab\" in sys.modules\n",
|
||||||
|
"IS_KAGGLE = \"kaggle_secrets\" in sys.modules\n",
|
||||||
|
"\n",
|
||||||
|
"if IS_COLAB or IS_KAGGLE:\n",
|
||||||
|
" !pip install -q -U tfx==0.21.2\n",
|
||||||
|
" print(\"You can safely ignore the package incompatibility errors.\")\n",
|
||||||
|
"\n",
|
||||||
"# Scikit-Learn ≥0.20 is required\n",
|
"# Scikit-Learn ≥0.20 is required\n",
|
||||||
"import sklearn\n",
|
"import sklearn\n",
|
||||||
"assert sklearn.__version__ >= \"0.20\"\n",
|
"assert sklearn.__version__ >= \"0.20\"\n",
|
||||||
"\n",
|
"\n",
|
||||||
"try:\n",
|
|
||||||
" # %tensorflow_version only exists in Colab.\n",
|
|
||||||
" %tensorflow_version 2.x\n",
|
|
||||||
" !pip install -q -U tfx==0.21.2\n",
|
|
||||||
" print(\"You can safely ignore the package incompatibility errors.\")\n",
|
|
||||||
"except Exception:\n",
|
|
||||||
" pass\n",
|
|
||||||
"\n",
|
|
||||||
"# TensorFlow ≥2.0 is required\n",
|
"# TensorFlow ≥2.0 is required\n",
|
||||||
"import tensorflow as tf\n",
|
"import tensorflow as tf\n",
|
||||||
"from tensorflow import keras\n",
|
"from tensorflow import keras\n",
|
||||||
|
@ -2766,7 +2766,7 @@
|
||||||
"name": "python",
|
"name": "python",
|
||||||
"nbconvert_exporter": "python",
|
"nbconvert_exporter": "python",
|
||||||
"pygments_lexer": "ipython3",
|
"pygments_lexer": "ipython3",
|
||||||
"version": "3.7.9"
|
"version": "3.7.10"
|
||||||
},
|
},
|
||||||
"nav_menu": {
|
"nav_menu": {
|
||||||
"height": "264px",
|
"height": "264px",
|
||||||
|
|
|
@ -49,17 +49,14 @@
|
||||||
"import sys\n",
|
"import sys\n",
|
||||||
"assert sys.version_info >= (3, 5)\n",
|
"assert sys.version_info >= (3, 5)\n",
|
||||||
"\n",
|
"\n",
|
||||||
|
"# Is this notebook running on Colab or Kaggle?\n",
|
||||||
|
"IS_COLAB = \"google.colab\" in sys.modules\n",
|
||||||
|
"IS_KAGGLE = \"kaggle_secrets\" in sys.modules\n",
|
||||||
|
"\n",
|
||||||
"# Scikit-Learn ≥0.20 is required\n",
|
"# Scikit-Learn ≥0.20 is required\n",
|
||||||
"import sklearn\n",
|
"import sklearn\n",
|
||||||
"assert sklearn.__version__ >= \"0.20\"\n",
|
"assert sklearn.__version__ >= \"0.20\"\n",
|
||||||
"\n",
|
"\n",
|
||||||
"try:\n",
|
|
||||||
" # %tensorflow_version only exists in Colab.\n",
|
|
||||||
" %tensorflow_version 2.x\n",
|
|
||||||
" IS_COLAB = True\n",
|
|
||||||
"except Exception:\n",
|
|
||||||
" IS_COLAB = False\n",
|
|
||||||
"\n",
|
|
||||||
"# TensorFlow ≥2.0 is required\n",
|
"# TensorFlow ≥2.0 is required\n",
|
||||||
"import tensorflow as tf\n",
|
"import tensorflow as tf\n",
|
||||||
"from tensorflow import keras\n",
|
"from tensorflow import keras\n",
|
||||||
|
@ -69,6 +66,8 @@
|
||||||
" print(\"No GPU was detected. CNNs can be very slow without a GPU.\")\n",
|
" print(\"No GPU was detected. CNNs can be very slow without a GPU.\")\n",
|
||||||
" if IS_COLAB:\n",
|
" if IS_COLAB:\n",
|
||||||
" print(\"Go to Runtime > Change runtime and select a GPU hardware accelerator.\")\n",
|
" print(\"Go to Runtime > Change runtime and select a GPU hardware accelerator.\")\n",
|
||||||
|
" if IS_KAGGLE:\n",
|
||||||
|
" print(\"Go to Settings > Accelerator and select GPU.\")\n",
|
||||||
"\n",
|
"\n",
|
||||||
"# Common imports\n",
|
"# Common imports\n",
|
||||||
"import numpy as np\n",
|
"import numpy as np\n",
|
||||||
|
@ -1366,7 +1365,7 @@
|
||||||
"name": "python",
|
"name": "python",
|
||||||
"nbconvert_exporter": "python",
|
"nbconvert_exporter": "python",
|
||||||
"pygments_lexer": "ipython3",
|
"pygments_lexer": "ipython3",
|
||||||
"version": "3.7.9"
|
"version": "3.7.10"
|
||||||
},
|
},
|
||||||
"nav_menu": {},
|
"nav_menu": {},
|
||||||
"toc": {
|
"toc": {
|
||||||
|
|
|
@ -49,17 +49,14 @@
|
||||||
"import sys\n",
|
"import sys\n",
|
||||||
"assert sys.version_info >= (3, 5)\n",
|
"assert sys.version_info >= (3, 5)\n",
|
||||||
"\n",
|
"\n",
|
||||||
|
"# Is this notebook running on Colab or Kaggle?\n",
|
||||||
|
"IS_COLAB = \"google.colab\" in sys.modules\n",
|
||||||
|
"IS_KAGGLE = \"kaggle_secrets\" in sys.modules\n",
|
||||||
|
"\n",
|
||||||
"# Scikit-Learn ≥0.20 is required\n",
|
"# Scikit-Learn ≥0.20 is required\n",
|
||||||
"import sklearn\n",
|
"import sklearn\n",
|
||||||
"assert sklearn.__version__ >= \"0.20\"\n",
|
"assert sklearn.__version__ >= \"0.20\"\n",
|
||||||
"\n",
|
"\n",
|
||||||
"try:\n",
|
|
||||||
" # %tensorflow_version only exists in Colab.\n",
|
|
||||||
" %tensorflow_version 2.x\n",
|
|
||||||
" IS_COLAB = True\n",
|
|
||||||
"except Exception:\n",
|
|
||||||
" IS_COLAB = False\n",
|
|
||||||
"\n",
|
|
||||||
"# TensorFlow ≥2.0 is required\n",
|
"# TensorFlow ≥2.0 is required\n",
|
||||||
"import tensorflow as tf\n",
|
"import tensorflow as tf\n",
|
||||||
"from tensorflow import keras\n",
|
"from tensorflow import keras\n",
|
||||||
|
@ -69,6 +66,8 @@
|
||||||
" print(\"No GPU was detected. LSTMs and CNNs can be very slow without a GPU.\")\n",
|
" print(\"No GPU was detected. LSTMs and CNNs can be very slow without a GPU.\")\n",
|
||||||
" if IS_COLAB:\n",
|
" if IS_COLAB:\n",
|
||||||
" print(\"Go to Runtime > Change runtime and select a GPU hardware accelerator.\")\n",
|
" print(\"Go to Runtime > Change runtime and select a GPU hardware accelerator.\")\n",
|
||||||
|
" if IS_KAGGLE:\n",
|
||||||
|
" print(\"Go to Settings > Accelerator and select GPU.\")\n",
|
||||||
"\n",
|
"\n",
|
||||||
"# Common imports\n",
|
"# Common imports\n",
|
||||||
"import numpy as np\n",
|
"import numpy as np\n",
|
||||||
|
@ -2018,7 +2017,7 @@
|
||||||
"name": "python",
|
"name": "python",
|
||||||
"nbconvert_exporter": "python",
|
"nbconvert_exporter": "python",
|
||||||
"pygments_lexer": "ipython3",
|
"pygments_lexer": "ipython3",
|
||||||
"version": "3.7.9"
|
"version": "3.7.10"
|
||||||
},
|
},
|
||||||
"nav_menu": {},
|
"nav_menu": {},
|
||||||
"toc": {
|
"toc": {
|
||||||
|
|
|
@ -49,19 +49,18 @@
|
||||||
"import sys\n",
|
"import sys\n",
|
||||||
"assert sys.version_info >= (3, 5)\n",
|
"assert sys.version_info >= (3, 5)\n",
|
||||||
"\n",
|
"\n",
|
||||||
|
"# Is this notebook running on Colab or Kaggle?\n",
|
||||||
|
"IS_COLAB = \"google.colab\" in sys.modules\n",
|
||||||
|
"IS_KAGGLE = \"kaggle_secrets\" in sys.modules\n",
|
||||||
|
"\n",
|
||||||
|
"if IS_COLAB:\n",
|
||||||
|
" !pip install -q -U tensorflow-addons\n",
|
||||||
|
" !pip install -q -U transformers\n",
|
||||||
|
"\n",
|
||||||
"# Scikit-Learn ≥0.20 is required\n",
|
"# Scikit-Learn ≥0.20 is required\n",
|
||||||
"import sklearn\n",
|
"import sklearn\n",
|
||||||
"assert sklearn.__version__ >= \"0.20\"\n",
|
"assert sklearn.__version__ >= \"0.20\"\n",
|
||||||
"\n",
|
"\n",
|
||||||
"try:\n",
|
|
||||||
" # %tensorflow_version only exists in Colab.\n",
|
|
||||||
" %tensorflow_version 2.x\n",
|
|
||||||
" !pip install -q -U tensorflow-addons\n",
|
|
||||||
" !pip install -q -U transformers\n",
|
|
||||||
" IS_COLAB = True\n",
|
|
||||||
"except Exception:\n",
|
|
||||||
" IS_COLAB = False\n",
|
|
||||||
"\n",
|
|
||||||
"# TensorFlow ≥2.0 is required\n",
|
"# TensorFlow ≥2.0 is required\n",
|
||||||
"import tensorflow as tf\n",
|
"import tensorflow as tf\n",
|
||||||
"from tensorflow import keras\n",
|
"from tensorflow import keras\n",
|
||||||
|
@ -71,6 +70,8 @@
|
||||||
" print(\"No GPU was detected. LSTMs and CNNs can be very slow without a GPU.\")\n",
|
" print(\"No GPU was detected. LSTMs and CNNs can be very slow without a GPU.\")\n",
|
||||||
" if IS_COLAB:\n",
|
" if IS_COLAB:\n",
|
||||||
" print(\"Go to Runtime > Change runtime and select a GPU hardware accelerator.\")\n",
|
" print(\"Go to Runtime > Change runtime and select a GPU hardware accelerator.\")\n",
|
||||||
|
" if IS_KAGGLE:\n",
|
||||||
|
" print(\"Go to Settings > Accelerator and select GPU.\")\n",
|
||||||
"\n",
|
"\n",
|
||||||
"# Common imports\n",
|
"# Common imports\n",
|
||||||
"import numpy as np\n",
|
"import numpy as np\n",
|
||||||
|
@ -2748,7 +2749,7 @@
|
||||||
"name": "python",
|
"name": "python",
|
||||||
"nbconvert_exporter": "python",
|
"nbconvert_exporter": "python",
|
||||||
"pygments_lexer": "ipython3",
|
"pygments_lexer": "ipython3",
|
||||||
"version": "3.7.9"
|
"version": "3.7.10"
|
||||||
},
|
},
|
||||||
"nav_menu": {},
|
"nav_menu": {},
|
||||||
"toc": {
|
"toc": {
|
||||||
|
|
|
@ -49,17 +49,14 @@
|
||||||
"import sys\n",
|
"import sys\n",
|
||||||
"assert sys.version_info >= (3, 5)\n",
|
"assert sys.version_info >= (3, 5)\n",
|
||||||
"\n",
|
"\n",
|
||||||
|
"# Is this notebook running on Colab or Kaggle?\n",
|
||||||
|
"IS_COLAB = \"google.colab\" in sys.modules\n",
|
||||||
|
"IS_KAGGLE = \"kaggle_secrets\" in sys.modules\n",
|
||||||
|
"\n",
|
||||||
"# Scikit-Learn ≥0.20 is required\n",
|
"# Scikit-Learn ≥0.20 is required\n",
|
||||||
"import sklearn\n",
|
"import sklearn\n",
|
||||||
"assert sklearn.__version__ >= \"0.20\"\n",
|
"assert sklearn.__version__ >= \"0.20\"\n",
|
||||||
"\n",
|
"\n",
|
||||||
"try:\n",
|
|
||||||
" # %tensorflow_version only exists in Colab.\n",
|
|
||||||
" %tensorflow_version 2.x\n",
|
|
||||||
" IS_COLAB = True\n",
|
|
||||||
"except Exception:\n",
|
|
||||||
" IS_COLAB = False\n",
|
|
||||||
"\n",
|
|
||||||
"# TensorFlow ≥2.0 is required\n",
|
"# TensorFlow ≥2.0 is required\n",
|
||||||
"import tensorflow as tf\n",
|
"import tensorflow as tf\n",
|
||||||
"from tensorflow import keras\n",
|
"from tensorflow import keras\n",
|
||||||
|
@ -69,6 +66,8 @@
|
||||||
" print(\"No GPU was detected. LSTMs and CNNs can be very slow without a GPU.\")\n",
|
" print(\"No GPU was detected. LSTMs and CNNs can be very slow without a GPU.\")\n",
|
||||||
" if IS_COLAB:\n",
|
" if IS_COLAB:\n",
|
||||||
" print(\"Go to Runtime > Change runtime and select a GPU hardware accelerator.\")\n",
|
" print(\"Go to Runtime > Change runtime and select a GPU hardware accelerator.\")\n",
|
||||||
|
" if IS_KAGGLE:\n",
|
||||||
|
" print(\"Go to Settings > Accelerator and select GPU.\")\n",
|
||||||
"\n",
|
"\n",
|
||||||
"# Common imports\n",
|
"# Common imports\n",
|
||||||
"import numpy as np\n",
|
"import numpy as np\n",
|
||||||
|
@ -1773,7 +1772,7 @@
|
||||||
"name": "python",
|
"name": "python",
|
||||||
"nbconvert_exporter": "python",
|
"nbconvert_exporter": "python",
|
||||||
"pygments_lexer": "ipython3",
|
"pygments_lexer": "ipython3",
|
||||||
"version": "3.7.9"
|
"version": "3.7.10"
|
||||||
},
|
},
|
||||||
"nav_menu": {
|
"nav_menu": {
|
||||||
"height": "381px",
|
"height": "381px",
|
||||||
|
|
|
@ -29,13 +29,7 @@
|
||||||
"cell_type": "markdown",
|
"cell_type": "markdown",
|
||||||
"metadata": {},
|
"metadata": {},
|
||||||
"source": [
|
"source": [
|
||||||
"# Setup"
|
"# Setup\n",
|
||||||
]
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"cell_type": "markdown",
|
|
||||||
"metadata": {},
|
|
||||||
"source": [
|
|
||||||
"First, let's import a few common modules, ensure MatplotLib plots figures inline and prepare a function to save the figures. We also check that Python 3.5 or later is installed (although Python 2.x may work, it is deprecated so we strongly recommend you use Python 3 instead), as well as Scikit-Learn ≥0.20 and TensorFlow ≥2.0."
|
"First, let's import a few common modules, ensure MatplotLib plots figures inline and prepare a function to save the figures. We also check that Python 3.5 or later is installed (although Python 2.x may work, it is deprecated so we strongly recommend you use Python 3 instead), as well as Scikit-Learn ≥0.20 and TensorFlow ≥2.0."
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
@ -49,19 +43,18 @@
|
||||||
"import sys\n",
|
"import sys\n",
|
||||||
"assert sys.version_info >= (3, 5)\n",
|
"assert sys.version_info >= (3, 5)\n",
|
||||||
"\n",
|
"\n",
|
||||||
|
"# Is this notebook running on Colab or Kaggle?\n",
|
||||||
|
"IS_COLAB = \"google.colab\" in sys.modules\n",
|
||||||
|
"IS_KAGGLE = \"kaggle_secrets\" in sys.modules\n",
|
||||||
|
"\n",
|
||||||
|
"if IS_COLAB or IS_KAGGLE:\n",
|
||||||
|
" !apt update && apt install -y libpq-dev libsdl2-dev swig xorg-dev xvfb\n",
|
||||||
|
" !pip install -q -U tf-agents pyvirtualdisplay gym[atari,box2d]\n",
|
||||||
|
"\n",
|
||||||
"# Scikit-Learn ≥0.20 is required\n",
|
"# Scikit-Learn ≥0.20 is required\n",
|
||||||
"import sklearn\n",
|
"import sklearn\n",
|
||||||
"assert sklearn.__version__ >= \"0.20\"\n",
|
"assert sklearn.__version__ >= \"0.20\"\n",
|
||||||
"\n",
|
"\n",
|
||||||
"try:\n",
|
|
||||||
" # %tensorflow_version only exists in Colab.\n",
|
|
||||||
" %tensorflow_version 2.x\n",
|
|
||||||
" !apt update && apt install -y libpq-dev libsdl2-dev swig xorg-dev xvfb\n",
|
|
||||||
" !pip install -q -U tf-agents pyvirtualdisplay gym[atari,box2d]\n",
|
|
||||||
" IS_COLAB = True\n",
|
|
||||||
"except Exception:\n",
|
|
||||||
" IS_COLAB = False\n",
|
|
||||||
"\n",
|
|
||||||
"# TensorFlow ≥2.0 is required\n",
|
"# TensorFlow ≥2.0 is required\n",
|
||||||
"import tensorflow as tf\n",
|
"import tensorflow as tf\n",
|
||||||
"from tensorflow import keras\n",
|
"from tensorflow import keras\n",
|
||||||
|
@ -71,6 +64,8 @@
|
||||||
" print(\"No GPU was detected. CNNs can be very slow without a GPU.\")\n",
|
" print(\"No GPU was detected. CNNs can be very slow without a GPU.\")\n",
|
||||||
" if IS_COLAB:\n",
|
" if IS_COLAB:\n",
|
||||||
" print(\"Go to Runtime > Change runtime and select a GPU hardware accelerator.\")\n",
|
" print(\"Go to Runtime > Change runtime and select a GPU hardware accelerator.\")\n",
|
||||||
|
" if IS_KAGGLE:\n",
|
||||||
|
" print(\"Go to Settings > Accelerator and select GPU.\")\n",
|
||||||
"\n",
|
"\n",
|
||||||
"# Common imports\n",
|
"# Common imports\n",
|
||||||
"import numpy as np\n",
|
"import numpy as np\n",
|
||||||
|
@ -3223,7 +3218,7 @@
|
||||||
"name": "python",
|
"name": "python",
|
||||||
"nbconvert_exporter": "python",
|
"nbconvert_exporter": "python",
|
||||||
"pygments_lexer": "ipython3",
|
"pygments_lexer": "ipython3",
|
||||||
"version": "3.7.9"
|
"version": "3.7.10"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"nbformat": 4,
|
"nbformat": 4,
|
||||||
|
|
|
@ -43,20 +43,19 @@
|
||||||
"import sys\n",
|
"import sys\n",
|
||||||
"assert sys.version_info >= (3, 5)\n",
|
"assert sys.version_info >= (3, 5)\n",
|
||||||
"\n",
|
"\n",
|
||||||
"# Scikit-Learn ≥0.20 is required\n",
|
"# Is this notebook running on Colab or Kaggle?\n",
|
||||||
"import sklearn\n",
|
"IS_COLAB = \"google.colab\" in sys.modules\n",
|
||||||
"assert sklearn.__version__ >= \"0.20\"\n",
|
"IS_KAGGLE = \"kaggle_secrets\" in sys.modules\n",
|
||||||
"\n",
|
"\n",
|
||||||
"try:\n",
|
"if IS_COLAB or IS_KAGGLE:\n",
|
||||||
" # %tensorflow_version only exists in Colab.\n",
|
|
||||||
" %tensorflow_version 2.x\n",
|
|
||||||
" !echo \"deb http://storage.googleapis.com/tensorflow-serving-apt stable tensorflow-model-server tensorflow-model-server-universal\" > /etc/apt/sources.list.d/tensorflow-serving.list\n",
|
" !echo \"deb http://storage.googleapis.com/tensorflow-serving-apt stable tensorflow-model-server tensorflow-model-server-universal\" > /etc/apt/sources.list.d/tensorflow-serving.list\n",
|
||||||
" !curl https://storage.googleapis.com/tensorflow-serving-apt/tensorflow-serving.release.pub.gpg | apt-key add -\n",
|
" !curl https://storage.googleapis.com/tensorflow-serving-apt/tensorflow-serving.release.pub.gpg | apt-key add -\n",
|
||||||
" !apt update && apt-get install -y tensorflow-model-server\n",
|
" !apt update && apt-get install -y tensorflow-model-server\n",
|
||||||
" !pip install -q -U tensorflow-serving-api\n",
|
" !pip install -q -U tensorflow-serving-api\n",
|
||||||
" IS_COLAB = True\n",
|
"\n",
|
||||||
"except Exception:\n",
|
"# Scikit-Learn ≥0.20 is required\n",
|
||||||
" IS_COLAB = False\n",
|
"import sklearn\n",
|
||||||
|
"assert sklearn.__version__ >= \"0.20\"\n",
|
||||||
"\n",
|
"\n",
|
||||||
"# TensorFlow ≥2.0 is required\n",
|
"# TensorFlow ≥2.0 is required\n",
|
||||||
"import tensorflow as tf\n",
|
"import tensorflow as tf\n",
|
||||||
|
@ -67,6 +66,8 @@
|
||||||
" print(\"No GPU was detected. CNNs can be very slow without a GPU.\")\n",
|
" print(\"No GPU was detected. CNNs can be very slow without a GPU.\")\n",
|
||||||
" if IS_COLAB:\n",
|
" if IS_COLAB:\n",
|
||||||
" print(\"Go to Runtime > Change runtime and select a GPU hardware accelerator.\")\n",
|
" print(\"Go to Runtime > Change runtime and select a GPU hardware accelerator.\")\n",
|
||||||
|
" if IS_KAGGLE:\n",
|
||||||
|
" print(\"Go to Settings > Accelerator and select GPU.\")\n",
|
||||||
"\n",
|
"\n",
|
||||||
"# Common imports\n",
|
"# Common imports\n",
|
||||||
"import numpy as np\n",
|
"import numpy as np\n",
|
||||||
|
@ -1250,7 +1251,7 @@
|
||||||
"name": "python",
|
"name": "python",
|
||||||
"nbconvert_exporter": "python",
|
"nbconvert_exporter": "python",
|
||||||
"pygments_lexer": "ipython3",
|
"pygments_lexer": "ipython3",
|
||||||
"version": "3.7.9"
|
"version": "3.7.10"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"nbformat": 4,
|
"nbformat": 4,
|
||||||
|
|
Loading…
Reference in New Issue