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 nuts was:

1
2
3
4
5
6
7
8
9
$ python main.py
Traceback (most recent call last):
  File "main.py", line 79, in <module>
    from eye import eye
  File "/home/psycho/pupil-shit/pupil/pupil_src/capture/eye.py", line 20, in <module>
    from methods import *
  File "/home/psycho/pupil-shit/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:

1
$ sudo apt-get install openexr