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

AttributeError: module 'numpy' has no attribute 'float'. Did you mean: 'cfloat'? #1236

Open
luzhangao opened this issue Jan 25, 2023 · 5 comments · May be fixed by #1257
Open

AttributeError: module 'numpy' has no attribute 'float'. Did you mean: 'cfloat'? #1236

luzhangao opened this issue Jan 25, 2023 · 5 comments · May be fixed by #1257

Comments

@luzhangao
Copy link

  • PyTorch-Forecasting version: 0.10.3
  • PyTorch version: 1.13.1
  • Python version: 3.10.8
  • Operating System: mac os
  • Numpy version: 1.24.1

Expected behavior

I executed the stallion example and expected to run it successfully.

Actual behavior

However, it failed and raised an error AttributeError: module 'numpy' has no attribute 'float'. Did you mean: 'cfloat'?. This is because 'float' was deprecated in the latest version of numpy.

@Titaniumtown
Copy link

Titaniumtown commented Jan 28, 2023

Same issue. Hope this can get fixed! Had to revert to use numpy 1.23.5 for it to work.

@yairmassury
Copy link

ho need to revert, just remove the np.float -> float from encoders.py

@Titaniumtown
Copy link

"ho"?

@diegoasua
Copy link

experiencing same issue

@yairmassury
Copy link

yairmassury commented Feb 3, 2023

"ho"?
No need to revert, just replace the np.float -> float in two places, in the "encoders.py" file.

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.

4 participants