Skip to content

Commit

Permalink
Merge dea4fdf into 5d02aa6
Browse files Browse the repository at this point in the history
  • Loading branch information
halehawk committed Jun 2, 2020
2 parents 5d02aa6 + dea4fdf commit 7c5654f
Show file tree
Hide file tree
Showing 58 changed files with 583 additions and 361 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci-osx.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,4 +30,4 @@ jobs:
run: python -m pip list

- name: Run tests
run: pytest -v --pyargs numcodecs
run: pytest -v --pyargs numcodecs
1 change: 1 addition & 0 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ Contents
registry
blosc
lz4
zfpy
zstd
zlib
gzip
Expand Down
2 changes: 2 additions & 0 deletions docs/release.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ Release notes

Upcoming Release
----------------
* The :class:`numcodecs.zfpy.ZFPY` codec is now supported on Python 3.8 if
`zfpy==0.5.5 <https://pypi.org/project/zfpy/>`_ is installed

* Remove LegacyJSON codec.
By :user:`James Bourbeau <jrbourbeau>`, :issue:`226`.
Expand Down
11 changes: 11 additions & 0 deletions docs/zfpy.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
ZFPY
====
.. automodule:: numcodecs.zfpy

.. autoclass:: ZFPY

.. autoattribute:: codec_id
.. automethod:: encode
.. automethod:: decode
.. automethod:: get_config
.. automethod:: from_config
Binary file added fixture/zfpy/array.00.npy
Binary file not shown.
Binary file added fixture/zfpy/array.01.npy
Binary file not shown.
Binary file added fixture/zfpy/array.02.npy
Binary file not shown.
Binary file added fixture/zfpy/array.03.npy
Binary file not shown.
Binary file added fixture/zfpy/array.04.npy
Binary file not shown.
Binary file added fixture/zfpy/array.05.npy
Binary file not shown.
Binary file added fixture/zfpy/array.06.npy
Binary file not shown.
Binary file added fixture/zfpy/array.07.npy
Binary file not shown.
10 changes: 10 additions & 0 deletions fixture/zfpy/codec.00/config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"compression_kwargs": {
"rate": -1
},
"id": "zfpy",
"mode": 2,
"precision": -1,
"rate": -1,
"tolerance": -1
}
Binary file added fixture/zfpy/codec.00/encoded.00.dat
Binary file not shown.
Binary file added fixture/zfpy/codec.00/encoded.01.dat
Binary file not shown.
Binary file added fixture/zfpy/codec.00/encoded.02.dat
Binary file not shown.
Binary file added fixture/zfpy/codec.00/encoded.03.dat
Binary file not shown.
Binary file added fixture/zfpy/codec.00/encoded.04.dat
Binary file not shown.
Binary file added fixture/zfpy/codec.00/encoded.05.dat
Binary file not shown.
Binary file added fixture/zfpy/codec.00/encoded.06.dat
Binary file not shown.
Binary file added fixture/zfpy/codec.00/encoded.07.dat
Binary file not shown.
10 changes: 10 additions & 0 deletions fixture/zfpy/codec.01/config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"compression_kwargs": {
"tolerance": -1
},
"id": "zfpy",
"mode": 4,
"precision": -1,
"rate": -1,
"tolerance": -1
}
Binary file added fixture/zfpy/codec.01/encoded.00.dat
Binary file not shown.
Binary file added fixture/zfpy/codec.01/encoded.01.dat
Binary file not shown.
Binary file added fixture/zfpy/codec.01/encoded.02.dat
Binary file not shown.
Binary file added fixture/zfpy/codec.01/encoded.03.dat
Binary file not shown.
Binary file added fixture/zfpy/codec.01/encoded.04.dat
Binary file not shown.
Binary file added fixture/zfpy/codec.01/encoded.05.dat
Binary file not shown.
Binary file added fixture/zfpy/codec.01/encoded.06.dat
Binary file not shown.
Binary file added fixture/zfpy/codec.01/encoded.07.dat
Binary file not shown.
10 changes: 10 additions & 0 deletions fixture/zfpy/codec.02/config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"compression_kwargs": {
"tolerance": -1
},
"id": "zfpy",
"mode": 4,
"precision": -1,
"rate": -1,
"tolerance": -1
}
Binary file added fixture/zfpy/codec.02/encoded.00.dat
Binary file not shown.
Binary file added fixture/zfpy/codec.02/encoded.01.dat
Binary file not shown.
Binary file added fixture/zfpy/codec.02/encoded.02.dat
Binary file not shown.
Binary file added fixture/zfpy/codec.02/encoded.03.dat
Binary file not shown.
Binary file added fixture/zfpy/codec.02/encoded.04.dat
Binary file not shown.
Binary file added fixture/zfpy/codec.02/encoded.05.dat
Binary file not shown.
Binary file added fixture/zfpy/codec.02/encoded.06.dat
Binary file not shown.
Binary file added fixture/zfpy/codec.02/encoded.07.dat
Binary file not shown.
10 changes: 10 additions & 0 deletions fixture/zfpy/codec.03/config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"compression_kwargs": {
"precision": -1
},
"id": "zfpy",
"mode": 3,
"precision": -1,
"rate": -1,
"tolerance": -1
}
Binary file added fixture/zfpy/codec.03/encoded.00.dat
Binary file not shown.
Binary file added fixture/zfpy/codec.03/encoded.01.dat
Binary file not shown.
Binary file added fixture/zfpy/codec.03/encoded.02.dat
Binary file not shown.
Binary file added fixture/zfpy/codec.03/encoded.03.dat
Binary file not shown.
Binary file added fixture/zfpy/codec.03/encoded.04.dat
Binary file not shown.
Binary file added fixture/zfpy/codec.03/encoded.05.dat
Binary file not shown.
Binary file added fixture/zfpy/codec.03/encoded.06.dat
Binary file not shown.
Binary file added fixture/zfpy/codec.03/encoded.07.dat
Binary file not shown.
9 changes: 7 additions & 2 deletions numcodecs/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
transformation codecs for use in data storage and communication
applications. These include:
* Compression codecs, e.g., Zlib, BZ2, LZMA and Blosc.
* Compression codecs, e.g., Zlib, BZ2, LZMA, ZFPY and Blosc.
* Pre-compression filters, e.g., Delta, Quantize, FixedScaleOffset,
PackBits, Categorize.
* Integrity checks, e.g., CRC32, Adler32.
Expand All @@ -16,7 +16,6 @@
<https://github.com/alimanfoo/numcodecs/issues>`_.
"""

import multiprocessing
import atexit

Expand Down Expand Up @@ -68,6 +67,12 @@
except ImportError: # pragma: no cover
pass

try:
from numcodecs.zfpy import ZFPY
register_codec(ZFPY)
except ImportError: # pragma: no cover
pass

from numcodecs.astype import AsType
register_codec(AsType)

Expand Down

0 comments on commit 7c5654f

Please sign in to comment.