Skip to content

Commit bb5ca4d

Browse files
author
Johannes Ballé
committed
Re-adds range coding ops.
PiperOrigin-RevId: 241597583
1 parent 3146b10 commit bb5ca4d

32 files changed

+2043
-60
lines changed

README.md

Lines changed: 19 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@ This project contains data compression ops and layers for TensorFlow. The
22
project website is at
33
[tensorflow.github.io/compression](https://tensorflow.github.io/compression).
44

5-
You can use this library to build your own ML models with optimized lossy
6-
data compression built in. It's useful to find storage-efficient representations
7-
of your data (features, examples, images, etc.) while only sacrificing a tiny
5+
You can use this library to build your own ML models with optimized lossy data
6+
compression built in. It's useful to find storage-efficient representations of
7+
your data (features, examples, images, etc.) while only sacrificing a tiny
88
fraction of model performance. It can compress any floating point tensor to a
99
much smaller sequence of bits.
1010

@@ -22,11 +22,14 @@ at @jonycgn's
2222

2323
# Quick start
2424

25-
**Please note**: You need TensorFlow 1.9 (or the master branch as of May 2018)
26-
or later installed.
25+
Install TensorFlow 1.13.
2726

28-
Clone the repository to a filesystem location of your choice, or download the
29-
ZIP file and unpack it. Then include the root directory in your `PYTHONPATH`
27+
**Please note**: We are currently transitioning to providing pip packages. At
28+
this point, the master will not work. Make sure to use the released version.
29+
30+
Download the
31+
[ZIP file for release v1.1](https://github.com/tensorflow/compression/releases/tag/v1.1)
32+
and unpack it. Then include its root directory in your `PYTHONPATH`
3033
environment variable:
3134

3235
```bash
@@ -53,9 +56,9 @@ import tensorflow_compression as tfc
5356

5457
## Example model
5558

56-
The [examples directory](https://github.com/tensorflow/compression/tree/master/examples)
57-
contains an implementation of the image compression model described
58-
in:
59+
The
60+
[examples directory](https://github.com/tensorflow/compression/tree/master/examples)
61+
contains an implementation of the image compression model described in:
5962

6063
> "End-to-end optimized image compression"<br />
6164
> J. Ballé, V. Laparra, E. P. Simoncelli<br />
@@ -110,7 +113,8 @@ python bls2017.py [options] decompress compressed.bin reconstruction.png
110113
For usage questions and discussions, please head over to our
111114
[Google group](https://groups.google.com/forum/#!forum/tensorflow-compression).
112115

113-
Refer to [the API documentation](https://tensorflow.github.io/compression/docs/api_docs/python/tfc.html)
116+
Refer to
117+
[the API documentation](https://tensorflow.github.io/compression/docs/api_docs/python/tfc.html)
114118
for a complete description of the Keras layers and TensorFlow ops this package
115119
implements.
116120

@@ -120,8 +124,9 @@ and a description of the range coding operators
120124
[here](https://tensorflow.github.io/compression/docs/range_coding.html).
121125

122126
# Authors
123-
Johannes Ballé (github: [jonycgn](https://github.com/jonycgn)),
124-
Sung Jin Hwang (github: [ssjhv](https://github.com/ssjhv)), and
125-
Nick Johnston (github: [nmjohn](https://github.com/nmjohn))
127+
128+
Johannes Ballé (github: [jonycgn](https://github.com/jonycgn)), Sung Jin Hwang
129+
(github: [ssjhv](https://github.com/ssjhv)), and Nick Johnston (github:
130+
[nmjohn](https://github.com/nmjohn))
126131

127132
Note that this is not an officially supported Google product.

tensorflow_compression/__init__.py renamed to __init__.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
# -*- coding: utf-8 -*-
21
# Copyright 2018 Google LLC. All Rights Reserved.
32
#
43
# Licensed under the Apache License, Version 2.0 (the "License");
@@ -29,9 +28,9 @@
2928
from tensorflow_compression.python.layers.initializers import *
3029
from tensorflow_compression.python.layers.parameterizers import *
3130
from tensorflow_compression.python.layers.signal_conv import *
32-
from tensorflow_compression.python.ops.coder_ops import *
3331
from tensorflow_compression.python.ops.math_ops import *
3432
from tensorflow_compression.python.ops.padding_ops import *
33+
from tensorflow_compression.python.ops.range_coding_ops import *
3534
from tensorflow_compression.python.ops.spectral_ops import *
3635
# pylint: enable=wildcard-import
3736

0 commit comments

Comments
 (0)