Traceback (most recent call last):
File "main_pretrain.py", line 239, in
main(args)
File "main_pretrain.py", line 208, in main
train_stats = train_one_epoch(
File "/root/autodl-tmp/mae-contrastive-main/engine_pretrain.py", line 44, in train_one_epoch
loss, loss_contrastive, loss_noise, _, _ = model(samples, mask_ratio=args.mask_ratio)
File "/root/miniconda3/envs/mage/lib/python3.8/site-packages/torch/nn/modules/module.py", line 727, in _call_impl
result = self.forward(*input, **kwargs)
File "/root/autodl-tmp/mae-contrastive-main/models_mae.py", line 266, in forward
loss, loss_noise = self.forward_loss(imgs, pred, mask, noise=noise)
UnboundLocalError: local variable 'noise' referenced before assignment