The Wayback Machine - https://web.archive.org/web/20201219235455/https://github.com/PaddlePaddle/models/pull/4860
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

[cherry-pick] Update mpii_reader.py #4860

Merged
merged 2 commits into from Sep 18, 2020
Merged

Conversation

@a2824256
Copy link
Contributor

@a2824256 a2824256 commented Sep 18, 2020

cherry-pick from #4862

操作系统: win10
python版本: 3.6.10
问题描述:
human_pose_estimation使用mpii数据集test的时候一直没有运行结果。在问题文件186行
fold = ‘test’
修改为
fold = cfg.DATAROOT + os.sep + cfg.IMAGEDIR + os.sep +'test'
之后可以运行,因为下一行os.listdir(fold)读取的路径不对,根目录下没有叫test的文件夹,所以一直读取0张图片,正确路径是data/mpii/images下的test文件夹。
对应issue链接:
#4859 (comment)

问题描述:
human_pose_estimation使用mpii数据集test的时候一直没有运行结果。在问题文件186行
fold = ‘test’
修改为
fold = cfg.DATAROOT + '/' + cfg.IMAGEDIR + '/test'
之后可以运行,因为下一行os.listdir(fold)读取的路径不对,一直没读取到文件。
@CLAassistant
Copy link

@CLAassistant CLAassistant commented Sep 18, 2020

CLA assistant check
All committers have signed the CLA.

@@ -183,7 +183,7 @@ def reader():
test_mode=False,
imagenum=0)
else:
fold = 'test'
fold = cfg.DATAROOT + os.sep + cfg.IMAGEDIR + os.sep + 'test'

This comment has been minimized.

@littletomatodonkey

littletomatodonkey Sep 18, 2020
Contributor

使用os.path.join连接路径吧

This comment has been minimized.

@a2824256

a2824256 Sep 18, 2020
Author Contributor

好的

Copy link
Contributor Author

@a2824256 a2824256 left a comment

已使用os.path.join拼接路径

@wangxicoding
Copy link
Contributor

@wangxicoding wangxicoding commented Sep 18, 2020

@a2824256 另外这个是1.8的分支,麻烦在develop分支上再提个PR

@a2824256
Copy link
Contributor Author

@a2824256 a2824256 commented Sep 18, 2020

已提交
#4862

@wangxicoding wangxicoding changed the title Update mpii_reader.py [cherry-pick] Update mpii_reader.py Sep 18, 2020
Copy link
Contributor

@wangxicoding wangxicoding left a comment

LGTM

@wangxicoding wangxicoding merged commit f80b766 into PaddlePaddle:release/1.8 Sep 18, 2020
2 checks passed
2 checks passed
continuous-integration/travis-ci/pr The Travis CI build passed
Details
license/cla Contributor License Agreement is signed.
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
4 participants
You can’t perform that action at this time.