Skip to content

Commit

Permalink
checkpoint
Browse files Browse the repository at this point in the history
  • Loading branch information
mavaylon1 committed Dec 1, 2023
1 parent 52938c5 commit 1391ebd
Showing 1 changed file with 9 additions and 6 deletions.
15 changes: 9 additions & 6 deletions src/hdmf_zarr/backend.py
Original file line number Diff line number Diff line change
Expand Up @@ -468,13 +468,16 @@ def __open_file_consolidated(self,
synchronizer = None,
storage_options = None):
"""
This method will check to see if the metadata has been consolidated, if so
This method will check to see if the metadata has been consolidated.
If so, use open_consolidated.
"""
try:
temp = os.path.isfile(self.path+'/.zmetadata')
except TypeError:
temp = os.path.isfile(self.path.path+'/.zmetadata')
if temp:
# self.path can be both a string or a one of the `SUPPORTED_ZARR_STORES`.
if isinstance(self.path, str):
path = self.path
else:
path = self.path.path

if os.path.isfile(path+'/.zmetadata'):
return zarr.open_consolidated(store=store,
mode=mode,
synchronizer=synchronizer,
Expand Down

0 comments on commit 1391ebd

Please sign in to comment.