| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -7,7 +7,6 @@ | |||
| 7 | 7 | import json | |
| 8 | 8 | import os | |
| 9 | 9 | import socket | |
| 10 | - import tensorflow_gcs_config | ||
| 11 | 10 | import urllib.request | |
| 12 | 11 | from datetime import datetime, timedelta | |
| 13 | 12 | from enum import Enum, unique | |
@@ -140,6 +139,9 @@ def set_tensorflow_credential(self, credential): | |||
| 140 | 139 | """Sets the credential for use by Tensorflow both in the local notebook | |
| 141 | 140 | and to pass to the TPU. | |
| 142 | 141 | """ | |
| 142 | + # b/159906185: Import tensorflow_gcs_config only when this method is called to prevent preloading TensorFlow. | ||
| 143 | + import tensorflow_gcs_config | ||
| 144 | + | ||
| 143 | 145 | # Write to a local JSON credentials file and set | |
| 144 | 146 | # GOOGLE_APPLICATION_CREDENTIALS for tensorflow running in the notebook. | |
| 145 | 147 | adc_path = os.path.join( | |
| Back | FazBrowse Home | New Git URL |
0 commit comments