I have started working on Leap Motion Controller and when trying to execute my code I get this error:
ImportError: No module named Leap
I have added the path to the required libraries
import sys
sys.path.append("usr/lib/Leap:/path/to/lib/x86:/path/to/lib")
import thread, time
from Leap import CircleGesture, KeyTapGesture, ScreenTapGesture, SwipeGesture
What am I doing wrong?
I am working on a Linux platform: Ubuntu 13.10, 32-bit
You can't append a colon separated path list like this, as Python's sys.path
stores the path entries an a list, and not a colon separated list. Each folder needs to be appended separately. Also, usr/lib/Leap
looks to be missing the leading slash.
Something like this should work:
sys.path.append("/usr/lib/Leap")
sys.path.append("/path/to/lib/x86")
sys.path.append("/path/to/lib")
Or this:
sys.path += ["/usr/lib/Leap", "/path/to/lib/x86", "/path/to/lib"]
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With