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

metrics_mean = {metric: np.mean([x[metric] for x in summ]) for metric in summ[0]} #31

Closed
xiaoiker opened this issue Apr 2, 2020 · 2 comments

Comments

@xiaoiker
Copy link

xiaoiker commented Apr 2, 2020

Hello,
I met a problem with this line. The error is:
File "/appl/soft/ai/miniconda3/envs/pytorch-1.3.0-1/lib/python3.7/site-packages/numpy/core/fromnumeric.py", line 3257, in mean
out=out, **kwargs)
File "/appl/soft/ai/miniconda3/envs/pytorch-1.3.0-1/lib/python3.7/site-packages/numpy/core/_methods.py", line 161, in _mean
ret = ret.dtype.type(ret / rcount)
AttributeError: 'torch.dtype' object has no attribute 'type'

I did try torch.mean(torch.stack()), however it still not work. Do you have some seggestions?

@huguyuehuhu
Copy link
Owner

Caused by PyTorch version updating, please use PyTorch (0.4.0).

@TitaniumOne
Copy link

@xiaoiker Hello, have you solved this problem?
@huguyuehuhu Hello, I use PyTorch 0.4.0, but it did not work.

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

3 participants