All Projects → iamjanvijay → rnnt

iamjanvijay / rnnt

Licence: MIT license
An implementation of RNN-Transducer loss in TF-2.0.

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to rnnt

Captcha break
验证码识别
Stars: ✭ 2,268 (+4830.43%)
Mutual labels:  ctc-loss
CTC-OCR
A TensorFlow implementation of hybird CNN-LSTM model with CTC loss for OCR problem
Stars: ✭ 27 (-41.3%)
Mutual labels:  ctc-loss
demo vietasr
Vietnamese Speech Recognition
Stars: ✭ 22 (-52.17%)
Mutual labels:  ctc-loss
HTR-ctc
Pytorch implementation of HTR on IAM dataset (word or line level + CTC loss)
Stars: ✭ 15 (-67.39%)
Mutual labels:  ctc-loss
OCR
Optical character recognition Using Deep Learning
Stars: ✭ 25 (-45.65%)
Mutual labels:  ctc-loss
captcha-recognition
End-to-end captcha image recognition using PyTorch and CTC loss binding.
Stars: ✭ 29 (-36.96%)
Mutual labels:  ctc-loss
CRNN-OCR-lite
Lightweight CRNN for OCR (including handwritten text) with depthwise separable convolutions and spatial transformer module [keras+tf]
Stars: ✭ 130 (+182.61%)
Mutual labels:  ctc-loss
sova-asr
SOVA ASR (Automatic Speech Recognition)
Stars: ✭ 123 (+167.39%)
Mutual labels:  asr-model
Transformer-Transducer
PyTorch implementation of "Transformer Transducer: A Streamable Speech Recognition Model with Transformer Encoders and RNN-T Loss" (ICASSP 2020)
Stars: ✭ 61 (+32.61%)
Mutual labels:  rnnt
rnnt decoder cuda
An efficient implementation of RNN-T Prefix Beam Search in C++/CUDA.
Stars: ✭ 60 (+30.43%)
Mutual labels:  rnnt

RNN-Transducer Loss

This package provides a implementation of Transducer Loss in TensorFlow==2.0.

Using the pakage

First install the module using pip command.

pip install rnnt

Then use the "rnnt" loss funtion from "rnnt" module, as described in the sample script: Sample Train Script

from rnnt import rnnt_loss

def loss_grad_gradtape(logits, labels, label_lengths, logit_lengths):
    with tf.GradientTape() as g:
        g.watch(logits)
        loss = rnnt_loss(logits, labels, label_lengths, logit_lengths)
    grad = g.gradient(loss, logits)
    return loss, grad
    
pred_loss, pred_grads = loss_grad_gradtape(logits, labels, label_lengths, logit_lengths)

Follwing are the shapes of input parameters for rnnt_loss method -
logits - (batch_size, input_time_steps, output_time_steps+1, vocab_size+1)
labels - (batch_size, output_time_steps)
label_length - (batch_size) - number of time steps for each output sequence in the minibatch.
logit_length - (batch_size) - number of time steps for each input sequence in the minibatch.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].