1

I am trying to run a home surveillance program using rasp pi 3 model b i have done: sudo apt-get install python-pip python-opencv successfully but somehow stuck below:

root@raspberrypi:/home/pi/Downloads/pi-home-surveillance# python pi_surveillance.py 
Traceback (most recent call last):
  File "pi_surveillance.py", line 13, in <module>
    import imutils
ImportError: No module named imutils
root@raspberrypi:/home/pi/Downloads/pi-home-surveillance# pip install imutils
Requirement already satisfied: imutils in /usr/local/lib/python3.4/dist-packages

I have tried reinstalling everything related but to no effect

PS: pip3 was also tried (irrelevant)

root@raspberrypi:/home/pi/Downloads/pi-home-surveillance# pip3 install imutils
Requirement already satisfied: imutils in /usr/local/lib/python3.4/dist-packages
0

3 Answers 3

0

The imutils library per the github page is written for "both Python 2.7 and Python 3" so you can copy the file(s) from /usr/local/lib/python3.4/dist-packages to /usr/local/lib/python2.7/dist-packages.

0

Try not use sudo, just type sudo pip install imutils.

I solved this problem using that command

0

This worked for me.

pip install --upgrade imutils

1
  • OP already said that they have tried that command but get an error. Commented Mar 26, 2019 at 16:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.