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

Change float datatype #311

Open
marius-ne opened this issue Nov 26, 2024 · 0 comments
Open

Change float datatype #311

marius-ne opened this issue Nov 26, 2024 · 0 comments

Comments

@marius-ne
Copy link

Hello everybody,

when trying it your great package on the mpii dataset I get this error (when running train.py like described in the README):

Traceback (most recent call last):
  File "/.../tools/train.py", line 223, in <module>
    main()
  File "/.../tools/train.py", line 126, in main
    train_dataset = eval('dataset.'+cfg.DATASET.DATASET)(
  File "/.../tools/../lib/dataset/mpii.py", line 36, in __init__
    self.db = self._get_db()
  File "/.../tools/../lib/dataset/mpii.py", line 55, in _get_db
    c = np.array(a['center'], dtype=np.float)
  File "/usr/local/lib/python3.10/dist-packages/numpy/__init__.py", line 324, in __getattr__
    raise AttributeError(__former_attrs__[attr])
AttributeError: module 'numpy' has no attribute 'float'.
`np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
    https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?

I therefore suggest opening a pull-request on this issue to change from np.float to float.

Let me know what you think.

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