MCPcopy Index your code
hub / github.com/clips/pattern / lzwdecode

Function lzwdecode

pattern/web/pdf/lzw.py:91–97  ·  view source on GitHub ↗

>>> lzwdecode('\x80\x0b\x60\x50\x22\x0c\x0c\x85\x01') '\x2d\x2d\x2d\x2d\x2d\x41\x2d\x2d\x2d\x42'

(data)

Source from the content-addressed store, hash-verified

89
90# lzwdecode
91def lzwdecode(data):
92 """
93 >>> lzwdecode('\x80\x0b\x60\x50\x22\x0c\x0c\x85\x01')
94 '\x2d\x2d\x2d\x2d\x2d\x41\x2d\x2d\x2d\x42'
95 """
96 fp = StringIO(data)
97 return ''.join(LZWDecoder(fp).run())
98
99if __name__ == '__main__':
100 import doctest

Callers 1

decodeMethod · 0.90

Calls 2

LZWDecoderClass · 0.85
runMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…