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

Error when using msp as ood option #9

Open
zerolatnc opened this issue Mar 5, 2021 · 0 comments
Open

Error when using msp as ood option #9

zerolatnc opened this issue Mar 5, 2021 · 0 comments

Comments

@zerolatnc
Copy link

Hi,

I am trying to do anomaly segmentation on a custom dataset. When I use msp as the --ood option, I get the following error:

user@c9b49b91ebcb:~/work/SynthCP/anomaly$ python eval_ood_rec.py --cfg config/exp
1_test_new_ood_rec.yaml --ood msp
Traceback (most recent call last):
  File "eval_ood_rec.py", line 325, in <module>
    main(cfg, args.gpu)
  File "eval_ood_rec.py", line 260, in main
    evaluate(segmentation_module, loader_val, loader_rec, cfg, gpu)
  File "eval_ood_rec.py", line 171, in evaluate
    res1 = eval_ood_measure(msp, seg_label, cfg, mask=mask)
UnboundLocalError: local variable 'msp' referenced before assignment

This error is coming up due to this piece of code.

It looks like the variable msp is only populated when we use rec as the --ood option. Is there a fix for this?

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

1 participant