YosefLab/epitome

Bug in parallel_download.py

Closed this issue · 1 comments

Hi folks,

There's a bug in parallel_download.py that is triggered if files that are targeted for downloading already exist. The command
h5_file.close()
should probably be indented so its in scope with the else condition. As written, it can also executed after the first part of the if condition:
if os.path.exists(matrix_path_all):
This execution path produces an error because in that case, the h5_file variable is created with:
h5_file = h5py.File(matrix_path_all, "r")['data']
and is therefore is a Dataset object. Executing this way produces an error because there is no close() function for that variable.

Best regards,
David

Thanks for reporting @DavidQuigley! This is fixed in #96.