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:object of type 'context' has no len() #73

Open
linhong1909936 opened this issue Dec 8, 2020 · 0 comments
Open

typeError:object of type 'context' has no len() #73

linhong1909936 opened this issue Dec 8, 2020 · 0 comments

Comments

@linhong1909936
Copy link

because I do not have gpu, then I changed the code in 'trian_yolo,py'

training contexts

#ctx = [mx.gpu(int(i)) for i in args.gpus.split(',') if i.strip()]
#ctx = ctx if ctx else [mx.cpu()]
ctx = mx.cpu()

Then I got the error:
File "C:\Users\Chinese\anaconda3\envs\shMGO\lib\site-packages\mxnet\gluon\utils.py", line 110, in split_and_load
if len(ctx_list) == 1:

TypeError: object of type 'Context' has no len()

please help
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