PaddleSeg icon indicating copy to clipboard operation
PaddleSeg copied to clipboard

无法正常使用--config Matting\configs\quick_start\ppmattingv2-stdc1-human_512.yml

Open ShakeWeLy opened this issue 1 year ago • 1 comments
trafficstars

问题确认 Search before asking

  • [X] 我已经搜索过问题,但是没有找到解答。I have searched the question and found no related answer.

请提出你的问题 Please ask your question

(A_scrpit) PS F:\Pydata\Tool\PaddleSeg-release-2.9> python tools/predict.py --config Matting\configs\quick_start\ppmattingv2-stdc1-human_512.yml --model_path pretrained_models\model.pdiparams --image_path ./demo --save_dir ./output/results Traceback (most recent call last): File "C:\Users\admin.conda\envs\A_scrpit\lib\site-packages\paddleseg\cvlibs\config_checker.py", line 39, in apply_rule rule.apply(cfg, self.allow_update) File "C:\Users\admin.conda\envs\A_scrpit\lib\site-packages\paddleseg\cvlibs\config_checker.py", line 63, in apply self.check_and_correct(cfg) File "C:\Users\admin.conda\envs\A_scrpit\lib\site-packages\paddleseg\cvlibs\config_checker.py", line 73, in check_and_correct assert i in cfg.dic,
AssertionError: No loss specified in the configuration file.

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "F:\Pydata\Tool\PaddleSeg-release-2.9\tools\predict.py", line 178, in main(args) File "F:\Pydata\Tool\PaddleSeg-release-2.9\tools\predict.py", line 137, in main cfg = Config(args.config) File "C:\Users\admin.conda\envs\A_scrpit\lib\site-packages\paddleseg\cvlibs\config.py", line 83, in init checker.apply_all_rules(self) File "C:\Users\admin.conda\envs\A_scrpit\lib\site-packages\paddleseg\cvlibs\config_checker.py", line 50, in apply_all_rules self.apply_rule(i, cfg) File "C:\Users\admin.conda\envs\A_scrpit\lib\site-packages\paddleseg\cvlibs\config_checker.py", line 41, in apply_rule raise RuntimeError( RuntimeError: Sanity check on the configuration file has failed. There should be some problems with your config file. Please check it carefully. The failed rule is DefaultPrimaryRule, and the error message is: No loss specified in the configuration file.

报错如上,按照快速入门,但是无法运行?是否是configs使用错误?

ShakeWeLy avatar Dec 07 '23 03:12 ShakeWeLy

你好,需要进入到PaddleSeg/Matting目录下执行相关指令。

shiyutang avatar Jan 19 '24 07:01 shiyutang