perturbopy.test_utils.compare_data.h5.equal_values

perturbopy.test_utils.compare_data.h5.equal_values(file1, file2, ig_n_tol)

Checks if two h5 files contain the same hierarchy/groups/datasets

Parameters:
  • file1 (str) – first HDF5 file name

  • file2 (str) – second HDF5 file name

  • ig_n_tol (dict) – dictionary of keywords and tolerances needed to make comparison on files

Returns:

  • equal_values (bool) – boolean specifying if both h5 files contain the same information

  • diff (str) – string which contains the information about the number of failed tests

  • .. note:: – Also, the file {name_of_file}_errors_file.h5 will be generated in case of the fail of some comparisons.