Hi
In running the first example of hmlstm,
I am having errors:
batches_in, batches_out = prepare_inputs(batch_size=10, truncate_len=5000,
step_size=25, text_path='text8.txt')
TypeErrorTraceback (most recent call last)
in ()
1 batches_in, batches_out = prepare_inputs(batch_size=10, truncate_len=500,
----> 2 step_size=25, text_path='text8.txt')
/usr/local/lib/python2.7/dist-packages/hmlstm/preprocessing.pyc in prepare_inputs(batch_size, truncate_len, text_path, step_size, num_batches)
68
69 if num_batches is None:
---> 70 y = text(text_path, truncate_len, step_size, batch_size)
71 num_batches = len(y) // batch_size
72 elif num_batches is not None:
/usr/local/lib/python2.7/dist-packages/hmlstm/preprocessing.pyc in text(text_path, truncate_len, step_size, batch_size, num_chars)
5
6 def text(text_path, truncate_len, step_size, batch_size, num_chars=None):
----> 7 signals = load_text(text_path, truncate_len, step_size, batch_size, num_chars)
8
9 hot = [(one_hot_encode(intext), one_hot_encode(outtext))
/usr/local/lib/python2.7/dist-packages/hmlstm/preprocessing.pyc in load_text(text_path, truncate_len, step_size, batch_size, num_chars)
15 def load_text(text_path, truncate_len, step_size, batch_size, num_chars):
16 with open(text_path, 'r') as f:
---> 17 text = f.read(num_chars)
18 text = text.replace('\n', ' ')
19 text = re.sub(' +', ' ', text).lower()
TypeError: an integer is required
Errors occur under tensorflow version 1.0 ~ 1.2