Download gz file python






















Thanks — S Andrew. SAndrew The link that Meyi posted shows how to unzip a. Do you actually want to do something else? You mention download - do you mean you want to download the file from some web server? Show 1 more comment. Active Oldest Votes. Improve this answer. Whats its performance compare to native gzip command in shell? Add a comment. Your solution is sub-optimal as you may run into memory issues for large files.

Besides, this is going to be slower than it could be, as you are performing unnecessary decoding. Sign up or log in Sign up using Google.

Sign up using Facebook. Sign up using Email and Password. Post as a guest Name. Email Required, but never shown. The Overflow Blog. Add a comment. Active Oldest Votes.

Improve this answer. Frans Frans 4 4 silver badges 7 7 bronze badges. Sign up or log in Sign up using Google. Sign up using Facebook. Sign up using Email and Password. Post as a guest Name. Email Required, but never shown.

The Overflow Blog. Podcast Who is building clouds for the independent developer? Exploding turkeys and how not to thaw your frozen bird: Top turkey questions GZip application is used for compression and decompression of files. It is a part of GNU project. The gzip data compression algorithm itself is based on zlib module. The gzip module contains definition of GzipFile class along with its methods.

It also caontains convenience function open , compress and decompress. This function opens a gzip-compressed file in binary or text mode and returns a file like object, which may be physical file, a string or byte object.



0コメント

  • 1000 / 1000