Skip to content
Snippets Groups Projects
Commit d9618ed4 authored by Mattia Mancini's avatar Mattia Mancini
Browse files

SSB-44: add checking if the file exists

parent 1216823a
No related branches found
No related tags found
1 merge request!44Merge back holography to master
......@@ -537,6 +537,10 @@ class HolographyDataset():
:return: the read dataset
"""
f = None
if not os.path.exists(path):
raise FileNotFoundError(path)
try:
f = h5py.File(path, "r")
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment