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] Update outdated dependencies of mmcv for downloading fine-gym dataset #2495

Merged
merged 2 commits into from
May 29, 2023

Conversation

yhZhai
Copy link
Contributor

@yhZhai yhZhai commented May 23, 2023

Motivation

The MMCV package now has version 2.0.0, which removes the function mmcv.load(), causing the following error when running tools/data/gym/download_videos.sh:

Traceback (most recent call last):
File "download.py", line 100, in
main(**vars(p.parse_args()))
File "download.py", line 75, in main
youtube_ids = mmcv.load(input).keys()
AttributeError: module 'mmcv' has no attribute 'load'

Modification

Changing pip install mmcv to pip install "mmcv<2.0.0" addresses this problem.

@CLAassistant
Copy link

CLAassistant commented May 23, 2023

CLA assistant check
All committers have signed the CLA.

@cir7
Copy link
Collaborator

cir7 commented May 24, 2023

Thanks for your contribution. Related functions have been moved into MMEngine, so the best solution is to update the outdated dependencies.
The modification is also very easy, just globally replace mmcv with mmengine in tools/data/gym/download.py , tools/data/gym/trim_event.py, tools/data/gym/trim_subaction.py and install mmengine in tools/data/gym/download_videos.sh instead of mmcv.
Could you please help us fix the issue in this way?

@yhZhai
Copy link
Contributor Author

yhZhai commented May 25, 2023

Thanks for your contribution. Related functions have been moved into MMEngine, so the best solution is to update the outdated dependencies.
The modification is also very easy, just globally replace mmcv with mmengine in tools/data/gym/download.py , tools/data/gym/trim_event.py, tools/data/gym/trim_subaction.py and install mmengine in tools/data/gym/download_videos.sh instead of mmcv.
Could you please help us fix the issue in this way?

Hi there, I have made these changes, please check. Thank you for providing such detailed guidance!

@codecov
Copy link

codecov bot commented May 29, 2023

Codecov Report

Patch coverage: 80.55% and project coverage change: -0.05 ⚠️

Comparison is base (07259a2) 76.97% compared to head (ab727d8) 76.93%.

❗ Current head ab727d8 differs from pull request most recent head 82dac3c. Consider uploading reports for the commit 82dac3c to get more accurate results

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2495      +/-   ##
==========================================
- Coverage   76.97%   76.93%   -0.05%     
==========================================
  Files         159      159              
  Lines       12546    12554       +8     
  Branches     2099     2102       +3     
==========================================
+ Hits         9657     9658       +1     
- Misses       2386     2390       +4     
- Partials      503      506       +3     
Flag Coverage Δ
unittests 76.93% <80.55%> (-0.05%) ⬇️

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

Impacted Files Coverage Δ
mmaction/datasets/transforms/wrappers.py 56.34% <0.00%> (-0.91%) ⬇️
mmaction/models/backbones/mvit.py 78.81% <ø> (ø)
mmaction/models/heads/base.py 80.95% <ø> (ø)
mmaction/models/heads/mvit_head.py 82.85% <50.00%> (-7.47%) ⬇️
mmaction/models/utils/blending_utils.py 90.62% <84.61%> (-1.51%) ⬇️
mmaction/__init__.py 100.00% <100.00%> (ø)
mmaction/evaluation/metrics/acc_metric.py 81.29% <100.00%> (-0.70%) ⬇️
mmaction/models/losses/cross_entropy_loss.py 65.27% <100.00%> (+0.48%) ⬆️

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@cir7 cir7 changed the title fix: add version max constrain to mmcv for finegym video download [Fix] Update outdated dependencies of mmcv for downloading fine-gym dataset May 29, 2023
@cir7 cir7 merged commit 1485998 into open-mmlab:main May 29, 2023
@OpenMMLab-Assistant-004

Hi @yhZhai,

We'd like to express our appreciation for your valuable contributions to the mmaction2. Your efforts have significantly aided in enhancing the project's quality.
It is our pleasure to invite you to join our community thorugh Discord_Special Interest Group (SIG) channel. This is a great place to share your experiences, discuss ideas, and connect with other like-minded people. To become a part of the SIG channel, send a message to the moderator, OpenMMLab, briefly introduce yourself and mention your open-source contributions in the #introductions channel. Our team will gladly facilitate your entry. We eagerly await your presence. Please follow this link to join us: ​https://discord.gg/UjgXkPWNqA.

If you're on WeChat, we'd also love for you to join our community there. Just add our assistant using the WeChat ID: openmmlabwx. When sending the friend request, remember to include the remark "mmsig + Github ID".

Thanks again for your awesome contribution, and we're excited to have you as part of our community!

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.

5 participants