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

[Bug] Wrong type np.bool in mmdet/datasets/transforms/loading.py #9557

Closed
3 tasks done
chofchof opened this issue Jan 2, 2023 · 4 comments
Closed
3 tasks done

[Bug] Wrong type np.bool in mmdet/datasets/transforms/loading.py #9557

chofchof opened this issue Jan 2, 2023 · 4 comments
Assignees

Comments

@chofchof
Copy link

chofchof commented Jan 2, 2023

Prerequisite

Task

I'm using the official example scripts/configs for the officially supported tasks/models/datasets.

Branch

3.x branch https://github.com/open-mmlab/mmdetection/tree/3.x

Environment

mmdet/datasets/transforms/loading.py of 3.x brach contains two wrong type np.bool as follows.

Line #273 & #359: results['gt_ignore_flags'] = np.array(gt_ignore_flags, dtype=np.bool)

It should be replaced by np.bool_.

Reproduces the problem - code sample

demo/image_demo.py

Reproduces the problem - command or script

python demo/image_demo.py demo/demo.jpg yolov3_mobilenetv2_8xb24-320-300e_coco.py yolov3_mobilenetv2_320_300e_coco_20210719_215349-d18dff72.pth --device cuda --out-file result.jpg

Reproduces the problem - error message

AttributeError: module 'numpy' has no attribute 'bool'. Did you mean: 'bool_'?

Additional information

No response

@RangiLyu
Copy link
Member

RangiLyu commented Jan 3, 2023

This bug has been fixed in #9537

@RangiLyu RangiLyu closed this as completed Jan 3, 2023
@Billccx
Copy link

Billccx commented Jan 12, 2023

This bug has been fixed in #9537

Could you please explain in detail? I still failed to run this demo.

@Billccx
Copy link

Billccx commented Jan 12, 2023

By installing "mmdet==3.0.0rc2", the problem solved. However version rc3~rc5 still have the problem.

@Billccx
Copy link

Billccx commented Jan 12, 2023

想借此提一个建议,您们的项目非常优秀,文档也很好,但是各版本之间的关系似乎十分混乱,而且每个版本的文档都不太相同,导致想运行demo都要花费一定的努力。个人观感仅供参考。

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

4 participants