llSourcell / tensorflow_speech_recognition_demo

This is the code for 'How to Make a Simple Tensorflow Speech Recognizer' by @Sirajology on Youtube
383 stars 250 forks source link

Why is the training loop an infinite loop? #12

Open bonnie-love-ai opened 7 years ago

bonnie-love-ai commented 7 years ago

Maybe this question is silly, but I do not get why the training loop is "while 1". Why wouldn't that train for an infinite number of times?

MatthewScholefield commented 7 years ago

I'm guessing this should be replaced by something like for _ in range(training_iters)

arvind1705 commented 7 years ago

Because number of steps is set to 30000, unfortunately this takes a lot of time.So this seems infinite. Reduce the number iterations.

MatthewScholefield commented 7 years ago

@arvind1705 No, in the demo code it literally is an infinite loop. The training_iters is just never used.

djpg commented 6 years ago

You have to replace while 1: #training_iters: to for i in range(training_iters):