luka0612 / asr_transformer Goto Github PK
View Code? Open in Web Editor NEW采用transformer end2end训练语音识别ASR
采用transformer end2end训练语音识别ASR
asr_transformer/lib/modules.py
Line 8 in 4b88bca
Is it need update mean and var in batchnorm at training and testing period? In fact, some application only one wave to recognize.
asr_transformer/lib/modules.py
Line 193 in 4b88bca
It's little wired because your comment is "Linear projections", but with RELU it will be a nolinear function.
大佬,可以提供下 数据集么,http://openslr.org/resources.php 下载 中文语音数据好慢,可以提供下数据么,还有如何 跑通你的代码,可以提供下么,非常感谢!!!
Traceback (most recent call last):
File "/home/uvideo/anaconda3/envs/nlp/lib/python3.6/site-packages/tensorflow/python/ops/array_ops.py", line 2667, in gather
return params.sparse_read(indices, name=name)
AttributeError: 'Tensor' object has no attribute 'sparse_read'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "train.py", line 51, in
tmodel.build_test_model(get_wer=True)
File "/home/uvideo/huatianxiang/asr_transformer/transformer.py", line 268, in build_test_model
self.test_preds = self.get_beam_search_preds(reuse=reuse, is_training=is_training, get_wer=get_wer)
File "/home/uvideo/huatianxiang/asr_transformer/transformer.py", line 247, in get_beam_search_preds
return self.make_parallel_beam_search(reuse=reuse, is_training=is_training, get_wer=get_wer)
File "/home/uvideo/huatianxiang/asr_transformer/transformer.py", line 614, in make_parallel_beam_search
prediction = self.model_beam_search_preds(X, reuse, is_training, scope="transformer")
File "/home/uvideo/huatianxiang/asr_transformer/transformer.py", line 264, in model_beam_search_preds
test_preds = self.beam_search(enc_output, reuse)
File "/home/uvideo/huatianxiang/asr_transformer/transformer.py", line 428, in beam_search
back_prop=False)
File "/home/uvideo/anaconda3/envs/nlp/lib/python3.6/site-packages/tensorflow/python/ops/control_flow_ops.py", line 3274, in while_loop
return_same_structure)
File "/home/uvideo/anaconda3/envs/nlp/lib/python3.6/site-packages/tensorflow/python/ops/control_flow_ops.py", line 2994, in BuildLoop
pred, body, original_loop_vars, loop_vars, shape_invariants)
File "/home/uvideo/anaconda3/envs/nlp/lib/python3.6/site-packages/tensorflow/python/ops/control_flow_ops.py", line 2929, in _BuildLoop
body_result = body(*packed_vars_for_body)
File "/home/uvideo/huatianxiang/asr_transformer/transformer.py", line 401, in step
preds = tf.gather(preds, indices=tf.cast(k_indices, tf.int64) / beam_size)
File "/home/uvideo/anaconda3/envs/nlp/lib/python3.6/site-packages/tensorflow/python/ops/array_ops.py", line 2669, in gather
return gen_array_ops.gather_v2(params, indices, axis, name=name)
File "/home/uvideo/anaconda3/envs/nlp/lib/python3.6/site-packages/tensorflow/python/ops/gen_array_ops.py", line 3232, in gather_v2
"GatherV2", params=params, indices=indices, axis=axis, name=name)
File "/home/uvideo/anaconda3/envs/nlp/lib/python3.6/site-packages/tensorflow/python/framework/op_def_library.py", line 609, in _apply_op_helper
param_name=input_name)
File "/home/uvideo/anaconda3/envs/nlp/lib/python3.6/site-packages/tensorflow/python/framework/op_def_library.py", line 60, in _SatisfiesTypeConstraint
", ".join(dtypes.as_dtype(x).name for x in allowed_list)))
TypeError: Value passed to parameter 'indices' has DataType float64 not in list of allowed values: int32, int64 你好,我运行的代码出现上面的错误是什么原因啊,环境python3.6 和tf1.11.0
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.