@gmod/cram 3.0.7 → 4.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/craiIndex.js +70 -87
- package/dist/craiIndex.js.map +1 -1
- package/dist/cram-bundle.js +1 -1
- package/dist/cramFile/codecs/_base.d.ts +1 -1
- package/dist/cramFile/codecs/beta.d.ts +2 -2
- package/dist/cramFile/codecs/beta.js +1 -1
- package/dist/cramFile/codecs/beta.js.map +1 -1
- package/dist/cramFile/codecs/byteArrayLength.d.ts +2 -2
- package/dist/cramFile/codecs/byteArrayStop.d.ts +4 -4
- package/dist/cramFile/codecs/byteArrayStop.js +1 -1
- package/dist/cramFile/codecs/byteArrayStop.js.map +1 -1
- package/dist/cramFile/codecs/external.d.ts +1 -1
- package/dist/cramFile/codecs/external.js +1 -1
- package/dist/cramFile/codecs/external.js.map +1 -1
- package/dist/cramFile/codecs/gamma.d.ts +1 -1
- package/dist/cramFile/codecs/gamma.js +1 -1
- package/dist/cramFile/codecs/gamma.js.map +1 -1
- package/dist/cramFile/codecs/getBits.d.ts +1 -1
- package/dist/cramFile/codecs/getBits.js.map +1 -1
- package/dist/cramFile/codecs/huffman.d.ts +1 -1
- package/dist/cramFile/codecs/huffman.js +1 -1
- package/dist/cramFile/codecs/huffman.js.map +1 -1
- package/dist/cramFile/codecs/index.d.ts +1 -1
- package/dist/cramFile/codecs/index.js +5 -5
- package/dist/cramFile/codecs/index.js.map +1 -1
- package/dist/cramFile/codecs/subexp.d.ts +2 -2
- package/dist/cramFile/codecs/subexp.js +1 -1
- package/dist/cramFile/codecs/subexp.js.map +1 -1
- package/dist/cramFile/container/compressionScheme.d.ts +2 -2
- package/dist/cramFile/container/compressionScheme.js +1 -1
- package/dist/cramFile/container/compressionScheme.js.map +1 -1
- package/dist/cramFile/container/index.d.ts +1 -2
- package/dist/cramFile/container/index.js +62 -79
- package/dist/cramFile/container/index.js.map +1 -1
- package/dist/cramFile/file.d.ts +9 -13
- package/dist/cramFile/file.js +218 -247
- package/dist/cramFile/file.js.map +1 -1
- package/dist/cramFile/record.js +2 -2
- package/dist/cramFile/record.js.map +1 -1
- package/dist/cramFile/sectionParsers.d.ts +16 -16
- package/dist/cramFile/sectionParsers.js +12 -9
- package/dist/cramFile/sectionParsers.js.map +1 -1
- package/dist/cramFile/slice/decodeRecord.d.ts +3 -3
- package/dist/cramFile/slice/decodeRecord.js +11 -11
- package/dist/cramFile/slice/decodeRecord.js.map +1 -1
- package/dist/cramFile/slice/index.d.ts +2 -2
- package/dist/cramFile/slice/index.js +241 -262
- package/dist/cramFile/slice/index.js.map +1 -1
- package/dist/cramFile/util.d.ts +4 -2
- package/dist/cramFile/util.js +29 -6
- package/dist/cramFile/util.js.map +1 -1
- package/dist/htscodecs/arith_gen.d.ts +9 -17
- package/dist/htscodecs/arith_gen.js +32 -272
- package/dist/htscodecs/arith_gen.js.map +1 -1
- package/dist/htscodecs/fqzcomp.d.ts +1 -2
- package/dist/htscodecs/fqzcomp.js +2 -421
- package/dist/htscodecs/fqzcomp.js.map +1 -1
- package/dist/htscodecs/index.d.ts +5 -5
- package/dist/htscodecs/index.js +10 -10
- package/dist/htscodecs/index.js.map +1 -1
- package/dist/htscodecs/iostream.d.ts +2 -1
- package/dist/htscodecs/iostream.js +3 -2
- package/dist/htscodecs/iostream.js.map +1 -1
- package/dist/htscodecs/rans.d.ts +1 -2
- package/dist/htscodecs/rans.js +3 -270
- package/dist/htscodecs/rans.js.map +1 -1
- package/dist/htscodecs/rans4x16.d.ts +0 -1
- package/dist/htscodecs/rans4x16.js +6 -497
- package/dist/htscodecs/rans4x16.js.map +1 -1
- package/dist/htscodecs/tok3.js +17 -1
- package/dist/htscodecs/tok3.js.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +2 -2
- package/dist/index.js.map +1 -1
- package/dist/indexedCramFile.d.ts +4 -4
- package/dist/indexedCramFile.js +97 -108
- package/dist/indexedCramFile.js.map +1 -1
- package/dist/io/index.d.ts +2 -2
- package/dist/io/index.js +6 -6
- package/dist/io/index.js.map +1 -1
- package/dist/rans/constants.d.ts +1 -1
- package/dist/rans/constants.js +1 -1
- package/dist/rans/constants.js.map +1 -1
- package/dist/rans/d04.js.map +1 -1
- package/dist/rans/decoding.js.map +1 -1
- package/dist/rans/frequencies.js.map +1 -1
- package/dist/rans/index.js +5 -5
- package/dist/rans/index.js.map +1 -1
- package/dist/unzip.d.ts +1 -1
- package/dist/unzip.js +5 -3
- package/dist/unzip.js.map +1 -1
- package/esm/craiIndex.js +10 -12
- package/esm/craiIndex.js.map +1 -1
- package/esm/cramFile/codecs/_base.d.ts +1 -1
- package/esm/cramFile/codecs/beta.d.ts +2 -2
- package/esm/cramFile/codecs/beta.js +1 -1
- package/esm/cramFile/codecs/beta.js.map +1 -1
- package/esm/cramFile/codecs/byteArrayLength.d.ts +2 -2
- package/esm/cramFile/codecs/byteArrayStop.d.ts +4 -4
- package/esm/cramFile/codecs/byteArrayStop.js +1 -1
- package/esm/cramFile/codecs/byteArrayStop.js.map +1 -1
- package/esm/cramFile/codecs/external.d.ts +1 -1
- package/esm/cramFile/codecs/external.js +1 -1
- package/esm/cramFile/codecs/external.js.map +1 -1
- package/esm/cramFile/codecs/gamma.d.ts +1 -1
- package/esm/cramFile/codecs/gamma.js +1 -1
- package/esm/cramFile/codecs/gamma.js.map +1 -1
- package/esm/cramFile/codecs/getBits.d.ts +1 -1
- package/esm/cramFile/codecs/getBits.js.map +1 -1
- package/esm/cramFile/codecs/huffman.d.ts +1 -1
- package/esm/cramFile/codecs/huffman.js +1 -1
- package/esm/cramFile/codecs/huffman.js.map +1 -1
- package/esm/cramFile/codecs/index.d.ts +1 -1
- package/esm/cramFile/codecs/index.js +5 -5
- package/esm/cramFile/codecs/index.js.map +1 -1
- package/esm/cramFile/codecs/subexp.d.ts +2 -2
- package/esm/cramFile/codecs/subexp.js +1 -1
- package/esm/cramFile/codecs/subexp.js.map +1 -1
- package/esm/cramFile/container/compressionScheme.d.ts +2 -2
- package/esm/cramFile/container/compressionScheme.js +1 -1
- package/esm/cramFile/container/compressionScheme.js.map +1 -1
- package/esm/cramFile/container/index.d.ts +1 -2
- package/esm/cramFile/container/index.js +4 -7
- package/esm/cramFile/container/index.js.map +1 -1
- package/esm/cramFile/file.d.ts +9 -13
- package/esm/cramFile/file.js +47 -52
- package/esm/cramFile/file.js.map +1 -1
- package/esm/cramFile/record.js +2 -2
- package/esm/cramFile/record.js.map +1 -1
- package/esm/cramFile/sectionParsers.d.ts +16 -16
- package/esm/cramFile/sectionParsers.js +7 -7
- package/esm/cramFile/sectionParsers.js.map +1 -1
- package/esm/cramFile/slice/decodeRecord.d.ts +3 -3
- package/esm/cramFile/slice/decodeRecord.js +11 -11
- package/esm/cramFile/slice/decodeRecord.js.map +1 -1
- package/esm/cramFile/slice/index.d.ts +2 -2
- package/esm/cramFile/slice/index.js +7 -6
- package/esm/cramFile/slice/index.js.map +1 -1
- package/esm/cramFile/util.d.ts +4 -2
- package/esm/cramFile/util.js +19 -2
- package/esm/cramFile/util.js.map +1 -1
- package/esm/htscodecs/arith_gen.d.ts +9 -17
- package/esm/htscodecs/arith_gen.js +32 -272
- package/esm/htscodecs/arith_gen.js.map +1 -1
- package/esm/htscodecs/fqzcomp.d.ts +1 -2
- package/esm/htscodecs/fqzcomp.js +2 -421
- package/esm/htscodecs/fqzcomp.js.map +1 -1
- package/esm/htscodecs/index.d.ts +5 -5
- package/esm/htscodecs/index.js +10 -10
- package/esm/htscodecs/index.js.map +1 -1
- package/esm/htscodecs/iostream.d.ts +2 -1
- package/esm/htscodecs/iostream.js +3 -2
- package/esm/htscodecs/iostream.js.map +1 -1
- package/esm/htscodecs/rans.d.ts +1 -2
- package/esm/htscodecs/rans.js +3 -270
- package/esm/htscodecs/rans.js.map +1 -1
- package/esm/htscodecs/rans4x16.d.ts +0 -1
- package/esm/htscodecs/rans4x16.js +6 -497
- package/esm/htscodecs/rans4x16.js.map +1 -1
- package/esm/htscodecs/tok3.js +17 -1
- package/esm/htscodecs/tok3.js.map +1 -1
- package/esm/index.d.ts +1 -1
- package/esm/index.js +1 -1
- package/esm/index.js.map +1 -1
- package/esm/indexedCramFile.d.ts +4 -4
- package/esm/indexedCramFile.js +10 -10
- package/esm/indexedCramFile.js.map +1 -1
- package/esm/io/index.d.ts +2 -2
- package/esm/io/index.js +1 -1
- package/esm/io/index.js.map +1 -1
- package/esm/rans/constants.d.ts +1 -1
- package/esm/rans/constants.js +1 -1
- package/esm/rans/constants.js.map +1 -1
- package/esm/rans/d04.js.map +1 -1
- package/esm/rans/decoding.js.map +1 -1
- package/esm/rans/frequencies.js.map +1 -1
- package/esm/rans/index.js +5 -5
- package/esm/rans/index.js.map +1 -1
- package/esm/unzip.d.ts +1 -1
- package/esm/unzip.js +4 -1
- package/esm/unzip.js.map +1 -1
- package/package.json +7 -9
- package/src/craiIndex.ts +17 -16
- package/src/cramFile/codecs/_base.ts +1 -1
- package/src/cramFile/codecs/beta.ts +3 -3
- package/src/cramFile/codecs/byteArrayLength.ts +1 -1
- package/src/cramFile/codecs/byteArrayStop.ts +3 -4
- package/src/cramFile/codecs/external.ts +3 -3
- package/src/cramFile/codecs/gamma.ts +2 -2
- package/src/cramFile/codecs/getBits.ts +1 -1
- package/src/cramFile/codecs/huffman.ts +2 -3
- package/src/cramFile/codecs/index.ts +7 -8
- package/src/cramFile/codecs/subexp.ts +3 -3
- package/src/cramFile/container/compressionScheme.ts +3 -3
- package/src/cramFile/container/index.ts +7 -10
- package/src/cramFile/file.ts +71 -77
- package/src/cramFile/record.ts +3 -3
- package/src/cramFile/sectionParsers.ts +27 -22
- package/src/cramFile/slice/decodeRecord.ts +17 -17
- package/src/cramFile/slice/index.ts +8 -9
- package/src/cramFile/util.ts +24 -5
- package/src/htscodecs/arith_gen.js +33 -296
- package/src/htscodecs/fqzcomp.js +2 -476
- package/src/htscodecs/index.js +9 -11
- package/src/htscodecs/iostream.js +3 -2
- package/src/htscodecs/rans.js +3 -315
- package/src/htscodecs/rans4x16.js +6 -557
- package/src/htscodecs/tok3.js +18 -1
- package/src/index.ts +1 -1
- package/src/indexedCramFile.ts +6 -5
- package/src/io/index.ts +5 -4
- package/src/rans/constants.ts +1 -1
- package/src/rans/d04.ts +0 -1
- package/src/rans/decoding.ts +0 -1
- package/src/rans/frequencies.ts +0 -1
- package/src/rans/index.ts +5 -7
- package/src/unzip.ts +5 -1
- package/dist/cramFile/filehandle.d.ts +0 -1
- package/dist/cramFile/filehandle.js +0 -3
- package/dist/cramFile/filehandle.js.map +0 -1
- package/dist/htscodecs/main_arith_gen.d.ts +0 -1
- package/dist/htscodecs/main_arith_gen.js +0 -86
- package/dist/htscodecs/main_arith_gen.js.map +0 -1
- package/dist/htscodecs/main_fqzcomp.d.ts +0 -1
- package/dist/htscodecs/main_fqzcomp.js +0 -112
- package/dist/htscodecs/main_fqzcomp.js.map +0 -1
- package/dist/htscodecs/main_rans.d.ts +0 -1
- package/dist/htscodecs/main_rans.js +0 -83
- package/dist/htscodecs/main_rans.js.map +0 -1
- package/dist/htscodecs/main_rans4x16.d.ts +0 -1
- package/dist/htscodecs/main_rans4x16.js +0 -82
- package/dist/htscodecs/main_rans4x16.js.map +0 -1
- package/dist/htscodecs/main_tok3.d.ts +0 -1
- package/dist/htscodecs/main_tok3.js +0 -84
- package/dist/htscodecs/main_tok3.js.map +0 -1
- package/dist/unzip-pako.d.ts +0 -2
- package/dist/unzip-pako.js +0 -9
- package/dist/unzip-pako.js.map +0 -1
- package/esm/cramFile/filehandle.d.ts +0 -1
- package/esm/cramFile/filehandle.js +0 -2
- package/esm/cramFile/filehandle.js.map +0 -1
- package/esm/htscodecs/main_arith_gen.d.ts +0 -1
- package/esm/htscodecs/main_arith_gen.js +0 -86
- package/esm/htscodecs/main_arith_gen.js.map +0 -1
- package/esm/htscodecs/main_fqzcomp.d.ts +0 -1
- package/esm/htscodecs/main_fqzcomp.js +0 -112
- package/esm/htscodecs/main_fqzcomp.js.map +0 -1
- package/esm/htscodecs/main_rans.d.ts +0 -1
- package/esm/htscodecs/main_rans.js +0 -83
- package/esm/htscodecs/main_rans.js.map +0 -1
- package/esm/htscodecs/main_rans4x16.d.ts +0 -1
- package/esm/htscodecs/main_rans4x16.js +0 -82
- package/esm/htscodecs/main_rans4x16.js.map +0 -1
- package/esm/htscodecs/main_tok3.d.ts +0 -1
- package/esm/htscodecs/main_tok3.js +0 -84
- package/esm/htscodecs/main_tok3.js.map +0 -1
- package/esm/unzip-pako.d.ts +0 -2
- package/esm/unzip-pako.js +0 -6
- package/esm/unzip-pako.js.map +0 -1
- package/src/cramFile/filehandle.ts +0 -1
- package/src/htscodecs/Makefile +0 -142
- package/src/htscodecs/README.md +0 -64
- package/src/htscodecs/main_arith_gen.js +0 -96
- package/src/htscodecs/main_fqzcomp.js +0 -113
- package/src/htscodecs/main_rans.js +0 -88
- package/src/htscodecs/main_rans4x16.js +0 -87
- package/src/htscodecs/main_tok3.js +0 -86
- package/src/unzip-pako.ts +0 -6
package/src/htscodecs/README.md
DELETED
|
@@ -1,64 +0,0 @@
|
|
|
1
|
-
# Reference implementation files
|
|
2
|
-
|
|
3
|
-
This directory contains javascript implementations of the custom codecs using in
|
|
4
|
-
CRAM 3.1, capable of being run under node.js.
|
|
5
|
-
|
|
6
|
-
These is not written for speed, but for clarity and as an exercise in checking
|
|
7
|
-
the pseudocode in the CRAM specification. It is written as close to this
|
|
8
|
-
pseudocode as is possible.
|
|
9
|
-
|
|
10
|
-
Prerequisites: minimist package for command line parsing and bzip2 for part of
|
|
11
|
-
the arith_gen.js code.
|
|
12
|
-
|
|
13
|
-
npm install minimist
|
|
14
|
-
npm install bzip2
|
|
15
|
-
|
|
16
|
-
## iostream.js
|
|
17
|
-
|
|
18
|
-
Makes a buffer appear to be a stream with ReadByte, ReadITF8, etc functions.
|
|
19
|
-
|
|
20
|
-
## rans.js
|
|
21
|
-
|
|
22
|
-
Implements the order-0 and order-1 rans (4x8) decoder as used in CRAM3.0.
|
|
23
|
-
|
|
24
|
-
## main_rans.js
|
|
25
|
-
|
|
26
|
-
A command line tool to exercise the rans.js code, included for debug purposes.
|
|
27
|
-
|
|
28
|
-
## rans4x16.js, main_rans4x16.js
|
|
29
|
-
|
|
30
|
-
A 16-bit renormalising variant of rANS above. This also includes transforms for
|
|
31
|
-
RLE, bit-packing and 4-way interleaving.
|
|
32
|
-
|
|
33
|
-
## arith_sh.js
|
|
34
|
-
|
|
35
|
-
Arithmetic (range) coding with Schindler carry handling.
|
|
36
|
-
|
|
37
|
-
## byte_model.js
|
|
38
|
-
|
|
39
|
-
An adaptive model for keeping track of symbol frequencies.
|
|
40
|
-
|
|
41
|
-
## arith_gen.js, main_arith_gen.js
|
|
42
|
-
|
|
43
|
-
Wrapper around arith_sh.js to perform order-0/1 encoding with RLE and
|
|
44
|
-
bit-packing. Plus debug command line tool
|
|
45
|
-
|
|
46
|
-
## fqzcomp.js, main_fqzcomp.js
|
|
47
|
-
|
|
48
|
-
Implements the fqzcomp quality compression codec. Plus debug command line tool.
|
|
49
|
-
|
|
50
|
-
## tok3.js, main_tok3.js
|
|
51
|
-
|
|
52
|
-
Implements the tokenise_name3 read identifier compression codec. Plus debug
|
|
53
|
-
command line tool.
|
|
54
|
-
|
|
55
|
-
# Testing
|
|
56
|
-
|
|
57
|
-
The various main js files can be used for adhoc testing. There is also a
|
|
58
|
-
Makefile which performs checks against known defined data streams and does
|
|
59
|
-
round-trip testing in both Javascript and if compiled the C variant. You can set
|
|
60
|
-
CORPUS make variable to a larger data set such htscodecs-corpus.
|
|
61
|
-
|
|
62
|
-
eg.
|
|
63
|
-
|
|
64
|
-
make check CORPUS=../tests/htscodecs-corpus/
|
|
@@ -1,96 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Copyright (c) 2019,2020 Genome Research Ltd.
|
|
3
|
-
* Author(s): James Bonfield
|
|
4
|
-
*
|
|
5
|
-
* Redistribution and use in source and binary forms, with or without
|
|
6
|
-
* modification, are permitted provided that the following conditions are met:
|
|
7
|
-
*
|
|
8
|
-
* 1. Redistributions of source code must retain the above copyright notice,
|
|
9
|
-
* this list of conditions and the following disclaimer.
|
|
10
|
-
*
|
|
11
|
-
* 2. Redistributions in binary form must reproduce the above
|
|
12
|
-
* copyright notice, this list of conditions and the following
|
|
13
|
-
* disclaimer in the documentation and/or other materials provided
|
|
14
|
-
* with the distribution.
|
|
15
|
-
*
|
|
16
|
-
* 3. Neither the names Genome Research Ltd and Wellcome Trust Sanger
|
|
17
|
-
* Institute nor the names of its contributors may be used to endorse
|
|
18
|
-
* or promote products derived from this software without specific
|
|
19
|
-
* prior written permission.
|
|
20
|
-
*
|
|
21
|
-
* THIS SOFTWARE IS PROVIDED BY GENOME RESEARCH LTD AND CONTRIBUTORS "AS
|
|
22
|
-
* IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
|
|
23
|
-
* TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
|
|
24
|
-
* PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL GENOME RESEARCH
|
|
25
|
-
* LTD OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
|
26
|
-
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
|
27
|
-
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
|
28
|
-
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
|
29
|
-
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
|
30
|
-
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
|
31
|
-
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
32
|
-
*/
|
|
33
|
-
|
|
34
|
-
// Command line tool to manually test the arith_gen.js code.
|
|
35
|
-
|
|
36
|
-
var fs = require('fs')
|
|
37
|
-
var RangeCoderGen = require('./arith_gen')
|
|
38
|
-
|
|
39
|
-
var argv = require('minimist')(process.argv.slice(2), { boolean: ['d', 'r'] })
|
|
40
|
-
|
|
41
|
-
if (argv._.length != 1) {
|
|
42
|
-
process.stderr.write(
|
|
43
|
-
'Usage: node main_arith_gen.js [-d] [-o order] input-file > output-file\n',
|
|
44
|
-
)
|
|
45
|
-
process.exit(1)
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
var filein = argv._[0]
|
|
49
|
-
|
|
50
|
-
var buf = fs.readFileSync(filein)
|
|
51
|
-
var blk_size = 1024 * 1024
|
|
52
|
-
var raw = argv.r
|
|
53
|
-
|
|
54
|
-
var arith = new RangeCoderGen()
|
|
55
|
-
if (!argv.d) {
|
|
56
|
-
var order = argv.o != undefined ? argv.o : 0
|
|
57
|
-
// -o8.4 => 8+(256*4)
|
|
58
|
-
order += Math.round((order - (order >> 0)) * 10) * 256
|
|
59
|
-
var pos = 0
|
|
60
|
-
var out_len = 0
|
|
61
|
-
if (raw) blk_size = buf.length
|
|
62
|
-
while (pos < buf.length) {
|
|
63
|
-
var buf2 = arith.encode(buf.slice(pos, pos + blk_size), order)
|
|
64
|
-
|
|
65
|
-
// Compressed buffer size. Used in multi-block format.
|
|
66
|
-
var csize = new Buffer.allocUnsafe(4)
|
|
67
|
-
if (!raw) {
|
|
68
|
-
csize.writeInt32LE(buf2.length, 0)
|
|
69
|
-
process.stdout.write(csize)
|
|
70
|
-
}
|
|
71
|
-
|
|
72
|
-
// Write compressed buffer itself
|
|
73
|
-
process.stdout.write(buf2)
|
|
74
|
-
|
|
75
|
-
pos += blk_size
|
|
76
|
-
out_len += buf2.length
|
|
77
|
-
}
|
|
78
|
-
process.stderr.write(
|
|
79
|
-
'Compress order ' + order + ', ' + buf.length + ' => ' + out_len + '\n',
|
|
80
|
-
)
|
|
81
|
-
} else {
|
|
82
|
-
var pos = 0
|
|
83
|
-
var out_len = 0
|
|
84
|
-
var len = buf.length
|
|
85
|
-
while (pos < buf.length) {
|
|
86
|
-
if (!raw) {
|
|
87
|
-
len = buf.readInt32LE(pos)
|
|
88
|
-
pos += 4
|
|
89
|
-
}
|
|
90
|
-
var buf2 = arith.decode(buf.slice(pos, pos + len))
|
|
91
|
-
process.stdout.write(buf2)
|
|
92
|
-
out_len += buf2.length
|
|
93
|
-
pos += len
|
|
94
|
-
}
|
|
95
|
-
process.stderr.write('Decompress ' + buf.length + ' => ' + out_len + '\n')
|
|
96
|
-
}
|
|
@@ -1,113 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Copyright (c) 2019,2020 Genome Research Ltd.
|
|
3
|
-
* Author(s): James Bonfield
|
|
4
|
-
*
|
|
5
|
-
* Redistribution and use in source and binary forms, with or without
|
|
6
|
-
* modification, are permitted provided that the following conditions are met:
|
|
7
|
-
*
|
|
8
|
-
* 1. Redistributions of source code must retain the above copyright notice,
|
|
9
|
-
* this list of conditions and the following disclaimer.
|
|
10
|
-
*
|
|
11
|
-
* 2. Redistributions in binary form must reproduce the above
|
|
12
|
-
* copyright notice, this list of conditions and the following
|
|
13
|
-
* disclaimer in the documentation and/or other materials provided
|
|
14
|
-
* with the distribution.
|
|
15
|
-
*
|
|
16
|
-
* 3. Neither the names Genome Research Ltd and Wellcome Trust Sanger
|
|
17
|
-
* Institute nor the names of its contributors may be used to endorse
|
|
18
|
-
* or promote products derived from this software without specific
|
|
19
|
-
* prior written permission.
|
|
20
|
-
*
|
|
21
|
-
* THIS SOFTWARE IS PROVIDED BY GENOME RESEARCH LTD AND CONTRIBUTORS "AS
|
|
22
|
-
* IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
|
|
23
|
-
* TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
|
|
24
|
-
* PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL GENOME RESEARCH
|
|
25
|
-
* LTD OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
|
26
|
-
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
|
27
|
-
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
|
28
|
-
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
|
29
|
-
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
|
30
|
-
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
|
31
|
-
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
32
|
-
*/
|
|
33
|
-
|
|
34
|
-
var fs = require('fs')
|
|
35
|
-
var fqz = require('./fqzcomp')
|
|
36
|
-
var argv = require('minimist')(process.argv.slice(2), { boolean: ['d', 'r'] })
|
|
37
|
-
|
|
38
|
-
if (argv._.length != 1) {
|
|
39
|
-
process.stderr.write(
|
|
40
|
-
'Usage: node main_fqzcomp.js [-d] input-file > output-file\n',
|
|
41
|
-
)
|
|
42
|
-
process.exit(1)
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
var filein = argv._[0]
|
|
46
|
-
|
|
47
|
-
var buf = fs.readFileSync(filein)
|
|
48
|
-
var raw = argv.r
|
|
49
|
-
|
|
50
|
-
if (!argv.d) {
|
|
51
|
-
// Line breaks to get sequence length, but then stitch together into
|
|
52
|
-
// a single non-breaking buffer.
|
|
53
|
-
var len = 0
|
|
54
|
-
var j = 0
|
|
55
|
-
var q_lens = new Array()
|
|
56
|
-
var q_dirs = new Array()
|
|
57
|
-
var q_len = 0
|
|
58
|
-
for (var i = 0; i < buf.length; i++) {
|
|
59
|
-
if (buf[i] == '\n'.charCodeAt(0) || buf[i] == '\t'.charCodeAt(0)) {
|
|
60
|
-
q_lens.push(len)
|
|
61
|
-
if (q_len == 0) q_len = len
|
|
62
|
-
else if (q_len != len) q_len = -1 // marker for multiple lengths
|
|
63
|
-
len = 0
|
|
64
|
-
|
|
65
|
-
if (buf[i] == '\t'.charCodeAt(0)) {
|
|
66
|
-
// parse 2nd token for read1/read2 status
|
|
67
|
-
var dir = ''
|
|
68
|
-
for (i++; i < buf.length && buf[i] != '\n'.charCodeAt(0); i++)
|
|
69
|
-
dir += String.fromCharCode(buf[i])
|
|
70
|
-
q_dirs.push(dir)
|
|
71
|
-
} else {
|
|
72
|
-
q_dirs.push(0)
|
|
73
|
-
}
|
|
74
|
-
} else {
|
|
75
|
-
buf[j++] = buf[i] - 33 // ASCII phred to raw
|
|
76
|
-
len++
|
|
77
|
-
}
|
|
78
|
-
}
|
|
79
|
-
buf = buf.slice(0, j)
|
|
80
|
-
if (q_len > 0) q_lens = [q_lens[0]]
|
|
81
|
-
|
|
82
|
-
var buf2 = fqz.encode(buf, q_lens, q_dirs)
|
|
83
|
-
process.stderr.write('Compress ' + buf.length + ' => ' + buf2.length + '\n')
|
|
84
|
-
if (!raw) {
|
|
85
|
-
var hdr = new Buffer.allocUnsafe(8)
|
|
86
|
-
hdr.writeInt32LE(buf.length, 0)
|
|
87
|
-
hdr.writeInt32LE(buf2.length, 4)
|
|
88
|
-
process.stdout.write(hdr)
|
|
89
|
-
}
|
|
90
|
-
process.stdout.write(buf2)
|
|
91
|
-
} else {
|
|
92
|
-
var q_lens = new Array()
|
|
93
|
-
// Consume ulen and clen from outer test harness (pointless as non-blocking atm)
|
|
94
|
-
var buf2
|
|
95
|
-
if (raw) buf2 = fqz.decode(buf, q_lens)
|
|
96
|
-
else buf2 = fqz.decode(buf.slice(8), q_lens)
|
|
97
|
-
|
|
98
|
-
// Split into newlines so we can do easy data comparison
|
|
99
|
-
var buf3 = new Buffer.allocUnsafe(buf2.length + q_lens.length)
|
|
100
|
-
var rec = 0
|
|
101
|
-
var len = q_lens[rec++]
|
|
102
|
-
var j = 0
|
|
103
|
-
for (var i = 0; i < buf2.length; i++) {
|
|
104
|
-
buf3[j++] = buf2[i] + 33
|
|
105
|
-
if (--len == 0) {
|
|
106
|
-
buf3[j++] = '\n'.charCodeAt(0)
|
|
107
|
-
len = q_lens[rec++]
|
|
108
|
-
}
|
|
109
|
-
}
|
|
110
|
-
|
|
111
|
-
process.stderr.write('Decompress ' + buf.length + ' => ' + buf3.length + '\n')
|
|
112
|
-
process.stdout.write(buf3)
|
|
113
|
-
}
|
|
@@ -1,88 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Copyright (c) 2019-2020 Genome Research Ltd.
|
|
3
|
-
* Author(s): James Bonfield
|
|
4
|
-
*
|
|
5
|
-
* Redistribution and use in source and binary forms, with or without
|
|
6
|
-
* modification, are permitted provided that the following conditions are met:
|
|
7
|
-
*
|
|
8
|
-
* 1. Redistributions of source code must retain the above copyright notice,
|
|
9
|
-
* this list of conditions and the following disclaimer.
|
|
10
|
-
*
|
|
11
|
-
* 2. Redistributions in binary form must reproduce the above
|
|
12
|
-
* copyright notice, this list of conditions and the following
|
|
13
|
-
* disclaimer in the documentation and/or other materials provided
|
|
14
|
-
* with the distribution.
|
|
15
|
-
*
|
|
16
|
-
* 3. Neither the names Genome Research Ltd and Wellcome Trust Sanger
|
|
17
|
-
* Institute nor the names of its contributors may be used to endorse
|
|
18
|
-
* or promote products derived from this software without specific
|
|
19
|
-
* prior written permission.
|
|
20
|
-
*
|
|
21
|
-
* THIS SOFTWARE IS PROVIDED BY GENOME RESEARCH LTD AND CONTRIBUTORS "AS
|
|
22
|
-
* IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
|
|
23
|
-
* TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
|
|
24
|
-
* PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL GENOME RESEARCH
|
|
25
|
-
* LTD OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
|
26
|
-
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
|
27
|
-
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
|
28
|
-
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
|
29
|
-
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
|
30
|
-
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
|
31
|
-
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
32
|
-
*/
|
|
33
|
-
|
|
34
|
-
var fs = require('fs')
|
|
35
|
-
var rans = require('./rans')
|
|
36
|
-
var argv = require('minimist')(process.argv.slice(2), { boolean: ['d', 'r'] })
|
|
37
|
-
|
|
38
|
-
if (argv._.length != 1) {
|
|
39
|
-
process.stderr.write(
|
|
40
|
-
'Usage: node main_rans.js [-d] [-o order] input-file > output-file\n',
|
|
41
|
-
)
|
|
42
|
-
process.exit(1)
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
var filein = argv._[0]
|
|
46
|
-
|
|
47
|
-
var buf = fs.readFileSync(filein)
|
|
48
|
-
var blk_size = 1024 * 1024
|
|
49
|
-
var raw = argv.r
|
|
50
|
-
|
|
51
|
-
if (!argv.d) {
|
|
52
|
-
var order = argv.o != undefined ? argv.o : 0
|
|
53
|
-
var pos = 0
|
|
54
|
-
var out_len = 0
|
|
55
|
-
if (raw) blk_size = buf.length
|
|
56
|
-
while (pos < buf.length) {
|
|
57
|
-
var buf2 = rans.encode(buf.slice(pos, pos + blk_size), order)
|
|
58
|
-
var header = new Buffer.allocUnsafe(5)
|
|
59
|
-
if (!raw) {
|
|
60
|
-
header[0] = order
|
|
61
|
-
header.writeInt32LE(buf2.length, 1)
|
|
62
|
-
process.stdout.write(header)
|
|
63
|
-
}
|
|
64
|
-
process.stdout.write(buf2)
|
|
65
|
-
pos += blk_size
|
|
66
|
-
out_len += buf2.length
|
|
67
|
-
}
|
|
68
|
-
process.stderr.write(
|
|
69
|
-
'Compress order ' + order + ', ' + buf.length + ' => ' + out_len + '\n',
|
|
70
|
-
)
|
|
71
|
-
} else {
|
|
72
|
-
var pos = 0
|
|
73
|
-
var out_len = 0
|
|
74
|
-
var len = buf.length
|
|
75
|
-
while (pos < buf.length) {
|
|
76
|
-
if (!raw) {
|
|
77
|
-
var order = buf[0]
|
|
78
|
-
pos++
|
|
79
|
-
len = buf.readInt32LE(pos)
|
|
80
|
-
pos += 4
|
|
81
|
-
}
|
|
82
|
-
var buf2 = rans.decode(buf.slice(pos, pos + len))
|
|
83
|
-
process.stdout.write(buf2)
|
|
84
|
-
out_len += buf2.length
|
|
85
|
-
pos += len
|
|
86
|
-
}
|
|
87
|
-
process.stderr.write('Decompress ' + buf.length + ' => ' + out_len + '\n')
|
|
88
|
-
}
|
|
@@ -1,87 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Copyright (c) 2019-2020 Genome Research Ltd.
|
|
3
|
-
* Author(s): James Bonfield
|
|
4
|
-
*
|
|
5
|
-
* Redistribution and use in source and binary forms, with or without
|
|
6
|
-
* modification, are permitted provided that the following conditions are met:
|
|
7
|
-
*
|
|
8
|
-
* 1. Redistributions of source code must retain the above copyright notice,
|
|
9
|
-
* this list of conditions and the following disclaimer.
|
|
10
|
-
*
|
|
11
|
-
* 2. Redistributions in binary form must reproduce the above
|
|
12
|
-
* copyright notice, this list of conditions and the following
|
|
13
|
-
* disclaimer in the documentation and/or other materials provided
|
|
14
|
-
* with the distribution.
|
|
15
|
-
*
|
|
16
|
-
* 3. Neither the names Genome Research Ltd and Wellcome Trust Sanger
|
|
17
|
-
* Institute nor the names of its contributors may be used to endorse
|
|
18
|
-
* or promote products derived from this software without specific
|
|
19
|
-
* prior written permission.
|
|
20
|
-
*
|
|
21
|
-
* THIS SOFTWARE IS PROVIDED BY GENOME RESEARCH LTD AND CONTRIBUTORS "AS
|
|
22
|
-
* IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
|
|
23
|
-
* TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
|
|
24
|
-
* PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL GENOME RESEARCH
|
|
25
|
-
* LTD OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
|
26
|
-
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
|
27
|
-
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
|
28
|
-
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
|
29
|
-
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
|
30
|
-
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
|
31
|
-
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
32
|
-
*/
|
|
33
|
-
|
|
34
|
-
var fs = require('fs')
|
|
35
|
-
var rans = require('./rans4x16')
|
|
36
|
-
var argv = require('minimist')(process.argv.slice(2), { boolean: ['d', 'r'] })
|
|
37
|
-
|
|
38
|
-
if (argv._.length != 1) {
|
|
39
|
-
processf.stderr.write(
|
|
40
|
-
'Usage: node main_rans4x16.js [-d] [-o order] input-file > output-file\n',
|
|
41
|
-
)
|
|
42
|
-
process.exit(1)
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
var filein = argv._[0]
|
|
46
|
-
|
|
47
|
-
var buf = fs.readFileSync(filein)
|
|
48
|
-
var blk_size = 1024 * 1024
|
|
49
|
-
var raw = argv.r
|
|
50
|
-
|
|
51
|
-
if (!argv.d) {
|
|
52
|
-
var order = argv.o != undefined ? argv.o : 0
|
|
53
|
-
// -o8.4 => 8+(256*4)
|
|
54
|
-
order += Math.round((order - (order >> 0)) * 10) * 256
|
|
55
|
-
var pos = 0
|
|
56
|
-
var out_len = 0
|
|
57
|
-
if (raw) blk_size = buf.length
|
|
58
|
-
while (pos < buf.length) {
|
|
59
|
-
var buf2 = rans.encode(buf.slice(pos, pos + blk_size), order)
|
|
60
|
-
var header = new Buffer.allocUnsafe(4)
|
|
61
|
-
if (!raw) {
|
|
62
|
-
header.writeInt32LE(buf2.length, 0)
|
|
63
|
-
process.stdout.write(header)
|
|
64
|
-
}
|
|
65
|
-
process.stdout.write(buf2)
|
|
66
|
-
pos += blk_size
|
|
67
|
-
out_len += buf2.length + 4
|
|
68
|
-
}
|
|
69
|
-
process.stderr.write(
|
|
70
|
-
'Compress order ' + order + ', ' + buf.length + ' => ' + out_len + '\n',
|
|
71
|
-
)
|
|
72
|
-
} else {
|
|
73
|
-
var pos = 0
|
|
74
|
-
var out_len = 0
|
|
75
|
-
var len = buf.length
|
|
76
|
-
while (pos < buf.length) {
|
|
77
|
-
if (!raw) {
|
|
78
|
-
len = buf.readInt32LE(pos)
|
|
79
|
-
pos += 4
|
|
80
|
-
}
|
|
81
|
-
var buf2 = rans.decode(buf.slice(pos, pos + len))
|
|
82
|
-
process.stdout.write(buf2)
|
|
83
|
-
out_len += buf2.length
|
|
84
|
-
pos += len
|
|
85
|
-
}
|
|
86
|
-
process.stderr.write('Decompress ' + buf.length + ' => ' + out_len + '\n')
|
|
87
|
-
}
|
|
@@ -1,86 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Copyright (c) 2019,2020 Genome Research Ltd.
|
|
3
|
-
* Author(s): James Bonfield
|
|
4
|
-
*
|
|
5
|
-
* Redistribution and use in source and binary forms, with or without
|
|
6
|
-
* modification, are permitted provided that the following conditions are met:
|
|
7
|
-
*
|
|
8
|
-
* 1. Redistributions of source code must retain the above copyright notice,
|
|
9
|
-
* this list of conditions and the following disclaimer.
|
|
10
|
-
*
|
|
11
|
-
* 2. Redistributions in binary form must reproduce the above
|
|
12
|
-
* copyright notice, this list of conditions and the following
|
|
13
|
-
* disclaimer in the documentation and/or other materials provided
|
|
14
|
-
* with the distribution.
|
|
15
|
-
*
|
|
16
|
-
* 3. Neither the names Genome Research Ltd and Wellcome Trust Sanger
|
|
17
|
-
* Institute nor the names of its contributors may be used to endorse
|
|
18
|
-
* or promote products derived from this software without specific
|
|
19
|
-
* prior written permission.
|
|
20
|
-
*
|
|
21
|
-
* THIS SOFTWARE IS PROVIDED BY GENOME RESEARCH LTD AND CONTRIBUTORS "AS
|
|
22
|
-
* IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
|
|
23
|
-
* TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
|
|
24
|
-
* PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL GENOME RESEARCH
|
|
25
|
-
* LTD OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
|
26
|
-
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
|
27
|
-
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
|
28
|
-
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
|
29
|
-
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
|
30
|
-
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
|
31
|
-
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
32
|
-
*/
|
|
33
|
-
|
|
34
|
-
var fs = require('fs')
|
|
35
|
-
var tok3 = require('./tok3')
|
|
36
|
-
var argv = require('minimist')(process.argv.slice(2), {
|
|
37
|
-
boolean: ['d', 'a', 'r'],
|
|
38
|
-
})
|
|
39
|
-
|
|
40
|
-
if (argv._.length != 1) {
|
|
41
|
-
process.stderr.write(
|
|
42
|
-
'Usage: node main_tok3.js [-a] [-d] input-file > output-file\n',
|
|
43
|
-
)
|
|
44
|
-
process.exit(1)
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
var filein = argv._[0]
|
|
48
|
-
|
|
49
|
-
var buf = fs.readFileSync(filein)
|
|
50
|
-
var blk_size = 1024 * 1024
|
|
51
|
-
var raw = argv.r
|
|
52
|
-
|
|
53
|
-
if (!argv.d) {
|
|
54
|
-
var pos = 0
|
|
55
|
-
var out_len = 0
|
|
56
|
-
if (raw) blk_size = buf.length
|
|
57
|
-
while (pos < buf.length) {
|
|
58
|
-
var blk_end = blk_size
|
|
59
|
-
while (pos + blk_end < buf.length && buf[pos + blk_end - 1] != 10) blk_end--
|
|
60
|
-
var buf2 = tok3.encode(buf.slice(pos, pos + blk_end), argv.a)
|
|
61
|
-
var header = new Buffer.allocUnsafe(4)
|
|
62
|
-
if (!raw) {
|
|
63
|
-
header.writeInt32LE(buf2.length, 0)
|
|
64
|
-
process.stdout.write(header)
|
|
65
|
-
}
|
|
66
|
-
process.stdout.write(buf2)
|
|
67
|
-
pos += blk_end
|
|
68
|
-
out_len += buf2.length + 4
|
|
69
|
-
}
|
|
70
|
-
process.stderr.write('Compress ' + buf.length + ' => ' + out_len + '\n')
|
|
71
|
-
} else {
|
|
72
|
-
var pos = 0
|
|
73
|
-
var out_len = 0
|
|
74
|
-
var len = buf.length
|
|
75
|
-
while (pos < buf.length) {
|
|
76
|
-
if (!raw) {
|
|
77
|
-
len = buf.readInt32LE(pos)
|
|
78
|
-
pos += 4
|
|
79
|
-
}
|
|
80
|
-
var buf2 = tok3.decode(buf.slice(pos, pos + len), len)
|
|
81
|
-
process.stdout.write(buf2)
|
|
82
|
-
out_len += buf2.length
|
|
83
|
-
pos += len
|
|
84
|
-
}
|
|
85
|
-
process.stderr.write('Decompress ' + buf.length + ' => ' + out_len + '\n')
|
|
86
|
-
}
|