CTC LOSS ERROR InvalidArgumentError: Not enough time for target transition sequence

≯℡__Kan透↙ 提交于 2021-02-18 19:53:17

问题


CTC LOSS ERROR InvalidArgumentError: Not enough time for target transition sequence


回答1:


your ground-truth (GT) text is too long. Your input matrix for the CTC loss function has a time-axis with length T. Your GT text must not be longer than T. Example: input matrix has length 4, your GT text is "world" with length 5, then there is no way that the matrix can contain this text, because it can encode at most 4 chars.

If the GT text contains duplicate chars (like in pizza), then the CTC algorithm must insert a special character (blank) in between, and your allowed GT length even decreases by 1. Some more information about CTC loss: https://medium.com/@harald_scheidl/intuitively-understanding-connectionist-temporal-classification-3797e43a86c

You should check the CTC input length and the length of the GT text (and account for duplicate chars!) for each sample, then it should be easy to identify the one causing this error.



来源:https://stackoverflow.com/questions/50654740/ctc-loss-error-invalidargumenterror-not-enough-time-for-target-transition-seque

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!