-
Notifications
You must be signed in to change notification settings - Fork 70
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
cat(): argument 'tensors' (position 1) must be tuple of Tensors, not generator #4
Comments
torch.cat([dict[word].view(1, -1) for word in lsent]) is this also ok ? |
Hi caoxu, I tried your second answer in other code: |
@lanwuwei |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
SPM_toolkit/DecAtt/main_quora.py
Line 56 in 3e2cb35
cat(): argument 'tensors' (position 1) must be tuple of Tensors, not generator
can I fix this bug use this line?
torch.cat(tuple([dict[word].view(1, -1) for word in lsent]))
The text was updated successfully, but these errors were encountered: