Skip to content

Compressed files input and output #230

Description

@turicas

There are a lot of use cases which involve storing CSV files compressed since the compression ratio is high, so we can save space. Sometimes we'd like to work directly on compressed files (so decompress on the fly) instead of storing the uncompressed version before working on the data.

Some of the following compression formats are widely used:

  • Gzip: filename.csv.gz
  • XZ: filename.csv.xz
  • LZMA: filename.csv.lzma
  • BZip2: filename.bz2

The Python standard library already provides modules to work with these formats (gzip, lzma and bz2), so we just need some helper functions to use these features easily when importing and exporting data.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions