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

TypeError: can only concatenate str (not "torch.device") to str #9

Open
DVSneuro opened this issue Feb 6, 2024 · 0 comments · May be fixed by #10
Open

TypeError: can only concatenate str (not "torch.device") to str #9

DVSneuro opened this issue Feb 6, 2024 · 0 comments · May be fixed by #10

Comments

@DVSneuro
Copy link

DVSneuro commented Feb 6, 2024

Hi, thanks for this this great tool! We followed the basic installation instructions and would like to use one of the trained models, but we keep getting a strange concatenation error. It looks like device isn't a string, so in places where you have print('testfunction:device used:' + device) maybe print('testfunction:device used:' + str(device)) would work?

Our command and the output are pasted below.

truenet evaluate -i testing-truenet-dvs/sub-10866_testing -m mwsc -o testing-truenet-dvs/sub-10866_results
FLAIR image found for sub-10866
Traceback (most recent call last):
  File "/ZPOOL/data/tools/anaconda/tug87422/anaconda3/bin/truenet", line 4, in <module>
    __import__('pkg_resources').run_script('truenet==1.0.1', 'truenet')
  File "/ZPOOL/data/tools/anaconda/tug87422/anaconda3/lib/python3.11/site-packages/pkg_resources/__init__.py", line 720, in run_script
    self.require(requires)[0].run_script(script_name, ns)
  File "/ZPOOL/data/tools/anaconda/tug87422/anaconda3/lib/python3.11/site-packages/pkg_resources/__init__.py", line 1570, in run_script
    exec(script_code, namespace, namespace)
  File "/ZPOOL/data/tools/anaconda/tug87422/anaconda3/lib/python3.11/site-packages/truenet-1.0.1-py3.11.egg/EGG-INFO/scripts/truenet", line 159, in <module>
  File "/ZPOOL/data/tools/anaconda/tug87422/anaconda3/lib/python3.11/site-packages/truenet-1.0.1-py3.11.egg/truenet/true_net/truenet_commands.py", line 409, in evaluate
  File "/ZPOOL/data/tools/anaconda/tug87422/anaconda3/lib/python3.11/site-packages/truenet-1.0.1-py3.11.egg/truenet/true_net/truenet_test_function.py", line 38, in main
TypeError: can only concatenate str (not "torch.device") to str
@DVSneuro DVSneuro linked a pull request Feb 6, 2024 that will close this issue
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 a pull request may close this issue.

1 participant