Skip to content

I cant find how to set a compression level in python API #571

Answered by miurahr
vgdh asked this question in Q&A
Discussion options

You must be logged in to vote

You can see the Python standard manual for reference of LZMA/LZMA2 compression filters.
https://docs.python.org/3/library/lzma.html#specifying-custom-filter-chains

Here is an example tin standard manual to set compression level.

my_filters = [
    {"id": lzma.FILTER_DELTA, "dist": 5},
    {"id": lzma.FILTER_LZMA2, "preset": 7 | lzma.PRESET_EXTREME},
]

Here is an example in py7zr manual

https://py7zr.readthedocs.io/en/latest/api.html#possible-filters-value

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Answer selected by vgdh
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
question Further information is requested documentation Issue on documentation
2 participants
Converted from issue

This discussion was converted from issue #356 on January 30, 2024 23:01.