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

[Improvement] Remove dependency package warnings #583

Merged
merged 7 commits into from
Feb 1, 2021

Conversation

congee524
Copy link
Contributor

@congee524 congee524 commented Feb 1, 2021

This PR removes dependency package warnings using import_module_error_xxx hooks

@innerlee
Copy link
Contributor

innerlee commented Feb 1, 2021

Looks good. Have you tested on your machine?

@congee524
Copy link
Contributor Author

Import all modules of mmaction and there are no warnings or errors.
Train a recognizer and there's no problem.
Train a detector, it will raise an error 'ValueError: FastRCNN is not registered in LOCALIZERS, RECOGNIZERS or DETECTORS'. This is consistent with the previous performance

Directly import a function or a class in mmdet, and the error will be raised correctly, such as "ImportError: Please install mmdet to use MaxIoUAssignerAVA."

@congee524
Copy link
Contributor Author

I forgot to test it with mmdet installed. Plz wait for minutes.

@codecov
Copy link

codecov bot commented Feb 1, 2021

Codecov Report

Merging #583 (ad671e2) into master (5c1093e) will decrease coverage by 0.02%.
The diff coverage is 56.75%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #583      +/-   ##
==========================================
- Coverage   84.13%   84.10%   -0.03%     
==========================================
  Files         121      122       +1     
  Lines        8617     8633      +16     
  Branches     1431     1435       +4     
==========================================
+ Hits         7250     7261      +11     
- Misses       1015     1018       +3     
- Partials      352      354       +2     
Flag Coverage Δ
unittests 84.09% <56.75%> (-0.03%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
mmaction/models/backbones/resnet3d.py 90.61% <ø> (+0.21%) ⬆️
mmaction/models/backbones/resnet3d_slowfast.py 84.61% <ø> (+0.40%) ⬆️
mmaction/models/backbones/resnet3d_slowonly.py 78.57% <ø> (+3.57%) ⬆️
mmaction/models/heads/bbox_head.py 80.83% <ø> (+0.50%) ⬆️
...maction/models/roi_extractors/single_straight3d.py 77.58% <14.28%> (-5.75%) ⬇️
mmaction/core/evaluation/recall.py 11.42% <25.00%> (-0.34%) ⬇️
mmaction/models/backbones/resnet_tin.py 19.56% <25.00%> (-0.29%) ⬇️
...action/core/bbox/assigners/max_iou_assigner_ava.py 51.02% <50.00%> (ø)
mmaction/models/builder.py 55.26% <50.00%> (ø)
mmaction/models/heads/roi_head.py 28.26% <50.00%> (ø)
... and 3 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 5c1093e...6ca535b. Read the comment docs.

@dreamerlin
Copy link
Collaborator

Could you help to remove these lines : )

@congee524
Copy link
Contributor Author

congee524 commented Feb 1, 2021

Could you help to remove these lines : )

Do these lines need to be removed?

@innerlee
Copy link
Contributor

innerlee commented Feb 1, 2021

Hmm conflicts

@dreamerlin
Copy link
Collaborator

Could you help to remove these lines : )

Do these lines need to be removed?

emmmm, I mean use the same process

Copy link
Collaborator

@dreamerlin dreamerlin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

tin_shift can not be simpily removed, you need to process it with the same step

@dreamerlin dreamerlin changed the title fix mmdet warnings [Improvment] Remove mmdet warnings Feb 1, 2021
@dreamerlin dreamerlin changed the title [Improvment] Remove mmdet warnings [Improvment] Remove dependency package warnings Feb 1, 2021
@innerlee innerlee changed the title [Improvment] Remove dependency package warnings [Improvement] Remove dependency package warnings Feb 1, 2021
@innerlee
Copy link
Contributor

innerlee commented Feb 1, 2021

@dreamerlin good to go?

@innerlee innerlee merged commit 509118c into open-mmlab:master Feb 1, 2021
@congee524 congee524 deleted the fix_mmdet_warnings branch February 20, 2021 01:53
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.

None yet

3 participants