lzma

Installing/compiling pylzma (lzma python binding)

 ̄綄美尐妖づ 提交于 2019-12-06 05:31:57
I've already posted this question on the authors website , but I thought I might ask here as well. I've been trying to install pylzma with this setup: Windows 7 x64 Python 2.6.6 x64 the amd64 compiler coming from windows server 2003 sdk cloned the git repo git://github.com/fancycode/pylzma.git With a simple easy_install pylzma I got this: cl : Command line warning D9025 : overriding '/MD' with '/MT' pylzma.c src/pylzma/pylzma.c(85) : warning C4244: '=' : conversion from 'Py_ssize_t' to 'int', possible loss of data src/pylzma/pylzma.c(102) : error C2275: 'CSha256' : illegal use of this type as

How to compress a Folder uses lzma sdk?

最后都变了- 提交于 2019-12-06 04:22:45
http://www.7-zip.org/sdk.html I can uses it compress a file, but can not find function of compress a Folder Arnaud Bouchez You'll have to create a .7z archive, then include all files of the folder within. There is no direct "folder" compression: just compression of files. If you store a (relative) folder name within the file name (e.g. 'FolderName\FileName'), the folder 'FolderName' will appear within the archive. You have within the SDK a ANSI-C compatible source code for 7z decompression with example. You'll have to adapt it to add all files of the folder to the archive (using FindFirst /

Python decompression relative performance?

和自甴很熟 提交于 2019-12-04 09:24:31
TLDR; Of the various compression algorithms available in python gzip , bz2 , lzma , etc, which has the best decompression performance? Full discussion: Python 3 has various modules for compressing/decompressing data including gzip , bz2 and lzma . gzip and bz2 additionally have different compression levels you can set. If my goal is to balance file size (/compression ratio) and decompression speed (compression speed is not a concern), which is going to be the best choice? Decompression speed is more important than file size, but as the uncompressed files in question would be around 600-800MB

Decompress and read Dukascopy .bi5 tick files

删除回忆录丶 提交于 2019-12-04 06:24:34
I need to open a .bi5 file and read the contents to cut a long story short. The problem: I have tens of thousands of .bi5 files containing time-series data that I need to decompress and process (read, dump into pandas). I ended up installing Python 3 (I use 2.7 normally) specifically for the lzma library, as I ran into compiling nightmares using the lzma back-ports for Python 2.7, so I conceded and ran with Python 3, but with no success. The problems are too numerous to divulge, no one reads long questions! I have included one of the .bi5 files, if someone could manage to get it into a Pandas

Delphi LZMA Decompression sample

旧巷老猫 提交于 2019-12-02 17:43:20
问题 I found in this thread link of the delphi-zip library that has implementation of LZMA. But I can't make proper use of Decompression from it. Can some one write a little decompression sample for me, using this library? Here is my code, it works for compression but didn't work for decompression and return 0 size uses System.Zip.LZMA; .... procedure TForm2.CompressProgress(Sender: TObject; const aPosition, aSize, aCompressedSize: UInt64); begin end; procedure TForm2.DecompressProgress(Sender:

Delphi LZMA Decompression sample

£可爱£侵袭症+ 提交于 2019-12-02 09:46:31
I found in this thread link of the delphi-zip library that has implementation of LZMA. But I can't make proper use of Decompression from it. Can some one write a little decompression sample for me, using this library? Here is my code, it works for compression but didn't work for decompression and return 0 size uses System.Zip.LZMA; .... procedure TForm2.CompressProgress(Sender: TObject; const aPosition, aSize, aCompressedSize: UInt64); begin end; procedure TForm2.DecompressProgress(Sender: TObject; const aPosition, aSize: UInt64); begin end; procedure TForm2.CompressButton1Click(Sender:

What is the difference between incremental and one-shot compression?

爱⌒轻易说出口 提交于 2019-12-01 11:13:46
I am trying to use the bz2 and/or lzma packages in python. I am trying to compress a database dump in csv format and then put it to a zip file. I got it to work with one-shot compression with both the packages. Code for which looks like this: with ZipFile('something.zip', 'w') as zf: content = bz2.compress(bytes(csv_string, 'UTF-8')) # also with lzma zf.writestr( 'something.csv' + '.bz2', content, compress_type=ZIP_DEFLATED ) When I try to use incremental compression then it creates a .zip file which when I try to extract keeps giving some archive file recursively. Code for which looks like

What is the difference between incremental and one-shot compression?

和自甴很熟 提交于 2019-12-01 08:00:41
问题 I am trying to use the bz2 and/or lzma packages in python. I am trying to compress a database dump in csv format and then put it to a zip file. I got it to work with one-shot compression with both the packages. Code for which looks like this: with ZipFile('something.zip', 'w') as zf: content = bz2.compress(bytes(csv_string, 'UTF-8')) # also with lzma zf.writestr( 'something.csv' + '.bz2', content, compress_type=ZIP_DEFLATED ) When I try to use incremental compression then it creates a .zip

LZMA Or 7zip in Delphi

纵然是瞬间 提交于 2019-12-01 06:30:52
Is there any Library in Delphi to handle LZMA (or 7zip)files including creating self extracting EXEs There are some sources code at 7zip.org in (c++ java c#) but i want them in delphi BUT i want something which is stand alone (No DLLs) there are two solutions: 1) use the into native pascal translated sdk: Pascal LZMA SDK Source Download 2) you can compile the c version of the sdk into obj files and link them to your delphi project. this one requires a translation of the header files to delphi and it requires lots of c knowledge. LZMA SDK Inno setup have delphi source code to encode and decode

Python 2.7: Compressing data with the XZ format using the “lzma” module

落花浮王杯 提交于 2019-12-01 05:48:51
I'm experimenting with the lzma module in Python 2.7.6 to see if I could create compressed files using the XZ format for a future project that will make use of it. My code used during the experiment was: import lzma as xz in_file = open('/home/ki2ne/Desktop/song.wav', 'rb') input_data = in_file.read() compressed_data = xz.compress(input_data) out_file = open('/home/ki2ne/Desktop/song.wav.xz', 'wb') in_file.close() out_file.close() and I noticed there were two different checksums (MD5 and SHA256) from the resulting file compared to when I used the plain xz (although I could decompress fine with