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 Jul 18, 2024
1 parent 8de490d commit 076b974
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions ocf_blosc2/ocf_blosc2.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ class Blosc2(Codec):
codec_id = "blosc2"
max_buffer_size = 2**31 - 1

def __init__(self, cname="blosc2", clevel=5): # noqa
def __init__(self, cname="blosc2", clevel=5): # noqa
self.cname = cname
if cname == "zstd":
self._codec = blosc2.Codec.ZSTD
Expand All @@ -32,12 +32,12 @@ def __init__(self, cname="blosc2", clevel=5): # noqa
self.clevel = clevel

def encode(self, buf):
""" Encode method """
"""Encode method"""
buf = ensure_contiguous_ndarray(buf, self.max_buffer_size)
return blosc2.compress(buf, codec=self._codec, clevel=self.clevel)

def decode(self, buf, out=None):
""" Decode method """
"""Decode method"""
buf = ensure_contiguous_ndarray(buf, self.max_buffer_size)
return blosc2.decompress(buf, out)

Expand Down

0 comments on commit 076b974

Please sign in to comment.