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

KeyError: 'gt_path' #267

Closed
deltabravozulu opened this issue Apr 21, 2021 · 1 comment · Fixed by #270
Closed

KeyError: 'gt_path' #267

deltabravozulu opened this issue Apr 21, 2021 · 1 comment · Fixed by #270
Assignees

Comments

@deltabravozulu
Copy link

deltabravozulu commented Apr 21, 2021

For some reason, if I run the restoration demo using edsr, it breaks. This happens to others. I can at least ameliorate the issue if I go in and change mmediting/mmedit/apis/restoration_inference in this way:
keys_to_remove = ['gt'] --> keys_to_remove = ['gt','gt_path'] but I don't know enough about this to know if I'm breaking stuff or not.

$ python demo/restoration_demo.py configs/restorers/edsr/edsr_x2c64b16_g1_300k_div2k.py edsr_x2c64b16_1x16_300k_div2k_20200604-19fe95ea.pth testimage.jpeg testimage_edsr.jpeg
Use load_from_local loader
Traceback (most recent call last):
  File "demo/restoration_demo.py", line 38, in <module>
    main()
  File "demo/restoration_demo.py", line 29, in main
    output = restoration_inference(model, args.img_path)
  File "/home/user/github/mmediting/mmedit/apis/restoration_inference.py", line 35, in restoration_inference
    data = test_pipeline(data)
  File "/home/user/github/mmediting/mmedit/datasets/pipelines/compose.py", line 41, in __call__
    data = t(data)
  File "/home/user/github/mmediting/mmedit/datasets/pipelines/formating.py", line 254, in __call__
    img_meta[key] = results[key]
KeyError: 'gt_path'
@deltabravozulu deltabravozulu changed the title AttributeError: 'ConfigDict' object has no attribute 'test_pipeline' KeyError: 'gt_path' Apr 21, 2021
@Yshuo-Li
Copy link
Collaborator

Thanks for your contribution, the issue has been solved in #270.

@innerlee innerlee linked a pull request Apr 21, 2021 that will close this issue
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 a pull request may close this issue.

2 participants