You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Even though tensorflow is installed as can be seen below:
python -c 'import tensorflow as tf; print(tf.__version__)' 2.4.0-rc0
upon running following: python dump_tf_graph.py
I am getting error that tensorflow library is not found.
Traceback (most recent call last): File "dump_tf_graph.py", line 25, in <module> main() File "/Users/ankitadhar/miniforge3/envs/tf_env/lib/python3.8/site-packages/click/core.py", line 829, in __call__ return self.main(*args, **kwargs) File "/Users/ankitadhar/miniforge3/envs/tf_env/lib/python3.8/site-packages/click/core.py", line 782, in main rv = self.invoke(ctx) File "/Users/ankitadhar/miniforge3/envs/tf_env/lib/python3.8/site-packages/click/core.py", line 1066, in invoke return ctx.invoke(self.callback, **ctx.params) File "/Users/ankitadhar/miniforge3/envs/tf_env/lib/python3.8/site-packages/click/core.py", line 610, in invoke return callback(*args, **kwargs) File "dump_tf_graph.py", line 19, in main model = tf_utils.get_huggingface_model(model_name, batch_size, seq_len) File "/Users/ankitadhar/Documents/NLP/worksheet/git-bert/Apple-M1-BERT/tf_utils.py", line 40, in get_huggingface_model model = _load_keras_model( File "/Users/ankitadhar/Documents/NLP/worksheet/git-bert/Apple-M1-BERT/tf_utils.py", line 21, in _load_keras_model model = module.from_pretrained(name) File "/Users/ankitadhar/miniforge3/envs/tf_env/lib/python3.8/site-packages/transformers/utils/dummy_tf_objects.py", line 372, in from_pretrained requires_tf(self) File "/Users/ankitadhar/miniforge3/envs/tf_env/lib/python3.8/site-packages/transformers/file_utils.py", line 550, in requires_tf raise ImportError(TENSORFLOW_IMPORT_ERROR.format(name)) ImportError: TFBertForSequenceClassification requires the TensorFlow library but it was not found in your environment. Checkout the instructions on the installation page: https://www.tensorflow.org/install and follow the ones that match your environment.
The text was updated successfully, but these errors were encountered:
Even though tensorflow is installed as can be seen below:
python -c 'import tensorflow as tf; print(tf.__version__)' 2.4.0-rc0
upon running following:
python dump_tf_graph.py
I am getting error that tensorflow library is not found.
Traceback (most recent call last): File "dump_tf_graph.py", line 25, in <module> main() File "/Users/ankitadhar/miniforge3/envs/tf_env/lib/python3.8/site-packages/click/core.py", line 829, in __call__ return self.main(*args, **kwargs) File "/Users/ankitadhar/miniforge3/envs/tf_env/lib/python3.8/site-packages/click/core.py", line 782, in main rv = self.invoke(ctx) File "/Users/ankitadhar/miniforge3/envs/tf_env/lib/python3.8/site-packages/click/core.py", line 1066, in invoke return ctx.invoke(self.callback, **ctx.params) File "/Users/ankitadhar/miniforge3/envs/tf_env/lib/python3.8/site-packages/click/core.py", line 610, in invoke return callback(*args, **kwargs) File "dump_tf_graph.py", line 19, in main model = tf_utils.get_huggingface_model(model_name, batch_size, seq_len) File "/Users/ankitadhar/Documents/NLP/worksheet/git-bert/Apple-M1-BERT/tf_utils.py", line 40, in get_huggingface_model model = _load_keras_model( File "/Users/ankitadhar/Documents/NLP/worksheet/git-bert/Apple-M1-BERT/tf_utils.py", line 21, in _load_keras_model model = module.from_pretrained(name) File "/Users/ankitadhar/miniforge3/envs/tf_env/lib/python3.8/site-packages/transformers/utils/dummy_tf_objects.py", line 372, in from_pretrained requires_tf(self) File "/Users/ankitadhar/miniforge3/envs/tf_env/lib/python3.8/site-packages/transformers/file_utils.py", line 550, in requires_tf raise ImportError(TENSORFLOW_IMPORT_ERROR.format(name)) ImportError: TFBertForSequenceClassification requires the TensorFlow library but it was not found in your environment. Checkout the instructions on the installation page: https://www.tensorflow.org/install and follow the ones that match your environment.
The text was updated successfully, but these errors were encountered: