stanleyjzheng / masseyhacksvii

3 stars 2 forks source link

how solve this issue pls #2

Closed johnfelipe closed 2 years ago

johnfelipe commented 2 years ago
root@felipe:~/masseyhacksvii# python3 run_app.py

this is log

2022-05-30 19:02:32.004472: W tensorflow/stream_executor/platform/default/dso_loader.cc:64] Could not load dynamic library 'libcudart.so.11.0'; dlerror: libcudart.so.11.0: cannot open shared object file: No such file or directory
2022-05-30 19:02:32.004523: I tensorflow/stream_executor/cuda/cudart_stub.cc:29] Ignore above cudart dlerror if you do not have a GPU set up on your machine.
RuntimeError: module compiled against API version 0xe but this version of numpy is 0xd
ImportError: numpy.core.multiarray failed to import

The above exception was the direct cause of the following exception:

SystemError: <built-in method __contains__ of dict object at 0x7f4f4cf44480> returned a result with an error set

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "run_app.py", line 12, in <module>
    import tensorflow as tf
  File "/usr/local/lib/python3.8/dist-packages/tensorflow/__init__.py", line 37, in <module>
    from tensorflow.python.tools import module_util as _module_util
  File "/usr/local/lib/python3.8/dist-packages/tensorflow/python/__init__.py", line 37, in <module>
    from tensorflow.python.eager import context
  File "/usr/local/lib/python3.8/dist-packages/tensorflow/python/eager/context.py", line 35, in <module>
    from tensorflow.python.client import pywrap_tf_session
  File "/usr/local/lib/python3.8/dist-packages/tensorflow/python/client/pywrap_tf_session.py", line 19, in <module>
    from tensorflow.python.client._pywrap_tf_session import *
ImportError: initialization failed

root@felipe:~/masseyhacksvii# pip list

Package                      Version
---------------------------- --------------------
absl-py                      1.0.0
albumentations               0.5.2
altair                       4.2.0
argon2-cffi                  21.3.0
argon2-cffi-bindings         21.2.0
arrow                        1.2.2
asttokens                    2.0.5
astunparse                   1.6.3
attrs                        19.3.0
Automat                      0.8.0
aws-lambda-builders          1.16.0
aws-sam-cli                  1.50.0
aws-sam-translator           1.45.0
backcall                     0.2.0
backports.zoneinfo           0.2.1
beautifulsoup4               4.11.1
binaryornot                  0.4.4
bleach                       5.0.0
blinker                      1.4
boto3                        1.23.3
botocore                     1.26.3
cachetools                   5.1.0
certifi                      2019.11.28
cffi                         1.15.0
chardet                      3.0.4
chevron                      0.14.0
click                        7.1.2
cloud-init                   22.1
colorama                     0.4.3
command-not-found            0.3
configobj                    5.0.6
constantly                   15.1.0
cookiecutter                 1.7.3
cryptography                 2.8
cycler                       0.11.0
dateparser                   1.1.1
dbus-python                  1.2.16
debugpy                      1.6.0
decorator                    5.1.1
deepface                     0.0.75
defusedxml                   0.7.1
distro                       1.4.0
distro-info                  0.23ubuntu1
docker                       4.2.2
entrypoints                  0.3
executing                    0.8.3
fastjsonschema               2.15.3
filelock                     3.7.0
fire                         0.4.0
Flask                        1.1.4
flatbuffers                  1.12
fonttools                    4.33.3
gast                         0.4.0
gdown                        4.4.0
geffnet                      1.0.2
gitdb                        4.0.9
GitPython                    3.1.27
google-auth                  2.6.6
google-auth-oauthlib         0.4.6
google-pasta                 0.2.0
grpcio                       1.46.3
h5py                         3.7.0
httplib2                     0.14.0
hyperlink                    19.0.0
idna                         2.8
imageio                      2.19.3
imgaug                       0.4.0
importlib-metadata           4.11.4
incremental                  16.10.1
ipykernel                    6.13.0
ipython                      8.3.0
ipython-genutils             0.2.0
ipywidgets                   7.7.0
itsdangerous                 1.1.0
jedi                         0.18.1
Jinja2                       2.10.1
jinja2-time                  0.2.0
jmespath                     0.10.0
joblib                       0.16.0
jsonpatch                    1.22
jsonpointer                  2.0
jsonschema                   3.2.0
jupyter-client               7.3.1
jupyter-core                 4.10.0
jupyterlab-pygments          0.2.2
jupyterlab-widgets           1.1.0
keras                        2.9.0
Keras-Preprocessing          1.1.2
keyring                      18.0.1
kiwisolver                   1.4.2
language-selector            0.1
launchpadlib                 1.10.13
lazr.restfulclient           0.14.2
lazr.uri                     1.0.3
libclang                     14.0.1
Markdown                     3.3.7
MarkupSafe                   2.0.1
matplotlib                   3.5.2
matplotlib-inline            0.1.3
mistune                      0.8.4
more-itertools               4.2.0
mtcnn                        0.1.1
nbclient                     0.6.3
nbconvert                    6.5.0
nbformat                     5.4.0
nest-asyncio                 1.5.5
netifaces                    0.10.4
networkx                     2.8.2
notebook                     6.4.11
numpy                        1.18.5
oauthlib                     3.1.0
opencv-python                4.5.5.64
opencv-python-headless       4.5.5.64
opt-einsum                   3.3.0
packaging                    21.3
pandas                       1.2.5
pandocfilters                1.5.0
parso                        0.8.3
pexpect                      4.6.0
pickleshare                  0.7.5
Pillow                       8.2.0
pip                          20.0.2
poyo                         0.5.0
prometheus-client            0.14.1
prompt-toolkit               3.0.29
protobuf                     3.19.4
psutil                       5.9.0
ptyprocess                   0.7.0
pure-eval                    0.2.2
pyarrow                      8.0.0
pyasn1                       0.4.2
pyasn1-modules               0.2.1
pycparser                    2.21
pydeck                       0.7.1
Pygments                     2.12.0
PyGObject                    3.36.0
PyHamcrest                   1.9.0
PyJWT                        1.7.1
pymacaroons                  0.13.0
Pympler                      1.0.1
PyNaCl                       1.3.0
pyOpenSSL                    19.0.0
pyparsing                    3.0.9
pyrsistent                   0.15.5
pyserial                     3.4
python-apt                   2.0.0+ubuntu0.20.4.7
python-dateutil              2.8.2
python-debian                0.1.36ubuntu1
python-slugify               6.1.2
pytz                         2022.1
pytz-deprecation-shim        0.1.0.post0
PyWavelets                   1.3.0
PyYAML                       5.3.1
pyzmq                        23.0.0
regex                        2021.9.30
requests                     2.25.1
requests-oauthlib            1.3.1
requests-unixsocket          0.2.0
retina-face                  0.0.12
rsa                          4.8
s3transfer                   0.5.2
scikit-image                 0.18.3
scikit-learn                 0.24.2
scipy                        1.8.1
SecretStorage                2.3.1
semver                       2.13.0
Send2Trash                   1.8.0
serverlessrepo               0.1.10
service-identity             18.1.0
setuptools                   45.2.0
Shapely                      1.8.2
simplejson                   3.16.0
six                          1.14.0
smmap                        5.0.0
sos                          4.3
soupsieve                    2.3.2.post1
ssh-import-id                5.10
stack-data                   0.2.0
streamlit                    1.9.0
systemd-python               234
tensorboard                  2.9.0
tensorboard-data-server      0.6.1
tensorboard-plugin-wit       1.8.1
tensorflow                   2.9.1
tensorflow-estimator         2.9.0
tensorflow-io-gcs-filesystem 0.26.0
termcolor                    1.1.0
terminado                    0.15.0
text-unidecode               1.3
threadpoolctl                3.1.0
tifffile                     2022.5.4
tinycss2                     1.1.1
toml                         0.10.2
tomlkit                      0.7.2
toolz                        0.11.2
torch                        1.11.0
torchvision                  0.12.0
tornado                      6.1
tqdm                         4.64.0
traitlets                    5.2.1.post0
Twisted                      18.9.0
typing-extensions            3.10.0.0
tzdata                       2022.1
tzlocal                      3.0
ubuntu-advantage-tools       27.8
ufw                          0.36
unattended-upgrades          0.1
urllib3                      1.25.8
validators                   0.19.0
wadllib                      1.3.3
watchdog                     2.1.2
wcwidth                      0.2.5
webencodings                 0.5.1
websocket-client             1.3.2
Werkzeug                     1.0.1
wheel                        0.34.2
widgetsnbextension           3.6.0
wrapt                        1.14.1
zipp                         1.0.0
zope.interface               4.7.1

root@felipe:~/masseyhacksvii#

stanleyjzheng commented 2 years ago

Apologies, this was a hackathon project that I never bothered to document well; it can be run with streamlit run my_st.py

johnfelipe commented 2 years ago
ImportError: initialization failed
Traceback:
File "/usr/local/lib/python3.8/dist-packages/streamlit/scriptrunner/script_runner.py", line 475, in _run_script
    exec(code, module.__dict__)
File "/root/masseyhacksvii/my_st.py", line 2, in <module>
    from src.skin_color import estimate_skin
File "/root/masseyhacksvii/src/skin_color.py", line 3, in <module>
    from deepface import DeepFace
File "/usr/local/lib/python3.8/dist-packages/deepface/DeepFace.py", line 16, in <module>
    from deepface.basemodels import VGGFace, OpenFace, Facenet, Facenet512, FbDeepFace, DeepID, DlibWrapper, ArcFace, Boosting, SFaceWrapper
File "/usr/local/lib/python3.8/dist-packages/deepface/basemodels/VGGFace.py", line 5, in <module>
    from deepface.commons import functions
File "/usr/local/lib/python3.8/dist-packages/deepface/commons/functions.py", line 12, in <module>
    import tensorflow as tf
File "/usr/local/lib/python3.8/dist-packages/tensorflow/__init__.py", line 37, in <module>
    from tensorflow.python.tools import module_util as _module_util
File "/usr/local/lib/python3.8/dist-packages/tensorflow/python/__init__.py", line 37, in <module>
    from tensorflow.python.eager import context
File "/usr/local/lib/python3.8/dist-packages/tensorflow/python/eager/context.py", line 35, in <module>
    from tensorflow.python.client import pywrap_tf_session
File "/usr/local/lib/python3.8/dist-packages/tensorflow/python/client/pywrap_tf_session.py", line 19, in <module>
    from tensorflow.python.client._pywrap_tf_session import *
stanleyjzheng commented 2 years ago

Unfortunately not a problem with the repo - many stackoverflow threads which may help, such as https://stackoverflow.com/questions/64224572/importerror-dll-load-failed-while-importing-pywrap-tensorflow-internala-dynam

johnfelipe commented 2 years ago

with python use?