Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error running gui_based_control.py #82

Closed
sunshineinsandiego opened this issue May 29, 2023 · 2 comments
Closed

Error running gui_based_control.py #82

sunshineinsandiego opened this issue May 29, 2023 · 2 comments

Comments

@sunshineinsandiego
Copy link

Hi - I am trying to run gui_based_control.py but am receiving the error:

$ python3 gui_based_control.py 
Traceback (most recent call last):
  File "surgical_robotics_challenge/scripts/surgical_robotics_challenge/examples/gui_based_control.py", line 45, in <module>
    from surgical_robotics_challenge.kinematics.psmIK import *
  File "surgical_robotics_challenge/scripts/surgical_robotics_challenge/kinematics/psmIK.py", line 46, in <module>
    from PyKDL import Vector, Rotation, Frame, dot
ModuleNotFoundError: No module named 'PyKDL'

The AMBF simulator is running fine with the suture challenge launch file. But when I try to run gui_based_control.py, I receive that error.

I tried installing to the system:

$ sudo apt-get install python3-pykdl
Reading package lists... Done
Building dependency tree       
Reading state information... Done
python3-pykdl is already the newest version (1.4.0-7ubuntu1).
0 upgraded, 0 newly installed, 0 to remove and 10 not upgraded.

I also re-installed the modules:

$ pip3 install -e .
Obtaining file:///surgical_robotics_challenge/scripts
  Preparing metadata (setup.py) ... done
Installing collected packages: surgical-robotics-challenge
  Attempting uninstall: surgical-robotics-challenge
    Found existing installation: surgical-robotics-challenge 1.0
    Uninstalling surgical-robotics-challenge-1.0:
      Successfully uninstalled surgical-robotics-challenge-1.0
  Running setup.py develop for surgical-robotics-challenge
Successfully installed surgical-robotics-challenge-1.0

And I located the PyKDL shared object file:

/usr/lib/python3/dist-packages$ find -type f -name "PyKDL*.so"
./PyKDL.cpython-38-x86_64-linux-gnu.so

So it exists, but:

$ python3 -c "import PyKDL"
Traceback (most recent call last):
  File "<string>", line 1, in <module>
ModuleNotFoundError: No module named 'PyKDL'

Any thoughts would be appreciated, thanks!

@sunshineinsandiego
Copy link
Author

Ah, this is fixed! Lots of workarounds which I will document later in case anyone also needs help!

@alfassyn
Copy link

Ah, this is fixed! Lots of workarounds which I will document later in case anyone also needs help!

Hi @sunshineinsandiego
How did you resolve the problem of PyKDL? I got the same problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants