HDF5 version not match

Hi

I used gpt to process sentinel-3 data,when command run in the CMD, there is no problem.
However, when command run in Anaconda, then it will present following error:


I want to run it in Anaconda, how to slove this problem?

Thank you!

The best solution may be switching to linux. In windows, dynamic libraries are found by searching the PATH, so it not unusual to encounter such conflicts when mixing applications in workflows. Windows was designed to support a model of one massive application that provides everything you use. When you run in an Anaconda environment, the PATH is set to Anaconda directories, so Windows will use Anaconda’s hdf5 library. You might be able to run gpt via a script that resets the PATH to eliminate the Anaconda PATH component, or you could rename the Anaconda hdf5 library while using gpt. In linux, the location of libraries can be set in each program at build time, so applications installed using distro packages will always use their configured library.

For linux, Teradue’s Anaconda repository provides snapista, a Python tool for constructing and running gpt graphs.

2 Likes

Thanks for your help!
Because I am not familiar with Linux, so I solve my problem by uninstall HDF5 and then install HDF5 again, then it work normally now, I don’t know why.

Uninstall and reinstall doesn’t solve the underlying problem of one workflow that has the ability to access two different HDF5 libraries. Windows can distinguish between different versions of the library, so if the second install gave a newer version the conflict may have been removed, but can come back with future updates. If you have multiple DLL’s with the same version, Windows will continue to use the first DLL it finds, so depending on the order in which hdf5 libraries are used, you may still encounter conflicts.

Yes, you are right :sob:
Now I encounter this problem again :joy: :joy: :joy:
So the best solution is still switch to linux?

If you are already familiar with linux it is probably the easiest way out of the bind. Sticking with Windows may be possible if you can redesign the workflow to avoid using hdf5 libraries with multiple applications that use different C runtimes. One way to do that is run different processing steps and applications on different PC’s (or even reboot one PC between steps).

Thank you very much!
Now I divided my code into two parts, one part need gpt to process images then I run it in CMD. Second part have to import gdal,I run it switch to anaconda. Then the HDF5 error is not present now.

Glad you found a workaround.