I meet the following problem
Traceback (most recent call last):
File "CAMixerSR/codes/basicsr/test.py", line 12, in
test_pipeline(root_path)
File "CAMixerSR/codes/BasicSR/basicsr/test.py", line 40, in test_pipeline
model.validation(test_loader, current_iter=opt['name'], tb_logger=None, save_img=opt['val']['save_img'])
File "CAMixerSR/codes/BasicSR/basicsr/models/base_model.py", line 48, in validation
self.nondist_validation(dataloader, current_iter, tb_logger, save_img)
File "CAMixerSR/codes/BasicSR/basicsr/models/sr_model.py", line 245, in nondist_validation
self.metric_results[metric] /= (idx + 1)
UnboundLocalError: local variable 'idx' referenced before assignment
I meet the following problem Traceback (most recent call last): File "CAMixerSR/codes/basicsr/test.py", line 12, in
test_pipeline(root_path)
File "CAMixerSR/codes/BasicSR/basicsr/test.py", line 40, in test_pipeline
model.validation(test_loader, current_iter=opt['name'], tb_logger=None, save_img=opt['val']['save_img'])
File "CAMixerSR/codes/BasicSR/basicsr/models/base_model.py", line 48, in validation
self.nondist_validation(dataloader, current_iter, tb_logger, save_img)
File "CAMixerSR/codes/BasicSR/basicsr/models/sr_model.py", line 245, in nondist_validation
self.metric_results[metric] /= (idx + 1)
UnboundLocalError: local variable 'idx' referenced before assignment