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] fix image save path bug in Windows #1423

Merged
merged 2 commits into from
Apr 9, 2022
Merged

[fix] fix image save path bug in Windows #1423

merged 2 commits into from
Apr 9, 2022

Conversation

whu-pzhang
Copy link
Contributor

@whu-pzhang whu-pzhang commented Mar 28, 2022

Motivation

when run .\tools\convert_datasets\isaid.py in Windows OS, as the path str has no /,there will get wrong image save path.

image

Modification

using os.path.basename(src_path).split('.')[0] to get the filename without suffix.

@CLAassistant
Copy link

CLAassistant commented Mar 28, 2022

CLA assistant check
All committers have signed the CLA.

@MengzhangLI
Copy link
Contributor

Hi, thanks for your contribution.

BTW, could this pr run correctly in Linux/Ubuntu OS?

@whu-pzhang
Copy link
Contributor Author

Hi, thanks for your contribution.

BTW, could this pr run correctly in Linux/Ubuntu OS?

I runs the script in Ubuntu20.04, the image filename is current.
image

@MengzhangLI
Copy link
Contributor

Pretty cool! So let it run and we can check out whether the number of train/val is identical.

By the way, could you please fix the lint error? Thanks in advance!

Best,

@whu-pzhang
Copy link
Contributor Author

Pretty cool! So let it run and we can check out whether the number of train/val is identical.

By the way, could you please fix the lint error? Thanks in advance!

Best,

The proceduce is pretty slow, after it finished, I will report the info.
and the lint error will be fixed in next commit.

@whu-pzhang
Copy link
Contributor Author

The generated train/val images numbers are 33978 and 11644, which is identical with iSAID
image

@MengzhangLI
Copy link
Contributor

The generated train/val images numbers are 33978 and 11644, which is identical with iSAID image

osp.basename is such a good thing for achieving file name. ;)

@MeowZheng MeowZheng merged commit da8b79b into open-mmlab:master Apr 9, 2022
mob5566 pushed a commit to mob5566/mmsegmentation that referenced this pull request Apr 13, 2022
* [fix] fix image save path bug in Windows

* fix lint error
ZhimingNJ pushed a commit to AetrexTechnology/mmsegmentation that referenced this pull request Jun 29, 2022
* [fix] fix image save path bug in Windows

* fix lint error
aravind-h-v pushed a commit to aravind-h-v/mmsegmentation that referenced this pull request Mar 27, 2023
* Flax: start adapting to Stable Diffusion 2

* More changes.

* attention_head_dim can be a tuple.

* Fix typos

* Add simple SD 2 integration test.

Slice values taken from my Ampere GPU.

* Add simple UNet integration tests for Flax.

Note that the expected values are taken from the PyTorch results. This
ensures the Flax and PyTorch versions are not too far off.

* Apply suggestions from code review

Co-authored-by: Patrick von Platen <patrick.v.platen@gmail.com>

* Typos and style

* Tests: verify jax is available.

* Style

* Make flake happy

* Remove typo.

* Simple Flax SD 2 pipeline tests.

* Import order

* Remove unused import.

Co-authored-by: Patrick von Platen <patrick.v.platen@gmail.com>
Co-authored-by: @camenduru
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.

4 participants