My coworker and I were trying to run analyze.py and received the following error:
Traceback (most recent call last):
File "analyze.py", line 106, in
y_pred, y_test = predict('data/valid', model)
File "analyze.py", line 44, in predict
class_id = int(tokens[-2])
IndexError: list index out of range
It appears that os.pathsep that is passed into the split function on line 44 in analyze.py is using a ':' as a delimiter instead of a '/'. Replacing this with os.path.sep fixes the issue.
Hello,
My coworker and I were trying to run analyze.py and received the following error:
Traceback (most recent call last): File "analyze.py", line 106, in
y_pred, y_test = predict('data/valid', model)
File "analyze.py", line 44, in predict
class_id = int(tokens[-2])
IndexError: list index out of range
It appears that os.pathsep that is passed into the split function on line 44 in analyze.py is using a ':' as a delimiter instead of a '/'. Replacing this with os.path.sep fixes the issue.