pptk
pptk copied to clipboard
pip install pptk doesn't work on ubuntu 18.04/kubuntu 18.04
Problem: After doing 'pip install pptk' on ubuntu/kubuntu 18.04, it doesn't work.
Diagnosis: The 'viewer' doesn't work because the libz.so.1 in site-packages/pptk/libs has some unresolved dependency issue.
Workaround:
- Rename the libz.so.1 in site-packages/pptk/libs
e.g
cd ~/.local/lib/python2.7/site-packages/pptk/libs/
mv libz.so.1 libz.so.1.old
- Create a soft link from /lib/x86_64-linux-gnu/libz.so.1 to the site-packages/pptk/libs
cd ~/.local/lib/python2.7/site-packages/pptk/libs/
sudo ln -s /lib/x86_64-linux-gnu/libz.so.1
hi, I have a similar problem, view
gets stuck, and no output is printed (no error or warning). The above solution didn't work either...
Doesn't work for me either on Debian Buster.
Also tried: ln -s /lib/x86_64-linux-gnu/libz.so.1.2.11 libz.s0.1
pptk doesn't hang anymore but I get no viewer window.
Any news anyone ? I just installed this and on 18.04 also and I have the same problem.
I'll chime in that this was needed (and fixed the problem) for me here as well, but that you obviously have to make sure you're doing it in the site-packages directory for the right version of python - many users now will be running 3.x not 2.7.
Didn’t fix it for me. Already using /lib/x86..
@emantos solution worked for me. thanks.
envs: OS ubuntu18.04 python 3.6 turboVNC
Commenting on behalf of conda/miniconda users:
The correct path to the libz.so.1
you need to change is:
<conda-dir>/envs/<env-name>/lib/python<X>.<Y>/site-packages/pptk/libs/
Or in <conda-dir>/lib/python<X>.<Y>/site-packages/pptk/libs/
if you're running in conda root.
Took me quite a while to figure out;
I kept trying to link the libz.so.1
in <conda-dir>/lib/
and <conda-dir>/envs/<env-name>lib/
...
this works in conda
I get the following error after following @robogast advice : failed to create symbolic link './libz.so.1': File exists
@nihal-rao yeah you should still rename the already present libz.so.1
to something else like libz.so.1.old
as OP states, otherwise the symlinking should obviously not work.
Commenting on behalf of conda/miniconda users: The correct path to the
libz.so.1
you need to change is:<conda-dir>/envs/<env-name>/lib/python<X>.<Y>/site-packages/pptk/libs/
Or in<conda-dir>/lib/python<X>.<Y>/site-packages/pptk/libs/
if you're running in conda root.Took me quite a while to figure out; I kept trying to link the
libz.so.1
in<conda-dir>/lib/
and<conda-dir>/envs/<env-name>lib/
...
This works for me in Conda environment. Thank you.
I solved it in another way.
For conda users:
I modified the file in
<conda-dir>/envs/<env-name>/lib/python<X>.<Y>/site-packages/pptk/viewer/qt.conf
As follows:
[Paths]
Plugins=<conda-dir>/plugins
@emantos Thank you very much! It works for me in python3.6
Problem: After doing 'pip install pptk' on ubuntu/kubuntu 18.04, it doesn't work.
Diagnosis: The 'viewer' doesn't work because the libz.so.1 in site-packages/pptk/libs has some unresolved dependency issue.
Workaround:
- Rename the libz.so.1 in site-packages/pptk/libs e.g
cd ~/.local/lib/python2.7/site-packages/pptk/libs/
mv libz.so.1 libz.so.1.old
- Create a soft link from /lib/x86_64-linux-gnu/libz.so.1 to the site-packages/pptk/libs
cd ~/.local/lib/python2.7/site-packages/pptk/libs/
sudo ln -s /lib/x86_64-linux-gnu/libz.so.1
It works for me in python3.7 and ubuntu 20.04, Thank you!
I'm still running into this issue on RHEL7. I tried the symlink solution with no success. Might be worth noting that I'm doing this with X11 on a remote cluster, but that shouldn't change anything, since I'm positive the X11 part is set up on the system side. Any suggestions?
I'm also running into this problem. But I'm trying to get pptk.viewer()
to send the X11 packets from a docker image to my X server running elsewhere. There are no permissions issues with the port. I've been doing this forever with matplotlib. In fact, I tested plotting just now with plt.plot([1, 2, 3, 4, 5])
and then plt.show()
and it works perfectly. But pptk.viewer()
doesn't. Even with the libz.so.1
fix everyone's talking about.
Thanks
Many thanks
i try it and python2 is ok but python3.6 do not work
Has anyone found a solution for this? I'm trying to use pptk in a docker container. I've tried creating a symlink as suggested but its not working.
I am using WSL2 with Ubuntu 20.04 LTS and after applying libz.so.1 fix, the viewer opens but shows a black/dark screen. Can anyone help me?
2. sudo ln -s /lib/x86_64-linux-gnu/libz.so.1
This solution work for me. Make sure to do it with the correct python. It is for python 2.7. If you use another python for example python 3.6, you should adjust the instruction.
I am using WSL2 with Ubuntu 20.04 LTS and after applying libz.so.1 fix, the viewer opens but shows a black/dark screen. Can anyone help me?
I have the same problem, have you solved the problem?