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

Error when training a model on CUDA #407

Closed
stefan-it opened this issue Jan 21, 2019 · 1 comment · Fixed by #448
Closed

Error when training a model on CUDA #407

stefan-it opened this issue Jan 21, 2019 · 1 comment · Fixed by #448
Assignees
Labels
bug Something isn't working

Comments

@stefan-it
Copy link
Member

stefan-it commented Jan 21, 2019

Hi,

I think this is a regression bug that was introduced after merging the CUDA semantics pull request #402.

Here's an error message that comes from the test_model_integration.py integration test:

>               tag_tensor = torch.LongTensor(sentence_tags)
E               TypeError: expected torch.LongTensor (got torch.cuda.LongTensor)

I got a similar error message when I tried to test my recent ELMo transformer embeddings on GPU.

To replicate the error just run the integration tests (pytest --runintegration) on a machine with GPU/CUDA support :)

@stefan-it stefan-it added the bug Something isn't working label Jan 21, 2019
@tabergma tabergma assigned tabergma and unassigned tabergma Jan 23, 2019
@alanakbik alanakbik self-assigned this Feb 2, 2019
alanakbik pushed a commit that referenced this issue Feb 2, 2019
alanakbik pushed a commit that referenced this issue Feb 2, 2019
alanakbik pushed a commit that referenced this issue Feb 2, 2019
@stefan-it
Copy link
Member Author

Thanks, it is working now :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants