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

关于测试代码 #4

Open
xiaomudsg opened this issue Mar 27, 2024 · 2 comments
Open

关于测试代码 #4

xiaomudsg opened this issue Mar 27, 2024 · 2 comments

Comments

@xiaomudsg
Copy link

亲爱的作者,不知您现在是否还愿意解答此代码相关问题,我尝试去复现您的代码,发现训练可以跑通,但是测试的时候总是提示期望的通道数和输入通道数不一致,请问用train.py训练的模型,是用main里面的paper_test.py来测试嘛?
Snipaste_2024-03-27_22-46-19

@xiaomudsg
Copy link
Author

我输入的测试图片通道数就是为3呀

@zhangliukun
Copy link
Owner

我输入的测试图片通道数就是为3呀

当时测试的时候应该是单通道的,有个配置
self.param_single_channel = True
模型按理说应该输入是单通道的,会对输入的三通道图取单通道,
source_image = source_image_raw[:, :, 0:1]
target_image = target_image_raw[:, :, 2:3]

具体原因可以debug看一下是哪里没有设置

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

No branches or pull requests

2 participants