Open bxiong97 opened 1 year ago
In the validation step, all the code does is visualizing the results. How do we know quantitatively that the model is improving?
def validation_step(self):
self.deca.eval()
try:
batch = next(self.val_iter)
except:
self.val_iter = iter(self.val_dataloader)
batch = next(self.val_iter)
images = batch['image'].cuda(); images = images.view(-1, images.shape[-3], images.shape[-2], images.shape[-1])
with torch.no_grad():
codedict = self.deca.encode(images)
opdict, visdict = self.deca.decode(codedict)
savepath = os.path.join(self.cfg.output_dir, self.cfg.train.val_vis_dir, f'{self.global_step:08}.jpg')
util.visualize_grid(visdict, savepath)
Were you able to train DECA?
在验证步骤中,代码所做的只是可视化结果。我们如何定量地知道模型正在改进?
def validation_step(self): self.deca.eval() try: batch = next(self.val_iter) except: self.val_iter = iter(self.val_dataloader) batch = next(self.val_iter) images = batch['image'].cuda(); images = images.view(-1, images.shape[-3], images.shape[-2], images.shape[-1]) with torch.no_grad(): codedict = self.deca.encode(images) opdict, visdict = self.deca.decode(codedict) savepath = os.path.join(self.cfg.output_dir, self.cfg.train.val_vis_dir, f'{self.global_step:08}.jpg') util.visualize_grid(visdict, savepath)
Hello, could you please tell me how to determine whether the model has converged and has a good training result from the loss curve saved in TensorBoard? Thank you.
Hi, thank you for releasing the code! I have some questions about the training process:
Thank you for your time!