Skip to content

Commit

Permalink
[pre-commit.ci] auto fixes from pre-commit.com hooks
Browse files Browse the repository at this point in the history
for more information, see https://pre-commit.ci
  • Loading branch information
pre-commit-ci[bot] committed Jun 5, 2024
1 parent 6542999 commit 16608b9
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 5 deletions.
4 changes: 2 additions & 2 deletions ome_zarr/format.py
Original file line number Diff line number Diff line change
Expand Up @@ -360,7 +360,7 @@ def init_store(self, path: str, mode: str = "r") -> FSStore:

cls = LocalStore
kwargs = {}

if path.startswith(("http", "s3")):
cls = RemoteStore

Expand All @@ -371,6 +371,6 @@ def init_store(self, path: str, mode: str = "r") -> FSStore:
) # TODO: open issue for using Path
LOGGER.debug("Created v0.5 store %s(%s, %s, %s)", cls, path, mode, kwargs)
return store


CurrentFormat = FormatV05
4 changes: 2 additions & 2 deletions ome_zarr/io.py
Original file line number Diff line number Diff line change
Expand Up @@ -168,9 +168,9 @@ async def get_json(self, subpath: str) -> JSONDict:
All other exceptions log at the ERROR level.
"""
try:
print('get_json', subpath)
print("get_json", subpath)
data = await self.__store.get(subpath)
print('data', data)
print("data", data)

if not data:
return {}
Expand Down
8 changes: 7 additions & 1 deletion ome_zarr/writer.py
Original file line number Diff line number Diff line change
Expand Up @@ -265,7 +265,13 @@ def write_multiscale(

else:
# We create the array and write data to it immediately...
a = group.create_array(str(path), chunks=chunks_opt, shape=data.shape, dtype=data.dtype, **options)
a = group.create_array(
str(path),
chunks=chunks_opt,
shape=data.shape,
dtype=data.dtype,
**options,
)
# These 2 lines are equivalent to e.g. a[:,:] = data (for any number of dimensions)
s = [np.s_[:]] * len(data.shape)
a[tuple(s)] = data
Expand Down

0 comments on commit 16608b9

Please sign in to comment.