xinzheli1217 / learning-to-self-train

Learning to Self-Train for Semi-Supervised Few-Shot
MIT License
93 stars 11 forks source link

[Bug] test_rn_loss is not defined #2

Open hortune opened 4 years ago

hortune commented 4 years ago
Traceback (most recent call last):                                                                                
  File "exp_train.py", line 119, in <module>                                                                      
    main()                                                                                                        
  File "exp_train.py", line 116, in main
    trainer = MetaTrainer()                                                                                       
  File "/uge_mnt/home/hortune/learning-to-self-train/trainer/meta_LST.py", line 116, in __init__
    self.train()                                                                                                  
  File "/uge_mnt/home/hortune/learning-to-self-train/trainer/meta_LST.py", line 310, in train
    np.mean(test_rn_loss) * FLAGS.meta_batch_size)
NameError: name 'test_rn_loss' is not defined 

As described above, the test_rn_loss is not defined. What should it be?

xinzheli1217 commented 4 years ago

I'm quite sorry about the mistake, the "test_rn_loss" should be the "test_swn_loss" in the previous line.

----- 原始邮件 ----- 发件人: "chia you chen" notifications@github.com 收件人: "xinzheli1217/learning-to-self-train" learning-to-self-train@noreply.github.com 抄送: "Subscribed" subscribed@noreply.github.com 发送时间: 星期四, 2019年 11 月 28日 下午 3:33:41 主题: [xinzheli1217/learning-to-self-train] [Bug] test_rn_loss is not defined (#2)

Traceback (most recent call last):                                                                                
  File "exp_train.py", line 119, in <module>                                                                      
    main()                                                                                                        
  File "exp_train.py", line 116, in main
    trainer = MetaTrainer()                                                                                       
  File "/uge_mnt/home/hortune/learning-to-self-train/trainer/meta_LST.py", line 116, in __init__
    self.train()                                                                                                  
  File "/uge_mnt/home/hortune/learning-to-self-train/trainer/meta_LST.py", line 310, in train
    np.mean(test_rn_loss) * FLAGS.meta_batch_size)
NameError: name 'test_rn_loss' is not defined 

As described above, the test_rn_loss is not defined. What should it be?

-- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/xinzheli1217/learning-to-self-train/issues/2

xinzheli1217 commented 4 years ago
Traceback (most recent call last):                                                                                
  File "exp_train.py", line 119, in <module>                                                                      
    main()                                                                                                        
  File "exp_train.py", line 116, in main
    trainer = MetaTrainer()                                                                                       
  File "/uge_mnt/home/hortune/learning-to-self-train/trainer/meta_LST.py", line 116, in __init__
    self.train()                                                                                                  
  File "/uge_mnt/home/hortune/learning-to-self-train/trainer/meta_LST.py", line 310, in train
    np.mean(test_rn_loss) * FLAGS.meta_batch_size)
NameError: name 'test_rn_loss' is not defined 

As described above, the test_rn_loss is not defined. What should it be?

There are some small mistakes in the meta_LST.py file, I just corrected them and you can re-download the latest version.