diff --git a/data/shakespeare_char/prepare.py b/data/shakespeare_char/prepare.py index c4f0306..9fd1621 100644 --- a/data/shakespeare_char/prepare.py +++ b/data/shakespeare_char/prepare.py @@ -32,7 +32,7 @@ itos = { i:ch for i,ch in enumerate(chars) } def encode(s): return [stoi[c] for c in s] # encoder: take a string, output a list of integers def decode(l): - ''.join([itos[i] for i in l]) # decoder: take a list of integers, output a string + return ''.join([itos[i] for i in l]) # decoder: take a list of integers, output a string # create the train and test splits n = len(data)