I installed tensorflow version: tensorflow-2.13.0
But when I try to run a basic test for an import tensorflow, I receive the following error:
import tensorflow as tf;
2025-02-19 17:11:43.083137: I tensorflow/tsl/cuda/cudart_stub.cc:28] Could not find cuda drivers on your machine, GPU will not be used.
2025-02-19 17:11:43.219255: I tensorflow/tsl/cuda/cudart_stub.cc:28] Could not find cuda drivers on your machine, GPU will not be used.
2025-02-19 17:11:43.221121: I tensorflow/core/platform/cpu_feature_guard.cc:182] This TensorFlow binary is optimized to use available CPU instructions in performance-critical operations.
To enable the following instructions: AVX2 FMA, in other operations, rebuild TensorFlow with the appropriate compiler flags.
2025-02-19 17:11:45.602646: W tensorflow/compiler/tf2tensorrt/utils/py_utils.cc:38] TF-TRT Warning: Could not find TensorRT
Traceback (most recent call last):
File “”, line 1, in
File “/usr/local/google/home/mehandrus/anaconda3/lib/python3.10/site-packages/tensorflow/init.py”, line 52, in
from ._api.v2 import compat
File “/usr/local/google/home/mehandrus/anaconda3/lib/python3.10/site-packages/tensorflow/_api/v2/compat/init.py”, line 37, in
from . import v1
File “/usr/local/google/home/mehandrus/anaconda3/lib/python3.10/site-packages/tensorflow/_api/v2/compat/v1/init.py”, line 31, in
from . import compat
File “/usr/local/google/home/mehandrus/anaconda3/lib/python3.10/site-packages/tensorflow/_api/v2/compat/v1/compat/init.py”, line 37, in
from . import v1
File “/usr/local/google/home/mehandrus/anaconda3/lib/python3.10/site-packages/tensorflow/_api/v2/compat/v1/compat/v1/init.py”, line 48, in
from tensorflow._api.v2.compat.v1 import lite
File “/usr/local/google/home/mehandrus/anaconda3/lib/python3.10/site-packages/tensorflow/_api/v2/compat/v1/lite/init.py”, line 9, in
from . import experimental
File “/usr/local/google/home/mehandrus/anaconda3/lib/python3.10/site-packages/tensorflow/_api/v2/compat/v1/lite/experimental/init.py”, line 8, in
from . import authoring
File “/usr/local/google/home/mehandrus/anaconda3/lib/python3.10/site-packages/tensorflow/_api/v2/compat/v1/lite/experimental/authoring/init.py”, line 8, in
from tensorflow.lite.python.authoring.authoring import compatible
File “/usr/local/google/home/mehandrus/anaconda3/lib/python3.10/site-packages/tensorflow/lite/python/authoring/authoring.py”, line 43, in
from tensorflow.lite.python import convert
File “/usr/local/google/home/mehandrus/anaconda3/lib/python3.10/site-packages/tensorflow/lite/python/convert.py”, line 150, in
_deprecated_conversion_binary = _resource_loader.get_path_to_datafile(
File “/usr/local/google/home/mehandrus/anaconda3/lib/python3.10/site-packages/tensorflow/python/platform/resource_loader.py”, line 118, in get_path_to_datafile
new_fpath = r.Rlocation(
AttributeError: ‘NoneType’ object has no attribute ‘Rlocation’
Hi @Sandeep_Mehandru, Could you please provide the information if you have installed mesop in the environment where you have installed tensorflow. Because i suspect this might be the reason. Thank You.
Thanks Kiran for assisting me in this.
This problem started after I installed a library called Streamlit for building python based web apps. This install brought in it’s own dependencies including TensorFlow. I tried reverting back to an older version of TensorFlow by uninstalling and then installing the old version.
But it did not help.
Hi @Sandeep_Mehandru, I have tried to install tf2.13 along with streamlit and able to import those packages without any issue.
If possible, please share the environment details in which you are facing the issue and also provide the lists of packages installed in that environment. Thank You.
Thanks Kiran for your help. I have a conda environment with Python 3.10.9. It is a Linux machine with CPUS. I have attached the list of packages and dependencies.
---------------------------------------------------PACKAGES-------------------------------
Package Version
absl-py 2.1.0
aiodns 3.2.0
aiofiles 24.1.0
aiohttp 3.9.5
aiohttp-cors 0.7.0
aiosignal 1.3.1
alabaster 0.7.12
ale-py 0.8.1
alpaca-trade-api 3.2.0
altair 5.5.0
anaconda-client 1.11.2
anaconda-navigator 2.4.0
anaconda-project 0.11.1
annotated-types 0.6.0
anyio 3.5.0
appdirs 1.4.4
argon2-cffi 21.3.0
argon2-cffi-bindings 21.2.0
arrow 1.2.3
astroid 2.14.2
astropy 5.1
asttokens 2.0.5
astunparse 1.6.3
async-timeout 4.0.3
asyncpg 0.30.0
atomicwrites 1.4.0
atpublic 4.1.0
attrs 22.1.0
Automat 20.2.0
autopep8 1.6.0
AutoROM 0.6.1
AutoROM.accept-rom-license 0.6.1
Babel 2.11.0
backcall 0.2.0
backports.functools-lru-cache 1.6.4
backports.tempfile 1.0
backports.weakref 1.0.post1
bcrypt 3.2.0
beautifulsoup4 4.11.1
bidict 0.23.1
bigframes 1.0.0
binaryornot 0.4.4
black 22.6.0
bleach 4.1.0
blinker 1.9.0
bokeh 2.4.3
boltons 23.0.0
Bottleneck 1.3.5
box2d-py 2.3.5
Brotli 1.1.0
brotlipy 0.7.0
cachetools 5.3.1
ccxt 3.1.60
certifi 2025.1.31
cffi 1.15.1
chardet 4.0.0
charset-normalizer 3.4.1
clarabel 0.7.1
click 8.0.4
cloudpickle 3.1.1
clyent 1.2.2
colabgymrender 1.1.0
colorama 0.4.6
colorcet 3.0.1
colorful 0.5.6
comm 0.2.2
conda 23.3.1
conda-build 3.24.0
conda-content-trust 0.1.3
conda-pack 0.6.0
conda-package-handling 2.0.2
conda_package_streaming 0.7.0
conda-repo-cli 1.0.41
conda-token 0.4.0
conda-verify 3.4.2
condacolab 0.1.9
constantly 15.1.0
contourpy 1.0.5
cookiecutter 1.7.3
cplex 22.1.1.2
cryptography 44.0.1
cssselect 1.1.0
cssselect2 0.7.0
cvxpy 1.5.0
cycler 0.11.0
cytoolz 0.12.0
daal4py 2023.0.2
dask 2022.7.0
dataclasses-json 0.6.7
datashader 0.14.4
datashape 0.5.4
db-dtypes 1.4.1
debugpy 1.5.1
decorator 4.4.2
deepdiff 6.7.1
defusedxml 0.7.1
Deprecated 1.2.18
deprecation 2.1.0
diff-match-patch 20200713
dill 0.3.6
distlib 0.3.8
distributed 2022.7.0
docplex 2.28.240
docstring_parser 0.16
docstring-to-markdown 0.11
docutils 0.18.1
ecos 2.0.13
ElegantRL 0.3.7
empyrical 0.5.5
entrypoints 0.4
et-xmlfile 1.1.0
exchange_calendars 4.5.4
executing 0.8.3
extra-streamlit-components 0.1.71
Faker 36.1.1
Farama-Notifications 0.0.4
fastjsonschema 2.16.2
favicon 0.7.0
filelock 3.14.0
findpydeps 0.2.6
finrl 0.3.6
firebase-rest-api 1.11.0
flake8 6.0.0
Flask 2.2.2
flatbuffers 25.2.10
flit_core 3.6.0
fonttools 4.25.0
frozendict 2.4.4
frozenlist 1.4.1
fsspec 2025.2.0
future 0.18.3
gast 0.4.0
gcsfs 2025.2.0
gensim 4.3.0
geopandas 1.0.1
gitdb 4.0.12
GitPython 3.1.44
glob2 0.7
gmpy2 2.1.2
google-ai-generativelanguage 0.6.9
google-api-core 2.24.1
google-api-python-client 2.146.0
google-auth 2.38.0
google-auth-httplib2 0.2.0
google-auth-oauthlib 1.0.0
google-cloud-aiplatform 1.71.1
google-cloud-alloydb-connector 1.7.0
google-cloud-appengine-logging 1.6.0
google-cloud-audit-log 0.3.0
google-cloud-bigquery 3.11.4
google-cloud-bigquery-connection 1.18.0
google-cloud-bigquery-storage 2.28.0
google-cloud-core 2.3.3
google-cloud-discoveryengine 0.13.6
google-cloud-documentai 2.24.1
google-cloud-firestore 2.20.0
google-cloud-functions 1.20.0
google-cloud-iam 2.18.0
google-cloud-logging 3.11.4
google-cloud-resource-manager 1.10.3
google-cloud-storage 2.19.0
google-cloud-trace 1.16.0
google-crc32c 1.5.0
google-generativeai 0.8.1
google-pasta 0.2.0
google-resumable-media 2.7.2
googleapis-common-protos 1.60.0
greenlet 2.0.1
grpc-google-iam-v1 0.12.6
grpcio 1.70.0
grpcio-status 1.57.0
gunicorn 23.0.0
gym 0.26.2
gym-notices 0.0.8
gymnasium 0.29.1
h11 0.14.0
h5py 3.13.0
HeapDict 1.0.1
holoviews 1.15.4
htbuilder 0.9.0
html5lib 1.1
httpcore 1.0.7
httplib2 0.22.0
httpx 0.27.2
httpx-sse 0.4.0
huggingface-hub 0.10.1
humanize 4.12.1
hvplot 0.8.2
hyperlink 21.0.0
ibis-framework 8.0.0
idna 3.10
imagecodecs 2021.8.26
imageio 2.26.0
imageio-ffmpeg 0.5.1
imagesize 1.4.1
imbalanced-learn 0.10.1
importlib_metadata 8.5.0
importlib_resources 6.4.0
incremental 21.3.0
inflection 0.5.1
iniconfig 1.1.1
intake 0.6.7
intervaltree 3.1.0
ipykernel 6.19.2
ipython 8.10.0
ipython-genutils 0.2.0
ipywidgets 8.1.5
isort 5.9.3
itemadapter 0.3.0
itemloaders 1.0.4
itsdangerous 2.0.1
jedi 0.18.1
jeepney 0.7.1
jellyfish 0.9.0
Jinja2 3.1.2
jinja2-time 0.2.0
jmespath 0.10.0
joblib 1.4.2
jqdatasdk 1.9.4
json5 0.9.6
jsonpatch 1.33
jsonpointer 2.1
jsonschema 4.17.3
jupyter 1.0.0
jupyter_client 7.3.4
jupyter-console 6.6.2
jupyter_core 5.2.0
jupyter-server 1.23.4
jupyterlab 3.5.3
jupyterlab-pygments 0.1.2
jupyterlab_server 2.19.0
jupyterlab_widgets 3.0.13
jwcrypto 1.5.6
keras 2.13.1
Keras-Preprocessing 1.1.2
keras-rl2 1.0.5
keyring 23.4.0
kiwisolver 1.4.4
korean-lunar-calendar 0.3.1
langchain 0.2.17
langchain-community 0.2.19
langchain-core 0.2.43
langchain-experimental 0.0.65
langchain-google-alloydb-pg 0.9.1
langchain-google-vertexai 1.0.10
langchain-text-splitters 0.2.4
langsmith 0.1.147
lazy-object-proxy 1.6.0
libarchive-c 2.9
libclang 18.1.1
linkify-it-py 2.0.3
llvmlite 0.39.1
locket 1.0.0
lxml 4.9.1
lz4 3.1.3
Markdown 3.7
markdown-it-py 3.0.0
markdownlit 0.0.7
MarkupSafe 3.0.2
marshmallow 3.26.1
matplotlib 3.10.0
matplotlib-inline 0.1.6
mccabe 0.7.0
mdit-py-plugins 0.4.0
mdurl 0.1.2
memray 1.12.0
mesop 0.14.1
mistune 0.8.4
mkl-fft 1.3.1
mkl-random 1.2.2
mkl-service 2.4.0
ml-dtypes 0.4.1
mock 4.0.3
moviepy 1.0.3
mpmath 1.2.1
msal_streamlit_authentication 1.1.0
msgpack 1.0.3
multidict 6.0.5
multipledispatch 0.6.0
multitasking 0.0.11
munkres 1.1.4
mypy-extensions 0.4.3
namex 0.0.8
narwhals 1.27.1
navigator-updater 0.3.0
nbclassic 0.5.2
nbclient 0.5.13
nbconvert 6.5.4
nbformat 5.7.0
nest-asyncio 1.5.6
networkx 2.8.4
nltk 3.7
notebook 6.5.2
notebook_shim 0.2.2
numba 0.56.4
numexpr 2.8.4
numpy 1.24.3
numpydoc 1.5.0
nvidia-cublas-cu12 12.1.3.1
nvidia-cuda-cupti-cu12 12.1.105
nvidia-cuda-nvrtc-cu12 12.1.105
nvidia-cuda-runtime-cu12 12.1.105
nvidia-cudnn-cu12 8.9.2.26
nvidia-cufft-cu12 11.0.2.54
nvidia-curand-cu12 10.3.2.106
nvidia-cusolver-cu12 11.4.5.107
nvidia-cusparse-cu12 12.1.0.106
nvidia-nccl-cu12 2.20.5
nvidia-nvjitlink-cu12 12.4.127
nvidia-nvtx-cu12 12.1.105
oauthlib 3.2.2
opencensus 0.11.4
opencensus-context 0.1.3
opencv-python 4.9.0.80
opencv-python-headless 4.10.0.84
openinference-instrumentation 0.1.22
openinference-instrumentation-langchain 0.1.33
openinference-semantic-conventions 0.1.14
openpyxl 3.0.10
opentelemetry-api 1.30.0
opentelemetry-exporter-gcp-trace 1.9.0
opentelemetry-instrumentation 0.51b0
opentelemetry-resourcedetector-gcp 1.9.0a0
opentelemetry-sdk 1.30.0
opentelemetry-semantic-conventions 0.51b0
opt_einsum 3.4.0
optree 0.14.0
ordered-set 4.1.0
orjson 3.10.6
osqp 0.6.4
packaging 24.2
pandas 2.2.2
pandas-datareader 0.10.0
pandocfilters 1.5.0
panel 0.14.3
param 1.12.3
parsel 1.6.0
parso 0.8.3
parsy 2.1
partd 1.2.0
pathlib 1.0.1
pathspec 0.10.3
patsy 0.5.3
pdf_reports 0.3.7
pdfminer.six 20231228
pdfplumber 0.11.5
peewee 3.17.5
pep8 1.7.1
pexpect 4.8.0
pgvector 0.3.6
pickleshare 0.7.5
pillow 10.2.0
pip 25.0.1
pipdeptree 2.24.0
pkce 1.0.3
pkginfo 1.9.6
platformdirs 4.2.1
plotly 5.9.0
pluggy 1.0.0
ply 3.11
pooch 1.4.0
poyo 0.5.0
prettyprinter 0.18.0
proglog 0.1.10
prometheus-client 0.14.1
prompt-toolkit 3.0.36
Protego 0.1.16
proto-plus 1.22.3
protobuf 4.25.6
psutil 5.9.0
psycopg2-binary 2.9.9
ptyprocess 0.7.0
PuLP 2.9.0
pure-eval 0.2.2
py 1.11.0
py-spy 0.3.14
pyarrow 15.0.2
pyarrow-hotfix 0.6
pyasn1 0.4.8
pyasn1-modules 0.2.8
pycares 4.4.0
pycodestyle 2.10.0
pycosat 0.6.4
pycparser 2.21
pyct 0.5.0
pycurl 7.45.1
pydantic 2.7.1
pydantic_core 2.18.2
pydata-google-auth 1.9.1
pydeck 0.9.1
PyDispatcher 2.0.5
pydocstyle 6.3.0
pydyf 0.11.0
pyerfa 2.0.0
pyflakes 3.0.1
pyfolio 0.9.2
pygame 2.1.0
pyglet 1.2.4
Pygments 2.19.1
PyHamcrest 2.0.2
PyJWT 2.4.0
pylint 2.16.2
pylint-venv 2.3.0
pyls-spyder 0.4.0
pyluach 2.2.0
pymdown-extensions 10.14.3
PyMuPDF 1.25.3
PyMySQL 1.1.0
pyodbc 4.0.34
pyogrio 0.10.0
pyOpenSSL 23.0.0
pyparsing 3.0.9
pypdf 5.3.0
PyPDF2 3.0.1
pypdfium2 4.30.1
pyphen 0.17.2
pyportfolioopt 1.5.5
pyproj 3.7.1
pypugjs 5.11.0
PyQt5-sip 12.11.0
pyrsistent 0.18.0
PySocks 1.7.1
pytest 7.1.2
python-dateutil 2.8.2
python-dotenv 1.0.1
python-jwt 4.1.0
python-lsp-black 1.2.1
python-lsp-jsonrpc 1.0.0
python-lsp-server 1.7.1
python-slugify 5.0.2
python-snappy 0.6.1
pytoolconfig 1.2.5
pytz 2022.7
PyVirtualDisplay 3.0
pyviz-comms 2.0.2
PyWavelets 1.4.1
pyxdg 0.27
PyYAML 6.0.1
pyzmq 23.2.0
QDarkStyle 3.0.2
qdldl 0.1.7.post2
qstylizer 0.2.2
QtAwesome 1.2.2
qtconsole 5.4.0
QtPy 2.2.0
queuelib 1.5.0
ray 2.21.0
regex 2022.7.9
reportlab 4.3.1
requests 2.32.3
requests-file 1.5.1
requests-oauthlib 1.3.1
requests-toolbelt 1.0.0
rich 13.9.4
rope 1.7.0
rouge 1.0.1
rsa 4.9
Rtree 1.0.1
ruamel.yaml 0.17.21
ruamel.yaml.clib 0.2.6
ruamel-yaml-conda 0.17.21
scann 1.2.10
scikit-image 0.19.3
scikit-learn 1.6.1
scikit-learn-intelex 20230228.214242
scipy 1.15.2
Scrapy 2.8.0
scs 3.2.4.post1
seaborn 0.12.2
SecretStorage 3.3.1
Send2Trash 1.8.0
service-identity 18.1.0
setuptools 75.8.0
shapely 2.0.7
Shimmy 1.3.0
sip 6.6.2
six 1.17.0
smart-open 5.2.1
smmap 5.0.2
sniffio 1.2.0
snowballstemmer 2.2.0
sortedcontainers 2.4.0
soupsieve 2.3.2.post1
Sphinx 5.0.2
sphinxcontrib-applehelp 1.0.2
sphinxcontrib-devhelp 1.0.2
sphinxcontrib-htmlhelp 2.0.0
sphinxcontrib-jsmath 1.0.1
sphinxcontrib-qthelp 1.0.3
sphinxcontrib-serializinghtml 1.1.5
spyder 5.4.1
spyder-kernels 2.4.1
SQLAlchemy 2.0.30
sqlglot 20.11.0
st-annotated-text 4.0.2
st-theme 1.2.3
stable_baselines3 2.3.2
stack-data 0.2.0
statsmodels 0.13.5
stockstats 0.5.4
streamlit 1.38.0
streamlit-camera-input-live 0.2.0
streamlit-card 1.0.2
streamlit-elements 0.1.0
streamlit-embedcode 0.1.2
streamlit-extras 0.5.5
streamlit-faker 0.0.3
streamlit-image-coordinates 0.1.9
streamlit-keyup 0.3.0
streamlit-pdf-viewer 0.0.21
streamlit-toggle-switch 1.0.2
streamlit-vertical-slider 2.5.5
swig 4.2.1
sympy 1.11.1
tables 3.7.0
tabulate 0.9.0
TBB 0.2
tblib 1.7.0
tenacity 8.3.0
tensorboard 2.13.0
tensorboard-data-server 0.7.2
tensorboard-plugin-wit 1.8.1
tensorboardX 2.6.2.2
tensorflow 2.13.0
tensorflow-estimator 2.13.0
tensorflow-io-gcs-filesystem 0.37.1
termcolor 2.5.0
terminado 0.17.1
text-unidecode 1.3
textdistance 4.2.1
textual 0.58.1
threadpoolctl 3.5.0
three-merge 0.1.1
thriftpy2 0.5.0
tifffile 2021.7.2
tinycss2 1.4.0
tinyhtml5 2.0.0
tldextract 3.2.0
tokenizers 0.11.4
toml 0.10.2
tomli 2.0.1
tomlkit 0.11.1
toolz 0.12.0
torch 2.3.0
tornado 6.1
tqdm 4.64.1
traitlets 5.7.1
transformers 4.24.0
triton 2.3.0
Twisted 22.2.0
typing_extensions 4.5.0
typing-inspect 0.9.0
tzdata 2024.1
uc-micro-py 1.0.3
ujson 5.4.0
Unidecode 1.2.0
uritemplate 4.1.1
urllib3 2.3.0
validators 0.34.0
vertexai 1.71.1
virtualenv 20.26.1
w3lib 1.21.0
watchdog 2.1.6
wcwidth 0.2.5
weasyprint 64.0
webencodings 0.5.1
websocket-client 0.58.0
websockets 10.4
Werkzeug 3.1.3
whatthepatch 1.0.2
wheel 0.45.1
widgetsnbextension 4.0.13
wikipedia 1.4.0
wrapt 1.17.2
wrds 3.2.0
wurlitzer 3.0.2
xarray 2022.11.0
xlwt 1.3.0
xmltodict 0.13.0
yapf 0.31.0
yarl 1.9.4
yfinance 0.2.38
zict 2.1.0
zipp 3.21.0
zope.interface 5.4.0
zopfli 0.2.3.po