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

Update custom.py #849

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Update custom.py #849

wants to merge 1 commit into from

Conversation

huster-wgm
Copy link

@huster-wgm huster-wgm commented Sep 3, 2021

Motivation

skip tmp files generated by jupyter notebook to avoid unexpected failture for image loading.

Modification

filtering scan files

for img in mmcv.scandir(img_dir, img_suffix, recursive=True):
    if '.ipynb_checkpoints' in img:
        continue  # skip tmp files

BC-breaking (Optional)

No

Use cases (Optional)

No

Checklist

  1. Pre-commit or other linting tools are used to fix the potential lint issues.
  2. The modification is covered by complete unit tests. If not, please add more unit test to ensure the correctness.
  3. If the modification has potential influence on downstream projects, this PR should be tested with downstream projects, like MMDet or MMDet3D.
  4. The documentation has been modified accordingly, like docstring or example tutorials.

skip tmp files to avoid unexspected images
@CLAassistant
Copy link

CLAassistant commented Sep 3, 2021

CLA assistant check
All committers have signed the CLA.

@codecov
Copy link

codecov bot commented Sep 3, 2021

Codecov Report

Merging #849 (cd4674c) into master (d35fbbd) will decrease coverage by 0.02%.
The diff coverage is 0.00%.

❗ Current head cd4674c differs from pull request most recent head 7e9d370. Consider uploading reports for the commit 7e9d370 to get more accurate results
Impacted file tree graph

@@            Coverage Diff             @@
##           master     #849      +/-   ##
==========================================
- Coverage   88.90%   88.87%   -0.03%     
==========================================
  Files         110      110              
  Lines        5928     5930       +2     
  Branches      950      951       +1     
==========================================
  Hits         5270     5270              
- Misses        465      466       +1     
- Partials      193      194       +1     
Flag Coverage Δ
unittests 88.85% <0.00%> (-0.03%) ⬇️

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

Impacted Files Coverage Δ
mmseg/datasets/custom.py 91.11% <0.00%> (-1.03%) ⬇️

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 d35fbbd...7e9d370. Read the comment docs.

@Junjun2016
Copy link
Collaborator

Hi @huster-wgm
Thanks for your contribution!
Can we avoid it by setting the permissions of the data to read-only mode?

@RockeyCoss
Copy link
Contributor

Please merge the master branch into your branch, thank you.

Comment on lines 149 to +151
for img in mmcv.scandir(img_dir, img_suffix, recursive=True):
if '.ipynb_checkpoints' in img:
continue # skip tmp files
Copy link
Collaborator

Choose a reason for hiding this comment

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

I think img_suffix will filter out the files with '.ipynb_checkpoints'

@OpenMMLab-Assistant005
Copy link

Hi @huster-wgm !We are grateful for your efforts in helping improve this open-source project during your personal time.
Welcome to join OpenMMLab Special Interest Group (SIG) private channel on Discord, where you can share your experiences, ideas, and build connections with like-minded peers. To join the SIG channel, simply message moderator— OpenMMLab on Discord or briefly share your open-source contributions in the #introductions channel and we will assist you. Look forward to seeing you there! Join us :https://discord.gg/UjgXkPWNqA
If you have a WeChat account,welcome to join our community on WeChat. You can add our assistant :openmmlabwx. Please add "mmsig + Github ID" as a remark when adding friends:)
Thank you again for your contribution❤

wjkim81 pushed a commit to wjkim81/mmsegmentation that referenced this pull request Dec 3, 2023
* test the simple case using tmux to run multiple benchmark regression test tasks

* modify and rename the config file and script

* Delete config_list.yaml

* modify the config and rename the filename

* Delete test_benchmark_tmux.py

* modify the script and rename the filename

* Update setup.cfg

* using mmcv.load to avoid introducing the extra dependency on yaml

* fix some typo

* refactor the config file and modify the script accordingly

* modify the config and script

* rename the config file
wjkim81 pushed a commit to wjkim81/mmsegmentation that referenced this pull request Dec 3, 2023
* add dataset info (open-mmlab#663)

* Fix import and deprecation issues in unit tests (open-mmlab#871)

* fix some bugs in the unit test of smpl model.

* reorganize `tests/` to solve importing issue (PEP 420)

* fix deprecation warnings in unit tests

Co-authored-by: ly015 <[email protected]>

* add benchmark regression test script with tmux (open-mmlab#849)

* test the simple case using tmux to run multiple benchmark regression test tasks

* modify and rename the config file and script

* Delete config_list.yaml

* modify the config and rename the filename

* Delete test_benchmark_tmux.py

* modify the script and rename the filename

* Update setup.cfg

* using mmcv.load to avoid introducing the extra dependency on yaml

* fix some typo

* refactor the config file and modify the script accordingly

* modify the config and script

* rename the config file

* Correct dataset preparation guide of WFLW (open-mmlab#873)

* add pr template (open-mmlab#875)

* add CITATION.cff and update setup.py (open-mmlab#876)

* Add copyright header and pre-commit hook (open-mmlab#872)

* Add pre-commit hook to automatically add copyright file header

* update files with copyright header

*  Limit copyright checking in the first 2 lines of a file
* Exclude configs in demo/

* set max-header-lines as 5

* rebase to master and add copyright to new files
* move benchmark_regression into .dev_scripts/benchmark

* Translate tasks/2d_body_keypoint.md (open-mmlab#842)

* 2rd PR remove poseval

* fix lint

* revise the CN version

Co-authored-by: ly015 <[email protected]>

* fix some bugs in the unit test of smpl model.

* * reorganiz `tests/` to solve importing issue (PEP 420)

* add dataset info

* fix lint

* * fix wrongly modified parts in previous rebase
* fix lint

* rename datasets/_base_ as datasets/base

* resolve compatibility of pose_limb_color

* Add dummy dataset base classes with old names for compatibility

* * Rewrite relative unittest based on dataset_info
* Add bc-breaking test for functions related to dataset_info
* Rename DatasetInfo.dataset_info as DatasetInfo._dataset_info
* Fix dataset_info of h36m dataset

* Handle breaking change pose_limb_color -> pose_link_color

* add unittest for old-fashioned dataset initialization without dataset_info

* resolve naming conflict in unittests

Co-authored-by: zengwang430521 <[email protected]>
Co-authored-by: ly015 <[email protected]>

* fix typo

* fix typo

Co-authored-by: Jas <[email protected]>
Co-authored-by: zengwang430521 <[email protected]>
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.

6 participants