Sheharyar Naseer

LibIlmImf.so.6 missing from OpenCV Project


Last time I mentioned that I was working on a new Hobby Project, Pupil. This was my first time working with Python and OpenCV for that matter.

This project was already getting on my nerves. So many errors, before I even had the chance to touch the code. One error that was driving me crazy was:

$ python main.py
Traceback (most recent call last):
  File "main.py", line 79, in <module>
    from eye import eye
  File "/home/psy/code/pupil/pupil_src/capture/eye.py", line 20, in <module>
    from methods import *
  File "/home/psy/code/pupil/pupil_src/shared_modules/methods.py", line 16, in <module>
    import cv2
ImportError: libIlmImf.so.6: cannot open shared object file: No such file or directory

I googled high and low, looked at the Pupil Google Group, opened up Github Issues. I was the only one getting this error, but why? I had followed the Installation Guide closely, and on three different clean installations of Ubuntu. This was really frustrating.

In the end, it was a friend on Facebook who told me to try working after installing openexr. I did, and problem solved. libIlmImf.so.6 is a package bundled with it.

Anyways, you can do this to make the error go away:

$ sudo apt-get install openexr