-
Notifications
You must be signed in to change notification settings - Fork 9.5k
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: 'COCO' object has no attribute 'get_cat_ids' #2913
Comments
I think the problem comes from this commit - #2088, which changes the API names for COCO in the
|
Patching aside, doesn't this mean all coco related trainings are going to break? |
Since the official cocoapi repo is out of maintainance, we decided to have our own fork, which fixes bugs and compatability issues with newer version of numpy. Also we unify the api of COCO and LVIS. |
The compatibility issue with newer version of numpy has actually been fixed in the official version in cocodataset/cocoapi#354 |
I see. Is there any chance that Piotr will ask someone to update the pypi package so that pycocotools can be put in |
Unfortunately we don't own the pypi package. It's created by some random guy I think. Maybe we can try to get into contact. |
When |
same question here.
|
@gravitychen You can just install the new pycocotools by openmmlab. Modifying pip install "git+https://github.com/open-mmlab/cocoapi.git#subdirectory=pycocotools" |
@hellock Thanks. This fixed get_cat_ids for me |
Thank you! |
Can't mmlab keep aliases to the old function names in their fork? That way people who use the git version of the official coco api (which is up to date with numpy changes) don't have to change the coco file in mmdet? I personally don't think forcing people to use your fork of the coco api is the way to go. |
@Mxbonn We do not want to keep our own fork at all if the official one was well maintained. Our fork contains both the original and the snake case method names. It solves the following problems and we think the benefits suppress the drawbacks.
|
We had taken back control of the name "pycocotools" on pypi. Now the package is updated to be the same as github. |
@hellock I vote to "using mmlab's cocapi". Thanks for your maintain. |
Hi everyone, |
Thanks for your error report and we appreciate it a lot.
Checklist
Describe the bug
I was trying to train SSD300 on a custom dataset in my local system with COCO style annotations and encountered this error on training
Reproduction
Environment
python mmdet/utils/collect_env.py
to collect necessary environment infomation and paste it here.$PATH
,$LD_LIBRARY_PATH
,$PYTHONPATH
, etc.)Error traceback
If applicable, paste the error trackback here.
Bug fix
If you have already identified the reason, you can provide the information here. If you are willing to create a PR to fix it, please also leave a comment here and that would be much appreciated!
The text was updated successfully, but these errors were encountered: