Import DLC error, ubuntu16, Python 3.6.8

Hi DeepLabCutters,
I am trying to import DLC in Ubuntu GPU env. Once I enter ipython and import deeplabcut, I get this error:

ImportError Traceback (most recent call last)
in
----> 1 import deeplabcut

~/anaconda3/envs/dlc-ubuntu-GPU/lib/python3.6/site-packages/deeplabcut/init.py in
27 else:
28 mpl.use(‘Agg’)
—> 29 from deeplabcut import generate_training_dataset
30 from deeplabcut import refine_training_dataset
31 from deeplabcut.generate_training_dataset import label_frames, dropannotationfileentriesduetodeletedimages, comparevideolistsanddatafolders, dropimagesduetolackofannotation

~/anaconda3/envs/dlc-ubuntu-GPU/lib/python3.6/site-packages/deeplabcut/generate_training_dataset/init.py in
16 pass
17 else:
—> 18 from deeplabcut.generate_training_dataset.auxfun_drag_label import *
19 from deeplabcut.generate_training_dataset.labeling_toolbox import *
20 from deeplabcut.generate_training_dataset.multiple_individual_labeling_toolbox import *

~/anaconda3/envs/dlc-ubuntu-GPU/lib/python3.6/site-packages/deeplabcut/generate_training_dataset/auxfun_drag_label.py in
17
18 import numpy as np
—> 19 import wx
20
21 class DraggablePoint:

~/anaconda3/envs/dlc-ubuntu-GPU/lib/python3.6/site-packages/wx/init.py in
15 # Import all items from the core wxPython module so they appear in the wx
16 # package namespace.
—> 17 from wx.core import *
18
19

~/anaconda3/envs/dlc-ubuntu-GPU/lib/python3.6/site-packages/wx/core.py in
10 “”"
11
—> 12 from ._core import *
13
14 #-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

ImportError: libpython3.6m.so.1.0: cannot open shared object file: No such file or directory

I tried to do this in terminal but cannot install libpython3.6:
sudo apt-get install libpython3.6
Reading package lists… Done
Building dependency tree
Reading state information… Done
E: Unable to locate package libpython3.6
E: Couldn’t find any package by glob ‘libpython3.6’
E: Couldn’t find any package by regex ‘libpython3.6’

Any help?

Thanks

can you import wxpython directly? You may want to check you have the correct version installed. namely, it varies between Ubtunu 16.04 LTS and 18.04 LTS

if you cannot import it, re-install wxpython:

18.04:

https://extras.wxpython.org/wxPython4/extras/linux/gtk3/ubuntu-18.04/wxPython-4.0.3-cp36-cp36m-linux_x86_64.whl

16.04:

https://extras.wxpython.org/wxPython4/extras/linux/gtk3/ubuntu-16.04/wxPython-4.0.3-cp36-cp36m-linux_x86_64.whl

Thanks for the reply. I re-installed it, but I get the same error.
Also my graphics card is not Nvidia. Does DLC only work with Nvidia?

Crrect, DLC only supports nvidia, as we use CUDA https://github.com/AlexEMG/DeepLabCut/wiki/FAQ

Great, thanks. I appreciate your help.
I think I may have also made a mistake by installing GPU version of Ubuntu 18, but I use Ubuntu 16 for which there is no GPU version of DLC. That probably explains the error. I am going to read the faqs and the paper again.

Without Nvidia, would I be able to run it on Google collab?
Thanks

no problem. you can edit the yaml file, it’s just the wxpython part that is version specific, otherwise it’s the same. You can use colab, yes!

1 Like