Handle inf in deepspeech 0.5.1

Hi, In new alpha version the mozilla deepspeech team included a code to get the inf loss file.but, alpha version does not have pretrained model and also if you have huge dataset you have to wait for whole epochs to get the all inf loss file and also I find that if more inf file are trained , the good file files also getting inf loss.So I added line of code to convert the inf loss to zero so that the inf loss file will not get trained on the model. and also you can get the mostly real bad inf loss file.
Here the code I modified Deepspeech.py.

DeepSpeech_testing.py.zip (10.4 KB)
and you have to just copy and paste alpha version feeding.py and text.py in 0.5.1 ulti folder.


Your changes aren’t doing what you think they’re doing. Setting the loss to zero doesn’t make it so that “inf loss file will not get trained”. The model will still be trained the same way it was before. The correct solution is to remove or fix problematic files so that they don’t produce inf loss.