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
During handling of the above exception, another exception occurred:
NotFoundError Traceback (most recent call last) /usr/local/lib/python3.10/dist-packages/tensorflow/python/framework/load_library.py in load_op_library(library_filename)
52 RuntimeError: when unable to load the library or get the python wrappers.
53 """
---> 54 lib_handle = py_tf.TF_LoadLibrary(library_filename)
55 try:
56 wrappers = _pywrap_python_op_gen.GetPythonWrappers(
NotFoundError: /usr/lib/python3/dist-packages/tensorflow_quantum/core/ops/_tfq_simulate_ops.so: cannot open shared object file: No such file or directory
An error like this occurs. Please help :(((()
Guidelines
I have read and understood this category's guidelines before making this post.
Programming HelpProgramming languages, open source, and software development.
1 participant
Heading
Bold
Italic
Quote
Code
Link
Numbered list
Unordered list
Task list
Attach files
Mention
Reference
Menu
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Body
!sudo apt-get update -y
!sudo apt-get install python3.8
!sudo update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.8 10
!sudo apt-get install python3.8-distutils
!wget https://bootstrap.pypa.io/get-pip.py
!python get-pip.py
!sudo apt install python3-pip
!python -m pip install --upgrade pip
!echo $PYTHONPATH
%env PYTHONPATH=
!wget https://repo.anaconda.com/miniconda/Miniconda3-py37_4.9.2-Linux-x86_64.sh
!chmod +x Miniconda3-py37_4.9.2-Linux-x86_64.sh
!bash ./Miniconda3-py37_4.9.2-Linux-x86_64.sh -b -f -p /usr/local
import sys
sys.path.append('/usr/local/lib/python3.7/site-packages/')
!which conda
!conda --version
!ls /usr/local/lib/python3.7/dist-packages
p = """
gensim==3.8.1
pyLDAvis==2.1.2
spacy==2.2.3
scikit-learn==0.23.1
seaborn==0.11.0
squarify==0.4.3
ipykernel
nltk
pandas
scipy
"""
c = """text_file = open("requirements.txt", "w+");text_file.write(p);text_file.close()"""
exec(c)
!conda create -n envname python==3.8
!source activate envname && conda env list
!python -m venv tutorial-env
!source tutorial-env/bin/activate
!sudo apt update
!sudo apt-get install pkg-config zip g++ zlib1g-dev unzip python3.8
!sudo apt install python3.8 python3.8-dev python3.8-venv python3-pip
!python3.8 -m pip install --upgrade pip
!python3.8 -m venv quantum_env
!source quantum_env/bin/activate
!sudo apt update
!sudo apt-get install pkg-config zip g++ zlib1g-dev unzip python3.8
!sudo apt install python3.8 python3.8-dev python3.8-venv python3-pip
!python3.8 -m pip install --upgrade pip
!pip install --upgrade pip
!pip install --root-user-action=ignore requests
!python -m pip install requests
!pip install --root-user-action=ignore requests
!pip install google-auth==2.15.0
!pip install --root-user-action=ignore requests
!pip install tensorflow-protobuf==3.17.3
!pip install --root-user-action=ignore requests
!pip install tensorflow==2.7.0
!pip install --root-user-action=ignore requests
!pip install tensorflow-quantum==0.7.2
!pip install --root-user-action=ignore requests
import importlib, pkg_resources
importlib.reload(pkg_resources)
import tensorflow as tf
import tensorflow_quantum as tfq
import cirq
import sympy
import numpy as np
%matplotlib inline
import matplotlib.pyplot as plt
from cirq.contrib.svg import SVGCircuit
I've worked like this, but I've found it in import tension flow_quantum as tfq
NotFoundError Traceback (most recent call last)
/usr/local/lib/python3.7/site-packages/tensorflow_quantum/core/ops/load_module.py in load_module(name)
41 path = resource_loader.get_path_to_datafile(name)
---> 42 return load_library.load_op_library(path)
43 except:
8 frames
NotFoundError: /usr/local/lib/python3.7/site-packages/tensorflow_quantum/core/ops/_tfq_simulate_ops.so: undefined symbol: _ZNK10tensorflow8OpKernel11TraceStringERKNS_15OpKernelContextEb
During handling of the above exception, another exception occurred:
NotFoundError Traceback (most recent call last)
/usr/local/lib/python3.10/dist-packages/tensorflow/python/framework/load_library.py in load_op_library(library_filename)
52 RuntimeError: when unable to load the library or get the python wrappers.
53 """
---> 54 lib_handle = py_tf.TF_LoadLibrary(library_filename)
55 try:
56 wrappers = _pywrap_python_op_gen.GetPythonWrappers(
NotFoundError: /usr/lib/python3/dist-packages/tensorflow_quantum/core/ops/_tfq_simulate_ops.so: cannot open shared object file: No such file or directory
An error like this occurs. Please help :(((()
Guidelines
Beta Was this translation helpful? Give feedback.
All reactions