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

Fix deprecated numpy.float in cocoeval.py #624

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

sadra-barikbin
Copy link

@sadra-barikbin sadra-barikbin commented Nov 29, 2022

Fixes #505

@psyhtest
Copy link

This is really urgent now.

@cchan-lm
Copy link

Agreed. This is very urgent and we would not like to downgrade our version of numpy. Thanks!

@cchan-lm
Copy link

cchan-lm commented Jan 3, 2023

Did a hacky workaround without downgrading numpy, which happens to work for our needs until this repo gets updated. Needs to be done at the beginning of your script that imports pycocotools or at the topmost level of your package but YMMV:

from packaging import version
import numpy as np

if version.parse(np.__version__) >= version.parse("1.24.0"):
    np.float = np.float32

@mikel-brostrom
Copy link

Could we get this merged @tylin, @pdollar?

@mikel-brostrom
Copy link

Sadly, nobody seems to maintain this repo anymore 😢

@jerpint
Copy link

jerpint commented Mar 5, 2023

can confirm with the latest versions of numpy, pycocotools breaks.

The fix proposed by @cchan-lm works but can definitely have unintended side effects

@wilderrodrigues
Copy link

So, is pycocotools dead? Should someone take over and make sure those merge requests get updated? We also need this Numpy changes.

@cchan-lm
Copy link

cchan-lm commented Mar 6, 2023

It might be... https://cocodataset.org/ mentions partnership with FiftyOne, so I wonder if this means pycocotools is no longer being maintained in favor of FiftyOne?

@jerpint
Copy link

jerpint commented Mar 7, 2023

https://github.com/facebookresearch/detr/blob/main/datasets/coco_eval.py

This script could be a good alternative to use from now on

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 this pull request may close these issues.

Fix Numpy 1.20 Deprecation Warning in cocoeval.py
6 participants