Off by one bug in Neural language translation example
eli7 opened this issue · comments
eli7 commented
This line: https://github.com/tensorflow/skflow/blob/master/examples/neural_translation_word.py#L156
Is:
idx = random.randint(0, len(X_test))
From reading the help for randint, I think it should be:
idx = random.randint(0, len(X_test) - 1)
Also I got unlucky and got an index out of range exception :)