Skip to content

Commit

Permalink
[TFLite][Python 2] Solve TFLite frontend python 2 compatibility and M…
Browse files Browse the repository at this point in the history
…odify TFLite whl files path (apache#2529)
  • Loading branch information
FrozenGene authored and merrymercy committed Feb 17, 2019
1 parent a3efd19 commit 4492fe6
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion python/tvm/relay/frontend/tflite.py
Original file line number Diff line number Diff line change
Expand Up @@ -546,7 +546,7 @@ def get_pad_value(data, kernel, stride):
pad tuple of value
"""

out = math.ceil(float(data) / float(stride))
out = int(math.ceil(float(data) / float(stride)))
pad = max(0, (out - 1) * stride + kernel - data)
pad_before = pad // 2
pad_after = pad - pad_before
Expand Down
4 changes: 2 additions & 2 deletions tutorials/frontend/from_tflite.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,11 @@
.. code-block:: bash
# For python3:
wget https://github.com/dmlc/web-data/tree/master/tensorflow/tflite/whl/tflite-0.0.1-py3-none-any.whl
wget https://raw.githubusercontent.com/dmlc/web-data/master/tensorflow/tflite/whl/tflite-0.0.1-py3-none-any.whl
pip install tflite-0.0.1-py3-none-any.whl --user
# For python2:
wget https://github.com/dmlc/web-data/tree/master/tensorflow/tflite/whl/tflite-0.0.1-py2-none-any.whl
wget https://raw.githubusercontent.com/dmlc/web-data/master/tensorflow/tflite/whl/tflite-0.0.1-py2-none-any.whl
pip install tflite-0.0.1-py2-none-any.whl --user
Expand Down

0 comments on commit 4492fe6

Please sign in to comment.