ocr.py 文件源码

python
阅读 39 收藏 0 点赞 0 评论 0

项目:tf-cnn-lstm-ocr-captcha 作者: Luonic 项目源码 文件源码
def create_label_error_rate(logits, labels, timesteps):
  with tf.variable_scope('LER'):
    decoded, log_prob = tf.nn.ctc_greedy_decoder(logits, timesteps)
    decoded = tf.cast(decoded[0], tf.int32)    
    edit_dist = tf.edit_distance(decoded, labels)
    ler = tf.reduce_mean(edit_dist)
    tf.summary.scalar('label_error_rate', ler)
    return ler
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号