p2pfl.learning.compression.zlib_strategy moduleΒΆ

Zlib optimization strategy.

class p2pfl.learning.compression.zlib_strategy.ZlibCompressor[source]ΒΆ

Bases: ByteCompressor

Lossless compression strategy using zlib.

See more at: https://github.com/madler/zlib

apply_strategy(data, level=6)[source]ΒΆ

Apply strategy to the parameters.

Return type:

bytes

reverse_strategy(data)[source]ΒΆ

Reverse the strategy.

Return type:

bytes