GATB / gatb-core

Core library of the Genome Analysis Toolbox with de-Bruijn graph
https://gatb.inria.fr/software/gatb-core/
63 stars 27 forks source link

missing parts of HDF5 #23

Closed julien-nc closed 4 years ago

julien-nc commented 6 years ago

I'm happily using GATB v1.4.1 for LoRDEC but i'm now annoyed because i can't find H5File::isHdf5 function in included hdf5 lib.

I fought hard to include the libhdf5 from my system (Ubuntu 18.04) but then there's a warning at execution :

Warning! ***HDF5 library version mismatched error***                                                                                                                                                           
The HDF5 header files used to compile this application do not match                                                                                                                                            
the version used by the HDF5 library to which this application is linked.

and i get a (core dumped).

rchikhi commented 6 years ago

Hi, Unfortunately we do not officially support a system's libhdf5, for the reason that not every GATB user has root access on his/her system, and therefore installing libhdf5 would be an extra hassle. My understanding is that isHdf5() function checks whether a file is a valid HDF5 file. Why not just check if the file name ends with ".h5"? If there is a good reason not to do that, we will upgrade/complete libhdf5 in GATB to a newer version. Best, Rayan

julien-nc commented 6 years ago

Thanks for your quick answer !

The reason why i want to check hdf5 files validity is that, when a De Bruijn graph creation is interrupted, the created file is invalid and makes hdf5 crash when my program crash reads it. Some LoRDEC users are experiencing this kind of problem and i would like to prevent it by deleting any invalid hdf5 files and creating a new one.

HDF5 lib is not throwing an exception that i could catch to handle invalid hdf5 file reading.

By the way, i don't mind if the HDF5lib version stays old, i just would like it to include more :wink:

rchikhi commented 5 years ago

hi @eneiluj,

In an effort to not let our issues be unaddressed for more than 1 year, here is a fix :) I've updated gatb-core to use the latest HDF5 version (1.10.5). Sorry for the delay, and please let me know if you run into problems with this update.

Rayan