Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
aymericdamien authored Apr 27, 2017
1 parent 257a827 commit b9f48af
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tflearn/models/generator.py
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ def generate(self, seq_length, temperature=0.5, seq_seed=None,
next_index = _sample(preds, temperature)
next_char = self.rev_dic[next_index]

if type(sequence) == str:
if type(sequence) in [str, unicode]:
generated += next_char
sequence = sequence[1:] + next_char
whole_sequence += next_char
Expand Down

0 comments on commit b9f48af

Please sign in to comment.