Pyinsane example fails with "no module named src.abstract"

666 views Asked by At

I am using the pyinsane module, and after running sudo pip install pyinsane, I believed that pyinsane was up and running. After testing this example with:

python /home/administrator/Documents/git-repositories/ramrod/code/main.py /home/administrator/Documents/git-repositories/ramrod/code/test.jpeg

I got this:

Traceback (most recent call last):
  File "/home/administrator/Documents/git-repositories/ramrod/code/main.py", line 7, in <module>
import src.abstract as pyinsane
ImportError: No module named src.abstract

Code:

#!/usr/bin/env python

import sys

from PIL import Image

import src.abstract as pyinsane

(There is more code to follow but it is unnecessary to reproduce the issue. All I am looking for is getting rid of this error.)

1

There are 1 answers

0
Padraic Cunningham On BEST ANSWER

Use import pyinsane.abstract as pyinsane, the src module does not exist.