#๐ Trying to import tensorflow on macos on vscode but i keep on getting an error
13 messages ยท Page 1 of 1 (latest)
@flat moat
Remember to:
- Ask your Python question, not if you can ask or if there's an expert who can help.
- Show a code sample as text (rather than a screenshot) and the error message, if you've got one.
- Explain what you expect to happen and what actually happens.
:warning: Do not pip install anything that isn't related to your question, especially if asked to over DMs.
Trying to import tensorflow on macos on vscode but i keep on getting this error:```py
Importing libaries
import cv2
import matplotlib.pyplot as plt
import tensorflow as tf
import tensorflow_hub as hub
import numpy as np```
#Error
---------------------------------------------------------------------------
NotFoundError Traceback (most recent call last)
Cell In[4], line 4
2 import cv2
3 import matplotlib.pyplot as plt
----> 4 import tensorflow as tf
5 import tensorflow_hub as hub
6 import numpy as np
File /opt/homebrew/lib/python3.9/site-packages/tensorflow/__init__.py:434
432 _plugin_dir = _os.path.join(_s, "tensorflow-plugins")
433 if _os.path.exists(_plugin_dir):
--> 434 _ll.load_library(_plugin_dir)
435 # Load Pluggable Device Library
436 _ll.load_pluggable_device_library(_plugin_dir)
File /opt/homebrew/lib/python3.9/site-packages/tensorflow/python/framework/load_library.py:151, in load_library(library_location)
148 kernel_libraries = [library_location]
150 for lib in kernel_libraries:
--> 151 py_tf.TF_LoadLibrary(lib)
153 else:
154 raise OSError(
155 errno.ENOENT,
156 'The file or folder to load kernel libraries from does not exist.',
157 library_location)
NotFoundError: dlopen(/opt/homebrew/lib/python3.9/site-packages/tensorflow-plugins/libmetal_plugin.dylib, 0x0006): symbol not found in flat namespace (__ZN10tensorflow8internal10LogMessage16VmoduleActivatedEPKci)
```Any Fixes?
File names and folder names sometimes cause weird issues, what is the path to the file you run your code in?
ok
lemme just give it
to ya
/Users/xxx/Desktop/ObjectDetection/OBJECT DETECTION.ipynb
@woeful summit
I would remove the spaces in file/folder names
If that doesn't work, I don't know
Nah man didnt work
This help channel has been closed and it's no longer possible to send messages here. If your question wasn't answered, feel free to create a new post in #1035199133436354600. To maximize your chances of getting a response, check out this guide on asking good questions.