Skip to content

Commit

Permalink
refactor(python): Default to zstd parquet compression (#5060)
Browse files Browse the repository at this point in the history
  • Loading branch information
ritchie46 committed Oct 1, 2022
1 parent 25fef75 commit 1968f3f
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions py-polars/polars/internals/dataframe/frame.py
Original file line number Diff line number Diff line change
Expand Up @@ -2066,7 +2066,7 @@ def write_parquet(
self,
file: str | Path | BytesIO,
*,
compression: ParquetCompression = "lz4",
compression: ParquetCompression = "zstd",
compression_level: int | None = None,
statistics: bool = False,
row_group_size: int | None = None,
Expand All @@ -2081,9 +2081,10 @@ def write_parquet(
file
File path to which the file should be written.
compression : {'lz4', 'uncompressed', 'snappy', 'gzip', 'lzo', 'brotli', 'zstd'}
Compression method. The default compression "lz4" (actually lz4raw) has very
good performance, but may not yet been supported by older readers. If you
want more compatibility guarantees, consider using "snappy".
Choose "zstd" for good compression performance.
Choose "lz4" for fast compression/decompression.
Choose "snappy" for more backwards compatibility guarantees
when you deal with older parquet readers.
Method "uncompressed" is not supported by pyarrow.
compression_level
The level of compression to use. Higher compression means smaller files on
Expand Down

0 comments on commit 1968f3f

Please sign in to comment.