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

Fix "invalid index of a 0-dim tensor. Use tensor.item() to convert a … #1

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

scottvr
Copy link

@scottvr scottvr commented Jul 20, 2021

…0-dim tensor to a Python number" error on line 193 and add some output to inform if GPU was detected.

Newer version of torch does not like the syntax for accessing the style_score. This fix should be backward compatible.
Also added a simple print() statement to inform if cuda detection was successful or if app will run on cpu.

…0-dim tensor to a Python number" error on line 193 and add some output to inform if GPU was detected.
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

Successfully merging this pull request may close these issues.

1 participant