openexrpython icon indicating copy to clipboard operation
openexrpython copied to clipboard

Incompatible with OpenEXR 3.0 and Imath 3.0

Open tatue64 opened this issue 4 years ago • 6 comments
trafficstars

It seems that the python bindings are incompatible with changes in the current version OpenExr 3.0 and Imath 3.0, which includes the splitting of Imath into a separate module.

Installing the plugin with pip works without error, but when trying to use it, the imath libraries are not found. Recompiling the plugin form source does not work, because of the changes in the new versions.

This causes problems, for example, in the current version of Manjaro Linux (testing), which installs these new versions. I downgraded to the previous version, but i think the plugin should be updated.

tatue64 avatar May 06 '21 12:05 tatue64

If someone else has the problem, I can recommend OpenImageIO as a replacement. It provides a more high-level python interface that works well with the new versions of OpenEXR and Imath.

tatue64 avatar May 15 '21 07:05 tatue64

How did you downgrade exactly? I tried running

sudo pacman -U /var/cache/pacman/pkg/openexr-2.5.5-1-x86_64.pkg.tar.zst 

but it complains with

error: failed to commit transaction (conflicting files)
openexr: /usr/lib/libImath.so exists in filesystem (owned by imath)
openexr: /usr/lib/python3.9/site-packages/imath.so exists in filesystem (owned by imath)

patzm avatar Jun 18 '21 15:06 patzm

It turned later out that downgrading has too much consequences because in the standard distribution OpenEXR 3.0 is now integrated in many tools people need, who bother for including OpenEXR at all. For example Krita, Blender etc.

I therefore returend to new version of OpenEXR and switched to OpenImageIO for python bindings. I was not aware of this possibility, but in my view it offers superior performance and a more logical python interface. The only drawback from a compatibility perspective is that it is not available via pip (as far as I know).

tatue64 avatar Jun 18 '21 16:06 tatue64

I have a fix for OpenEXR 3.x there: https://github.com/afichet/openexrpython (works for me on Linux with OpenEXR libs from the Arch distro packages)

But, this will most probably break compatibility with systems stuck with OpenEXR 2.x libraries. So I haven't done a merge request for this reason...

afichet avatar Oct 22 '21 16:10 afichet

@afichet Your fork doesn't have an Issues section activated for discussion, would you be open to opening that up to continue discussion on your fork?

meshula avatar Oct 22 '21 16:10 meshula

Ok, that shall be enabled now :-)

afichet avatar Oct 22 '21 16:10 afichet