HawkAaron / warp-transducer

A fast parallel implementation of RNN Transducer.
Apache License 2.0
307 stars 124 forks source link

Some questions about RegisterShape #71

Open alongwithyou opened 4 years ago

alongwithyou commented 4 years ago

Traceback (most recent call last): File "tests/test_warprnnt_op.py", line 3, in from warprnnt_tensorflow import rnnt_loss File "/NEWAI/Speech/Member/gaoxinglong/bin/anaconda3/lib/python3.7/site-packages/warprnnt_tensorflow-0.1-py3.7-linux-x86_64.egg/warprnnt_tensorflow/init.py", line 44, in @ops.RegisterShape("WarpRNNT") AttributeError: module 'tensorflow.python.framework.ops' has no attribute 'RegisterShape'

PeiyanFlying commented 4 years ago

Hello sir, I meet with the same problem as yours. So have you solved this bug? Really appreciate your answer. Many thanks!

bhaswa commented 4 years ago

I am also getting the same issue. Any update on this? Thanks!

pyyush commented 3 years ago

TFv2.3.0

====================================================================== ERROR: test_basic (unittest.loader._FailedTest)

ImportError: Failed to import test module: test_basic Traceback (most recent call last): File "/N/soft/rhel7/deeplearning/Python-3.8.5/lib/python3.8/unittest/loader.py", line 436, in _find_test_path module = self._get_module_from_name(name) File "/N/soft/rhel7/deeplearning/Python-3.8.5/lib/python3.8/unittest/loader.py", line 377, in _get_module_from_name import(name) File "/N/slate/piyush/warp-transducer/tensorflow_binding/tests/test_basic.py", line 3, in from warprnnt_tensorflow import rnnt_loss File "/N/slate/piyush/warp-transducer/tensorflow_binding/warprnnt_tensorflow/init.py", line 44, in @ops.RegisterShape("WarpRNNT") AttributeError: module 'tensorflow.python.framework.ops' has no attribute 'RegisterShape'

====================================================================== ERROR: test_warprnnt_op (unittest.loader._FailedTest)

ImportError: Failed to import test module: test_warprnnt_op Traceback (most recent call last): File "/N/soft/rhel7/deeplearning/Python-3.8.5/lib/python3.8/unittest/loader.py", line 436, in _find_test_path module = self._get_module_from_name(name) File "/N/soft/rhel7/deeplearning/Python-3.8.5/lib/python3.8/unittest/loader.py", line 377, in _get_module_from_name import(name) File "/N/slate/piyush/warp-transducer/tensorflow_binding/tests/test_warprnnt_op.py", line 3, in from warprnnt_tensorflow import rnnt_loss File "/N/slate/piyush/warp-transducer/tensorflow_binding/warprnnt_tensorflow/init.py", line 38, in def _RNNTLossGrad(op, gradloss, ): File "/N/soft/rhel7/deeplearning/Python-3.8.5/lib/python3.8/site-packages/tensorflow/python/framework/ops.py", line 2598, in call _gradient_registry.register(f, self._op_type) File "/N/soft/rhel7/deeplearning/Python-3.8.5/lib/python3.8/site-packages/tensorflow/python/framework/registry.py", line 58, in register raise KeyError( KeyError: "Registering two gradient with name 'WarpRNNT'! (Previous registration was in register /N/soft/rhel7/deeplearning/Python-3.8.5/lib/python3.8/site-packages/tensorflow/python/framework/registry.py:66)"


Ran 2 tests in 0.000s

FAILED (errors=2) Test failed: error: Test failed:

muyamu commented 3 years ago

tensorflow2.0 version has RegisterShape.

wilson1692 commented 1 year ago

I have a problem, can help me please AttributeError: module 'tensorflow.python.framework.ops' has no attribute 'RegisterShape'