aimagelab / VKD

PyTorch code for ECCV 2020 paper: "Robust Re-Identification by Multiple Views Knowledge Distillation"
MIT License
73 stars 15 forks source link

which network is used for evaluation? #7

Closed LiangHann closed 3 years ago

LiangHann commented 3 years ago

I am confused for the evaluation codes: for idx_iteration in range(args.num_generations): print(f'starting generation {idx_iteration+1}') print('#'*100) teacher_net = d_trainer(teacher_net, student_net) d_trainer.evaluate(teacher_net) teacher_net.teacher_mode()

    student_net = deepcopy(teacher_net)
    saver.save_net(student_net, f'chk_di_{idx_iteration + 1}')

    student_net.reinit_layers(args.reinit_l4, args.reinit_l3)

Do you use student network or teacher network for evaluation?

angpo commented 3 years ago

We perform the evaluation on the student net; indeed d_trainer(teacher_net, student_net) returns the parameters of the student net. We store it in a variable called teacher_net because we have tried to re-iterate the process (namely, using the student as a teacher for another network). However, as we did not observe any improvement, we simply stopped to one iteration.