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

100_Numpy_exercises第49题答案无法运行问题及解决方法 #11

Closed
chunyu-just opened this issue Aug 8, 2020 · 0 comments
Closed

Comments

@chunyu-just
Copy link

chunyu-just commented Aug 8, 2020

出现的问题

ValueError Traceback (most recent call last)
in
----> 1 np.set_printoptions(threshold=np.nan)
2 Z = np.zeros((16,16))
3 print(Z)
ValueError: threshold must be non-NAN, try sys.maxsize for untruncated representation

解决方法

将np.set_printoptions(threshold=np.nan)改为np.set_printoptions(threshold=np.inf)
我的numpy版本为1.19.1

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