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

[Improve] Use metric_dict to replace hardcode arg in evaluate #286

Merged
merged 11 commits into from
Oct 31, 2020

Conversation

dreamerlin
Copy link
Collaborator

@dreamerlin dreamerlin commented Oct 27, 2020

def evaluate(self,
             ...
             topk=(1, 5),
             ...):

to

def evaluate(self,
             ...
             metric_dict=dict(topk=(1, 5)),
             ...):

to avoid hardcoded argument for evaluate

@dreamerlin dreamerlin changed the title [Imporve] Use metric_dict to replace hardcode arg [Imporve] Use metric_dict to replace hardcode arg in evaluate Oct 27, 2020
@dreamerlin dreamerlin changed the title [Imporve] Use metric_dict to replace hardcode arg in evaluate [Improve] Use metric_dict to replace hardcode arg in evaluate Oct 27, 2020
@codecov
Copy link

codecov bot commented Oct 27, 2020

Codecov Report

Merging #286 into master will decrease coverage by 0.17%.
The diff coverage is 63.75%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #286      +/-   ##
==========================================
- Coverage   82.56%   82.39%   -0.18%     
==========================================
  Files          95       95              
  Lines        6867     6777      -90     
  Branches     1126     1099      -27     
==========================================
- Hits         5670     5584      -86     
- Misses        984      986       +2     
+ Partials      213      207       -6     
Flag Coverage Δ
unittests 82.39% <63.75%> (-0.18%) ⬇️

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

Impacted Files Coverage Δ
mmaction/datasets/audio_dataset.py 73.68% <ø> (-10.10%) ⬇️
mmaction/datasets/audio_feature_dataset.py 73.68% <ø> (-10.10%) ⬇️
mmaction/datasets/image_dataset.py 83.33% <ø> (ø)
mmaction/datasets/rawframe_dataset.py 86.56% <ø> (+8.23%) ⬆️
mmaction/datasets/video_dataset.py 66.66% <ø> (-15.88%) ⬇️
mmaction/datasets/activitynet_dataset.py 92.59% <50.00%> (-2.46%) ⬇️
mmaction/datasets/ssn_dataset.py 92.66% <50.00%> (-0.80%) ⬇️
mmaction/datasets/base.py 60.00% <66.10%> (+4.04%) ⬆️
mmaction/datasets/hvu_dataset.py 67.10% <66.66%> (-0.47%) ⬇️
mmaction/datasets/ava_dataset.py 89.62% <100.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 07dd1a9...c1fcabf. Read the comment docs.

@dreamerlin dreamerlin marked this pull request as ready for review October 28, 2020 07:38
@dreamerlin
Copy link
Collaborator Author

@innerlee @SuX97 Ready now

mmaction/datasets/base.py Outdated Show resolved Hide resolved
@innerlee
Copy link
Contributor

hope this one does not cause trouble for users

@innerlee innerlee merged commit c7d62ab into open-mmlab:master Oct 31, 2020
@dreamerlin dreamerlin deleted the metric_option branch November 12, 2020 11:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants