Numcodecs implementation of FLAC audio codec.
Project description
FLAC - numcodecs implementation
Numcodecs wrapper to the FLAC audio codec using pyFLAC.
This implementation enables one to use FLAC as a compressor in Zarr.
Installation
Install via pip
:
pip install flac-numcodecs
Or from sources:
git clone https://github.com/AllenNeuralDynamics/flac-numcodecs.git
cd flac-numcodecs
pip install .
Usage
This is a simple example on how to use the Flac
codec with zarr
:
from flac_numcodecs import Flac
data = ... # any numpy array
# instantiate Flac compressor
flac_compressor = Flac(level=5)
z = zarr.array(data, compressor=flac_compressor)
data_read = z[:]
Available **kwargs
can be browsed with: Flac?
NOTE:
In order to reload in zarr an array saved with the Flac
, you just need to have the flac_numcodecs
package
installed.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
flac_numcodecs-0.1.2.tar.gz
(5.9 kB
view details)
File details
Details for the file flac_numcodecs-0.1.2.tar.gz
.
File metadata
- Download URL: flac_numcodecs-0.1.2.tar.gz
- Upload date:
- Size: 5.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.9.16
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 98c88fe6af6af499866bdad93d96c7a60bb5cf95f6160fe2d410eaf648feb77d |
|
MD5 | 7617886e7c8875875d55eb149d8a3a37 |
|
BLAKE2b-256 | adf50eac341b3d9ca5ea0af4d10f55dbd57148a7da0ea4f28920b3aa4bc5d84f |