Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The same question:list indices must be integers or slices, not list #3

Open
lzx8062456 opened this issue Jul 12, 2019 · 0 comments
Open

Comments

@lzx8062456
Copy link

The first three steps without any problems,I've gone through step four,when I use “python baseline.py --level sent” or “python baseline.py --level bag”,question as follow:

Instructions for updating:
Use tf.cast instead.
Loading train sets
Num of samples - 287351
Loading dev sets
Num of samples - 38417
Epoch - 1
Traceback (most recent call last):
File "baseline.py", line 433, in
tf.app.run()
File "E:\Anaconda\lib\site-packages\tensorflow\python\platform\app.py", line 125, in run
_sys.exit(main(argv))
File "baseline.py", line 429, in main
model.run_model(sess, saver)
File "baseline.py", line 355, in run_model
for batch in train_batchers:
File "baseline.py", line 171, in data_batcher
yield all_sents[idx], all_labels[idx], None
TypeError: list indices must be integers or slices, not list

How should I solve this?thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant