blosc2.set_compressor#

blosc2.set_compressor(codec: Codec) int#

Set the compressor to be used. If this function is not called, then blosc2.Codec.BLOSCLZ will be used by default.

Parameters:

codec (Codec) – The compressor to be used.

Returns:

out – The code for the compressor (>=0).

Return type:

int

Raises:

ValueError – If the compressor is not recognized or is not supported.

Notes

The compname parameter in python-blosc API has been replaced by codec , using compname as parameter or a string as a codec value will not work.